[TYPO3-ect] How to convert plugins to MVC/lib/div ?

Stefan Geith typo3dev2006 at geithware.de
Thu Jun 28 13:07:39 CEST 2007


Hi There,

hope, this is the right newsgroup for this ...


What is the way to convert exisiting plugins to MVC ?

If I understand it right, then my old plugins are some kind of
'controllers', but they also contain all that stuff for views and
models. Right ?


Then it could go this way:
- copy old 'tx_plugin_pi1' to get my new 'controler'
- replace all references to pi_base (e.g. pi_link...()) with
   tx_lib_link etc.
- change code, where necessary to let it work again
- then extract all view-thingys to view-classes and all
   model-related stuff to model-classes
- and then do refactoring (until the end of days ...)


Or should I do it better the other way round:
- change my 'tx_plugin_pi1' to use tx_lib instead of pi_base
   wherever possible
- then extract all view-thingys to view-classes and all
   model-related stuff to model-classes
- do some refactoring
- then copy old 'tx_plugin_pi1' to get my new 'controler'
- change code, where necessary to let it work again
- and then do refactoring (until the end of days ...)


And what about my libraries:
Should I create a plugin tx_mypersonal_lib where I put my stuff to new
classes (and extend existing classes where it is reasonable) ?
Maybe some parts of that could then go into the official tx_lib (if
there is interest in it) ...


-

Stefan


More information about the TYPO3-team-extension-coordination mailing list