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.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

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

Prototype responseText question (static publisher)


Reply


697 Views

Avatar
martimiz

Forum Moderator, 1132 Posts

16 September 2009 at 8:02pm

Hi all,
When using StaticPublisher, the prototype request will usually return a responseText like this:

$('Form_EditForm').loadActionsFromString('<input class=\"action delete\" id=\"Form_EditForm_action_unpublish\" type=\"submit\" name=\"action_unpublish\" value=\"Publicatie intrekken\" title=\"Publicatie intrekken\" /> <input class=\"action delete\" ...


But somehow with a specific Pagetype, it returns the page in HTML format instead, creating a JavaScript Parse Error. My question: does anyone know where the decision to request either HTML or the format above is made?

In this case I'm referring to the ImageGallery module (see: http://www.silverstripe.org/all-other-modules/show/250910?showPost=269126), but I thought to ask here as well, since it's a more general question...