分类
- WPBOSS使用教程 (5)
- 技术博客 (15)
- 外贸建站故事 (0)
只需要在代码里加入下面的代码即可:
<script>
document.addEventListener( 'wpcf7mailsent', function( event ) {
location = 'http://example.com/';
}, false );
</script>
支持的监听事件:
wpcf7invalid
— Fires when an Ajax form submission has completed successfully, but mail hasn’t been sent because there are fields with invalid input. 当已经提交表单成功但是有不无效的字段的时候触犯发此事件。wpcf7spam
— Fires when an Ajax form submission has completed successfully, but mail hasn’t been sent because a possible spam activity has been detected. 垃圾邮件。wpcf7mailsent
— Fires when an Ajax form submission has completed successfully, and mail has been sent. 成功发送时。wpcf7mailfailed
— Fires when an Ajax form submission has completed successfully, but it has failed in sending mail. 发送失败时。wpcf7submit
— Fires when an Ajax form submission has completed successfully, regardless of other incidents. 提交后。