Partial fix Contact Form

xf_phantom

Well-known member
Aren't the redirect variable and the data-redirect tag (or how would you call this?*g*) missing in the form?

The controller sets the redirect template parameter, but i had to add it myself to the form and also change

HTML:
<form action="{xen:link 'misc/contact'}" method="post" class="xenForm formOverlay AutoValidator">
to
HTML:
<form action="{xen:link 'misc/contact'}" method="post" class="xenForm formOverlay AutoValidator" data-redirect="on">



to get the redirect working
 
Last edited:
Maybe he does not want to redirect because redirect does nothing in this case?
if it's a overlay, it shouldn't redirect, that's true, but if the user doesn't use js, he'll not be redirected to the page he's comming from. He will stick on the contactform after the form was sent (without any notice, the contact page will just reload..)
 
if it's a overlay, it shouldn't redirect, that's true, but if the user doesn't use js, he'll not be redirected to the page he's comming from. He will stick on the contactform after the form was sent.
Do not worry. If he does not use JS then AutoValidator would not be called anyway :D
 
Do not worry. If he does not use JS then AutoValidator would not be called anyway :D
yes, but because the form doesn't submit the redirect url, the controller will just redirect him back to the contact form

try it out

and then add
Code:
<input type="hidden" name="redirect" value="{$redirect}" />

to the form and try it again:)
 
I have added the hidden redirect input, but the lack of data-redirect is correct. The contact form is opened with an overlay by default so it shouldn't redirect.
 
Back
Top Bottom