User tests: Successful: Unsuccessful:
Allows the plugins to catch the module object (content and params) before it renders into the page. This is very useful for design purposes
Status | New | ⇒ | Pending |
Labels |
Added:
?
|
Hi Brian,
Here an example of use :
1/ create a sytem plugin
2/ write
function onAfterRenderModule($module, $attribs) {
$module->content = '
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.
Please let me know
Regards
CEd
personally, I think that for such cases the ModuleChrome https://docs.joomla.org/Module_chrome cover all needs here
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.
If you need to alter the output of the module itself, template overrides are the way to go, assuming the module is coded right.
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.
If the user click the button in the module options, the plugin alter the module code before rendering in the page to add the sticky class.
this is a simple example, now if you know of to do all this using Module Chrome, let me know :)
I don't see where is the problem to add this event, is there anyone ?
Thanks for the example. It makes more sense now.
Are these three issues related #8693 #8296 #3105
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
Is there any news about the implementation of this trigger ?
Thank you
CEd
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).
They should then log their results in https://issues.joomla.org/tracker/joomla-cms/8693
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
Status | Pending | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2016-01-06 12:32:30 |
Closed_By | ⇒ | Bakual |
It would be useful if you could provide an example of how to test this functionality