问题
I'm coding my own joomla component based on Joomla 2.5.13 and I'm struggling with the "Adding sortable columns" tutorial. Extending the MVC-model with the provided code-snippets from this tutorial does not lead to the expected result, the columns cannot be sorted.
I guess, the problem is related to Step 2 (Adapting the View) of the guideline. (Shouldn't this piece of code located in the default.php of the view?) Amending the existing code of the view with the mentioned code snippet causes an error, the page will not be rendered.
Furthermore, the JavaScript snippet in Step 3 (Adapting the Template) seems not compatible with joomla 2.5.13. I copied the script between the header tags of my template, but there is no action observably. Could someone confirm, that this tutorial is valid for Joomla 2.5.13? Perhaps someone knows a working tutorial for this challange?
Kind Regards
来源:https://stackoverflow.com/questions/18131673/joomla-2-5-adding-sortable-columns-to-a-table-in-a-component