on_after_save event
Jesper Dinesen
Nouveau membre
Posts: 6
il y a 7 ans 1 mois #1647
par Jesper Dinesen
on_after_save event a été créé par Jesper Dinesen
Does anybody have an example of a plugin with on_after_save event etc. I need to modify the code for my plugin, but I would love not to have to hack it !
Jesper
Jesper
Connexion ou Créer un compte pour participer à la conversation.
Juan Sánchez
Nouveau membre
Posts: 9
il y a 7 ans 1 mois #1650
par Juan Sánchez
Réponse de Juan Sánchez sur le sujet on_after_save event
Hello,
Just locate a Joomla plugin similar to yours, in the docs you can find links with examples to the code. You can copy the plugin directory structure, rename it and change its xml configuration parameters. Then go to your backend, extensions, discover and install it. Now you have your own plugin and you can do as many changes you want.
Hope it helps.
Just locate a Joomla plugin similar to yours, in the docs you can find links with examples to the code. You can copy the plugin directory structure, rename it and change its xml configuration parameters. Then go to your backend, extensions, discover and install it. Now you have your own plugin and you can do as many changes you want.
Hope it helps.
Connexion ou Créer un compte pour participer à la conversation.
Jesper Dinesen
Nouveau membre
Posts: 6
il y a 7 ans 1 mois #1651
par Jesper Dinesen
Réponse de Jesper Dinesen sur le sujet on_after_save event
Hi Juan,
I get this, the bigger problem I have is how do I make it an on_after_save event on one of my components I created here... how will my plugin know about the component etc ?
I get this, the bigger problem I have is how do I make it an on_after_save event on one of my components I created here... how will my plugin know about the component etc ?
Connexion ou Créer un compte pour participer à la conversation.
Juan Sánchez
Nouveau membre
Posts: 9
il y a 7 ans 1 mois #1652
par Juan Sánchez
Réponse de Juan Sánchez sur le sujet on_after_save event
Hope it helps: docs.joomla.org/Triggering_content_plugins_in_your_extension
Connexion ou Créer un compte pour participer à la conversation.
Pete
Membre junior
Posts: 27
il y a 2 ans 11 mois #9932
par Pete
Réponse de Pete sur le sujet on_after_save event
It would help to know the Component Builder function names..
In another plugin I built for RS forms, the save event was ..
public function rsfp_f_onAfterStoreSubmissions($args) {
}
what would the Component Builder call name be (assuming it would be based on the component form name somehow ?
This code comes from the CB administrator > models > modelname.php
// Trigger the before save event.
$result = $dispatcher->trigger($this->event_before_save, array($context, &$table, true));
..............
// Trigger the after save event.
$dispatcher->trigger($this->event_after_save, array($context, &$table, true));
Maybe somebody who knows how to work out the function name from that code - if indeed it does what you want - which is to hook a call in after the save process..
In another plugin I built for RS forms, the save event was ..
public function rsfp_f_onAfterStoreSubmissions($args) {
}
what would the Component Builder call name be (assuming it would be based on the component form name somehow ?
This code comes from the CB administrator > models > modelname.php
// Trigger the before save event.
$result = $dispatcher->trigger($this->event_before_save, array($context, &$table, true));
..............
// Trigger the after save event.
$dispatcher->trigger($this->event_after_save, array($context, &$table, true));
Maybe somebody who knows how to work out the function name from that code - if indeed it does what you want - which is to hook a call in after the save process..
Connexion ou Créer un compte pour participer à la conversation.
Ingin Ibiza SL
Nouveau membre
Posts: 1
il y a 2 ans 10 mois #9945
par Ingin Ibiza SL
Réponse de Ingin Ibiza SL sur le sujet on_after_save event
maybe you are lookong the postSaveHook function
It's called after save an element.
It's called after save an element.
Les utilisateur(s) suivant ont remercié: Pete
Connexion ou Créer un compte pour participer à la conversation.
Temps de génération de la page : 0.055 secondes