Tony Thonglam KDTony
Tony Thonglam KDTony

Reputation: 21

SilverStripe Ajax and Page Controllers

I have a very short question regarding Silverstripe. I have not found a solution anyway on the internet or here. I currently have a form on SS4 that when submit it will run an AJax request and render new content (page). The problem I have is that the content does not display and it seems to be related to the fact that the content that is rendered in is managed by a different Page controller. So it could not find the content when rendering through Ajax from another page. How would I resolve this without refreshing the page ?

Thanks in advance !

Upvotes: 0

Views: 160

Answers (1)

mikeyc7m
mikeyc7m

Reputation: 93

you would submit to the same page, which has a function to generate/return the new page. note that when submitting via ajax you need to include the FormAction button in the submitted fields.

Upvotes: 0

Related Questions