7

I made a component in joomla 2.5 in mvc way which was not working in joomla 3, later found out it's because in joomla 3 previous mvc classes not working so is controller, view, model classes must be extended from Legacy classes like

JControllerLegacy, JViewLegacy ,JModelLegacy

and no other changes needed to make component compatible with joomla 3 as far as i knew.If there anything more to know then let me know for compatibility with j3. So instead of making two separate mvc components for joomla 2.5 and 3, i guess i can extend from these Legacy classes so that single component is enough for both joomla 2.5 and 3, right? and again what other things to be considered to produce successful MVC component which can be installed in both joomla versions.

2
  • 1
    To run an extension on both platforms, I've found FoF library to be the simplest solution github.com/akeeba/fof
    – Anibal
    Apr 28, 2014 at 21:15
  • I think a good resource for you would be 'Learning Joomla! 3 Extension Development,' by Tim Plummer as much of the book covers step-by-step 'How to upgrade a Joomla! 2.5 component to Joomla! 3.' See packtpub.com/web-development/…
    – NivF007
    Dec 6, 2016 at 23:40

1 Answer 1

8

There is a good doc page explaining the differences between Joomla 2.5 and 3.x.

http://docs.joomla.org/Potential_backward_compatibility_issues_in_Joomla_3_and_Joomla_Platform_12.2

The only thing to mention is that the legacy classes are only available in Joomla 2.5.5 and higher. But anyone should be on 2.5.19 nowadays anyway :)

2
  • 1
    How long does the legacy classes stay for joomla 3 versions?
    – dev-m
    Apr 29, 2014 at 1:15
  • 1
    They can be removed at earliest with Joomla 4.0. Currently they aren't even deprecated yet. Feel free to use them.
    – Bakual
    Apr 29, 2014 at 6:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.