Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

Widgets /

Discuss SilverStripe Widgets.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Widget fails when put with other widgets


Reply


2 Posts   658 Views

Avatar
NETim

Community Member, 24 Posts

25 October 2012 at 5:45am

Hi,

I have just added a widget area to a site. The problem is that when I add other widgets in with a custom widget, the custom widget will fail if it is not the first widget in the list.

The custom widget is simply a list of month data objects with a control statement in the template.

Any ideas why this may be happening?

Cheers,

T.

Avatar
Matty Balaam

Community Member, 69 Posts

26 November 2012 at 12:33pm

Edited: 26/11/2012 12:33pm

I sometimes have issues with some code in 'class fooWidget extends Widget'.

Instead I place this code into 'fooWidget_Controller extends Widget_Controller'

Give that a try if you haven't already.