问题
I followed a tutorial from the Joomla developer wiki (http://docs.joomla.org/Developers#Developing_a_Model-View-Controller_.28MVC.29_Component_2) to create a Joomla component. It all worked fine in Joomla 1.7, but when I upgraded to Joomla 2.5 the checkboxes in the backend are not working any more.
I checked the code from http://docs.joomla.org/Developing_a_Model-View-Controller_(MVC)_Component_for_Joomla!1.7_-_Part_09#Adding_a_toolbar in Joomla 2.5 extensions and the boxchecked hidden field is still there. Also the javascript around is still the same.
Does anyone has the same problem?
回答1:
I found the problem. The form should have a id next to the name. Joomla 1.7 is only checking on the name, but Joomla 2.5 is checking for the id.
回答2:
visit this weblink, it might be useful to you..
http://docs.joomla.org/Developing_a_Model-View-Controller_(MVC)_Component_for_Joomla!2.5_-_Part_13#Articles_in_this_series
来源:https://stackoverflow.com/questions/9017599/tutorial-code-is-not-working-any-more-in-joomla-2-5