-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
Add Event onAfterRenderModule #8693
Conversation
Allows the plugins to catch the module object (content and params) before it renders into the page. This is very useful for design purposes
It would be useful if you could provide an example of how to test this functionality |
Hi Brian, ' . $module->content . ' ';} 3/ this will render a div around the module that can be used to add some styles or link to some JS to make it float This is a basic example, where of course you would need in your plugin to test if you are in admin or front, make some additional condition to target the needed module and have the best conditions to do it (like any good developer would do in any plugin ;) ) Hope that this is clear and that you will think about implementing it. |
personally, I think that for such cases the ModuleChrome https://docs.joomla.org/Module_chrome cover all needs here |
@Fedik : how to you catch and render the module from a plugin ? the module Chrome covers all needs if you are inside a template only |
I tend to agree with @Fedik here, at least for the use case you mentioned. The module chrome is exactly meant to provide design around a module content. Like adding a div around the content. I don't see yet the usecase where you would need a plugin event, but feel free to make an example. |
I have made a little example above :) Imagine that you want to develop a plugin that will add some options into a module (any module in this case), then using the plugin you can check the options and do some work. In my case I add a button to make the module sticky. this is a simple example, now if you know of to do all this using Module Chrome, let me know :) |
Thanks for the example. It makes more sense now. |
Are these three issues related #8693 #8296 #3105 This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/8693. |
Is pretty much a carbon copy of: #8296 |
I have not seen the other requests that are similar. For me, no matter who's name is for the pull request, the only thing that is important to me is that this trigger is added to allow more customization and user interaction. Thank you |
Hi |
Without any human tests, it will usually go nowhere. |
Ok so please tell me wo needs to test and how. |
Anyone (beside you as it's your own PR and we assume you tested it) can test this PR by using the Joomla patchtester (http://joom.la/patchtester). Usually we require two good tests for anything to be merged. Since this introduces a new feature/API point, it can go into Joomla 3.6.0 earliest (3.5.0 is feature locked already as it is in beta). |
ok thank you for the informations |
The process for testers is described here https://docs.joomla.org/Testing_Joomla!_patches Normally it helps getting testing if you have a clear "How to test" or "Testing instructions" block in the PR description with clear and simple instructions on how to test (and screenshots if needed). Example: #8350 |
But this PR can get closed as it is a duplicate of #8296 |
Allows the plugins to catch the module object (content and params) before it renders into the page. This is very useful for design purposes