1 alexmagik Nov 28, 2006 14:53
3 edb Nov 28, 2006 15:09
AlexMagik wrote:
Hello,
i'm very new in b2e, and i already develop 2 plugins for myself for the public part...
Are you planning on sharing these plugins with everyone else?
4 yabba Nov 28, 2006 15:21
EdB wrote:
Are you planning on sharing these plugins with everyone else?
Do you want an rss plugin? I'm sure I've got a mostly finished one lying around somewhere?
¥
5 blueyed Nov 28, 2006 20:56
¥åßßå, is right about the events.
You'll find more documentation at http://doc.b2evolution.net/v-1-8/plugins/Plugin.html
(please don't hijack this thread :p)
6 alexmagik Nov 29, 2006 11:23
Thanks guys, this eve i am going to try to see if works :)
For the request to public my plugins... well, i need to clean them up first, if you look at them now, they work, but they are so ugly and messy :) when i done with this new plugin, i will clean the others up and then i may release them (if the customer who is paying me for make them will agree) :)
7 alexmagik Nov 29, 2006 16:31
i've a problem...
the 2 functions are called BEFORE the update/insert...
and it's fine for the update, but for the insert, my plugin is supposed to insert in another table some extra data, but in this case i can't because after i will not be able to know how to connect the 2 records...
for example, i do the insert of a new post, but how will i be able to know the post_id in the BEFORE function for insert my data in the secondary "extention" table?
8 yabba Nov 29, 2006 16:59
Try :-
'AfterItemInsert' => '',
'AfterItemUpdate' => '',
¥
9 alexmagik Nov 29, 2006 17:45
this is weird :)
i create the toolbar (and i can see it in the write/edit).
the issue seems that the functions "AfterItemUpdate"/"AdminBeforeItemEditUpdate" and the create ones as well, are never called... :(
should i set some special configuration in the plugin for run these? in the plugin properties the functions are enabled to be run, the render is "never".
EDIT: fixed... seems to be a problem with some other functions :) tooked away the AdminEndHtmlHead, and now it start working :)
10 blueyed Nov 29, 2006 18:22
AlexMagik, if you've added the methods into your plugin, you have to reload the plugins (see the link below the list of installed plugins), so that b2evo knows that the plugin hooks the new events.
As an alternative (or in case of releasing a plugin with added hooks), bump the version of the plugin - this will also reload the events.
11 alexmagik Nov 30, 2006 01:27
thank you guys,
the plugin is working using the AfterItemUpdate/AfterItemCreate/AfterItemDelete
a bit of tuning on my code and will be done :)
Thank you very much :)
Hi,
If you take a look in inc/misc/_plugins.class.php you can find a list of all of the hooks available to plugins. These are the ones available in 1.8.5
The one's you'll "probably" want to look into are these two :-
¥