I need to use a widget on the sidebar of a plugin, can i do that???
I'm trying this:
elgg_extend_view('page/elements/sidebar','event_manager/views/default/events/content');
(Plugin: Event Manager)
But that doesn't work.
Any ideas???
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.
- Matt Beckett@Beck24
Matt Beckett - 0 likes
- Angel Cruijff@Angel_Cruijff
Angel Cruijff - 0 likes
- Team Webgalli@webgalli
Team Webgalli - 0 likes
You must log in to post replies.you might be able to replicate the contents that way, it wouldn't be a widget in the full sense of it - ie. it wouldn't have the editable options or be able to move. Also keep in mind though, that the view may rely on $vars to be passed to it, including $vars['entity'] which would be the widget object itself...
Ok, I'll keep that in mind. The code above doesn't work, it doesn't show anything. I'm not interested in the full widget functionality, just the content of that widget.
Maybe, I need to do the functionality of that widget on a plugin instead of use the widget :/
Your code is wrong. You dont have to include the view path. Just call it like
Everything inside views can be called, just by the above call. But remember that elgg treats each widget as an entity and the contents to display depend on many properties like widget owner, number of items to display etc..