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.

Archive /

Our old forums are still available as a read-only archive.

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

TreeDropdownField()


Reply


942 Views

Avatar
OzziNL

Community Member, 37 Posts

28 December 2007 at 10:50am

Edited: 28/12/2007 11:16am

Hello,
I have a page type with some fields and one of the fields should be a url to another page in the tree. I use:

$fields->addFieldsToTab('Root.Content.Banners', new TreeDropdownField('Banner1Url','Link','SiteTree','URLSegment'));

This works fine but when saved and I return to the page I get an error as attached. It tries to do a get_by_id with the non-nummeric URLSegment. Am I doing something wrong?

Thanks a lot...