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.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

Widgets /

Discuss SilverStripe Widgets.

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

WidgetAreaEditor not saving its instance ID on Page Type


Go to End


2 Posts   2391 Views

Avatar
Wellfire

Community Member, 1 Post

14 May 2009 at 4:26pm

Currently have extended the WidgetArea to appear on other pages. I get the WidgetAreaEditor showing up in the CMS correctly, and newly placed widgets get saved to the correct WidgetArea.

However, the Page that contains this widget area (Sidebar) does not update with the correct WidgetArea ID (SidebarID) and instead remains with a value of 0. I've tried to force it using write, onBeforeWrite, and onAfterWrite, but I can't get it to work correctly. The closest I've gotten is to force every single Page to have the same widgetArea, which is not what I want or need.

Any help on associating the new widgetArea and its ID with the containing Page would be greatly appreciated!

Avatar
FungshuiElephant

Community Member, 57 Posts

15 May 2009 at 11:48am

Edited: 26/05/2009 2:43am

Not really sure I understand what you mean, better start off with some basics...

What version of SS are you running?
How have you extended the WidgetArea? Do you mean that you've modified a page to include a WidgetArea?
Can you post a picture showing what you mean, with the associated code?

I think that the WidgetAreaId will probably be the same for all pages of a given type. It will only be the widgets within it that change. So it may be that what you are experiencing is correct. What are you trying to do?

More questions than answers so far!