Warning: include_once(/home/sites/heteml/users/m/o/r/moriya-h5/web/confrage/bin/top_msg.php): failed to open stream: No such file or directory in /home/users/2/moriya-h5/web/confrage/php/confirmation/intval/intval.php on line 20
Warning: include_once(): Failed opening '/home/sites/heteml/users/m/o/r/moriya-h5/web/confrage/bin/top_msg.php' for inclusion (include_path='.:/usr/local/php/7.4/lib/php') in /home/users/2/moriya-h5/web/confrage/php/confirmation/intval/intval.php on line 20
目次 |
---|
・数値変換 ・サンプルコード ・サンプル |
(php部) <?php print "強制的に数字に変換されます。(数字以外の文字の場合は「0」)↓"; // 「送信」ボタンが押された時 if (isset($_POST[btnExec])) { print intval($_POST[memo]); } ?>
(html部) <form method="post"> <input type="text" name="memo" size="50"> <input type="submit" name="btnExec" value="送信"> </form>