A
account8226
Guest
Hello,
I am having trouble with my forms, I have an action, and data-fieldValidatorUrl, with data-redirect on off.
When I submit my form :
If there is an error, it's working fine, a nice XenForo's error popup is showing up with the following code :
But when everything goes fine, I would like the page to refresh, but it's actually returning a javascript error, here is the result with firebug :
Here is the final return code :
How can I return a simple message as a popup for example ? That would say everything was fine, do I have to use javascript ?
Regards.
I am having trouble with my forms, I have an action, and data-fieldValidatorUrl, with data-redirect on off.
When I submit my form :
If there is an error, it's working fine, a nice XenForo's error popup is showing up with the following code :
PHP:
$this->responseError(new XenForo_Phrase('error'));
But when everything goes fine, I would like the page to refresh, but it's actually returning a javascript error, here is the result with firebug :
PHP ?> {"status":"ok","message":" [........]
Here is the final return code :
PHP:
$redirectUrl = XenForo_Link::buildPublicLink('my_link');
return $this->responseRedirect(
XenForo_ControllerResponse_Redirect::SUCCESS,
$redirectUrl,
new XenForo_Phrase('my_text')
);
How can I return a simple message as a popup for example ? That would say everything was fine, do I have to use javascript ?
Regards.