Skip to content

Instantly share code, notes, and snippets.

@keisukemizuno
Created February 6, 2015 06:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save keisukemizuno/7eff1495f3a199465d07 to your computer and use it in GitHub Desktop.
Save keisukemizuno/7eff1495f3a199465d07 to your computer and use it in GitHub Desktop.
[Contact Form 7 4.1] 確認用メールアドレスのエラーチェック(最新版対応) ref: http://qiita.com/keisukemizuno@github/items/6816ed6f7d5e474a324e
<p>メールアドレス<br />
[email* your-email] </p>
<p>メールアドレス (確認用)<br />
[email* your-email_confirm] </p>
<?php
function wpcf7_text_validation_filter_extend( $result, $tag ) {
...
 //$result['reason'][$name] = '確認用のメールアドレスが一致していません';
 //上記記述を以下のように書き換えます。
 $result['reason'] = array( $name => '確認用のメールアドレスが一致していません' );
...
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment