Shortcode in loading php file.
-
Hi, Im sorry if this question is duplicated but I’ve been searching but can not find any solution yet.
To receive post data in dynamic field I put my CF7 shortcode in a file form.php and use ajax to load it in my page, it works but my form doesnt have normal behavior like when I put it in page ?– If I fill correct all fields, click submit, it still redirect to action attribute url, not showing any status (success or not) but email is sent.
– If I do not fill any fields but click on submit, it still redirect to the action attribute url which is “/wp-content/themes/child/form.php” (this is a file I put shortcode in not a page). email is not sent.I’ve tried to set action=”” or action=”currentpage.com”
anybody knows how to fix to make it have normal behavior like validation and show status & not redirect? or do you think I should do another method?
- The topic ‘Shortcode in loading php file.’ is closed to new replies.