-
-
Notifications
You must be signed in to change notification settings - Fork 131
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Understandment Questions to Smarty integration #1304
Comments
That is because of the history of Admidio. First we don't had any theme customizition. Later we added it and implement it, were it was easy. If I would start new with Admidio I would implement a better more integrated way of Smarty. But if there is time or someone who want's to push the integration of Smarty, it would be very nice. |
I did not do PHP for a longer time now and yet I have problems to find my way thru the Sourcecode but ill keep this in Mind and may encouple parts into the theme. |
Please start with small parts so we can have a view how this could be best implemented. Later we can than add more parts. |
Hey all, I have started to do this as well.
I have started with a HTMLForm part for testing which would look like this:
So at the end we are just calling all the "add*" Methods as they are for now, but we will render all that stuff in a Smarty template. What do you think about that idea? |
For me that looks like an implementation of my basic theoretical idea to aproach this; it does not change that much of the logic while uncoupling the template parts |
Would be great if you could also check which parts I have missed so far @Galileon-venta |
@marchorst Thank you very much for the implementation of the form templates. I have done some further fixes to the implementation. Do you plan further smarty integration? Maybe we should try that the HtmlForm class will be directly from the Smarty class. Now its from the deprecated HtmlFormBasis class, which we want to eleminate. |
I can definitely take a look on this and start further development, but I will not have the time in the next one or two month |
Another step was done. #1378 |
I think HtmlForm extends HtmlFormBasic, which is in fact not not used by any other core component as far as I can see this. |
Why not ignore HtmlElement and extend Smarty to HtmlForm. The structure of HtmlElemnt, HtmlTable, HtmlList ... is old and I want not generate the Html structure in PHP. Therefore we have now Smarty. So we should directly genereate Smarty templates out of the HtmlForm class. Maybe we can remove the other classes in future if there are more things migrated to Smarty templates. |
Understand! Yes makes sense - I will take a deeper look on this. |
@marchorst What do you think, is it better to separate the menu parts in separate files and include that files within the index.tpl or should it still be part of the index.tpl ? |
Makes definitly sense to split up the UI components a bit :) |
I implemented the last missing form objects (select and static) and removed the HtmlFormBasic class. |
I will close this issue because the question was answered and main parts are now customizable via Smarty. |
Admidio utilizes Smarty but only for parts of the Views... thereby theme customization provides only restricted possibilies to change the display of the different Module views.
Why is the design like that?
Question also applies for the language files... shouldnt it be possible to tweak them via a theme and not by changing the "core" Code?
The text was updated successfully, but these errors were encountered: