Hi Arne,
as you know it is possible to create a "show detail" view of the submitted form data in frontend. I thought it would be a good idea to place the link to this view (if it is enable) on a "small" field and choose to take the id field. That is, why the id field is displayed in frontend data list view. By now I know, that was not a very good idea, because it simple looks awful (and I hade more than one post about that). I will change this for certain. For now,
if you do not use the "show detail" feature, you could follow my instructions below and I think this will solve your problem.
1) Create an override of the views template file.
Create a folder named html in the root of your template (if such a folder already exists that is fine too).
Inside the html folder create a folder named com_visforms
Inside the com_visforms folder create a folder named visformsdata
After that you have a path like yourTemplate/html/com_visforms/visformsdata
Go to components/com_visforms/views/visformsdata/tmpl and
copy the file data.php into the newly created folder from above
For security reasons copy the index.html file (it is just an empty file) from components/com_visforms/views/visformsdata/tmpl too and put a copy in each folder which you have create (html, com_visforms, visformsdata in your template).
2) Adapt the override file
Open the copy of data.php in yourTemplate/html/com_visforms/visformsdata
Go to line 68 and remove the following 4 lines of code there
Code:
<th >
<?php echo JHtml::_('grid.sort', 'COM_VISFORMS_ID', 'a.id', $listDirn, $listOrder, 'visformsdata.display');
?>
</th>
Go to line 113 (or somewhere very near by that line) and remove the following lines of code
Code:
<td>
<?php
if (isset($row->id))
{
if (isset($this->form->displaydetail) == false || $this->form->displaydetail == true)
{
echo "<a href=\"".$link."\">".$row->id."</a>";
} else {
echo $row->id;
}
} else {
?> <?php
} ?>
</td>
After that the id column in frontend data view will be deleted for every form.
These instructions will work for Joomla! 2.5 and Joomla! 3 with Visforms 2.0.3 respectively Visforms 3.0.0
When a future version of Visforms comes with an option to hide the id field and another solution for the link to the detail view, you can just remove the override files and everything works with the core layout again, so you do not temper with the core code of Visforms.
Data will still be orderd according to the id. But if you set the "column header" option of the menu item (tab Form Data Display Options) to "show" (which is the default) users can click into the column headers and the record sets will then be ordered by the column they click on. The individual sort order will be a feature of Visforms versions to come.
Kind Regards,
Aicha