Hi,
I seem to be overlooking something when attempting to override the 'add' action of thewire plugin. In my plugins start.php init function I have:
elgg_register_action('thewire/add', __DIR__, . '/actions/thewire/add.php');
I have copied the ../vendor/elgg/elgg/mod/thewire/actions/add.php to my /var/www/html/mod/myplugin/actions/thewire/ directory and given all of the appropriate permissions on the file. I've added a few debug lines near the top of the file just to see if the action is registered correctly, but whenever I go to post a wire it seems my action isn't getting hit. Any help would be appreciated. I'm using elgg 2.3.14.
info@elgg.org
Security issues should be reported to security@elgg.org!
©2014 the Elgg Foundation
Elgg is a registered trademark of Thematic Networks.
Cover image by RaĆ¼l Utrera is used under Creative Commons license.
Icons by Flaticon and FontAwesome.
- Nikolai Shcherbin@rivervanrain
Nikolai Shcherbin - 0 likes
- TCB@tblack06
TCB - 0 likes
- Nikolai Shcherbin@rivervanrain
Nikolai Shcherbin - 0 likes
- TCB@tblack06
TCB - 0 likes
- TCB@tblack06
TCB - 0 likes
You must log in to post replies.Try this:
Hint: Check your server's error log before creating new discussion.
RvR sorry for the confusion... I actually typed it incorrectly in my post. I didn't actually have that extra ',' after __DIR__ in my code :-|. There are no errors in my server log.. I actually wish it was just a typo.
elgg_register_action('thewire/add', __DIR__ . '/actions/thewire/add.php');
Ok. In this case try to do it:
1 - Place your plugin after 'thewire' plugin (via Plugins in Administration)
2 - Add additional hook in your start.php before registering custom action:
3 - Run 'Flush the caches'
ahhhhh... ok I will give that a try.
That worked.. thanks.. gotta remember that part about moving up the plugin.