LoginSignup
10
11

More than 5 years have passed since last update.

FORMからPOSTを配列で送る方法【PHP】

Last updated at Posted at 2012-02-10

HTMLのFORMで、POSTの配列をPHPに送る方法です。

<form name="form" method="POST" action="./test.php">
<input type="checkbox" name="hoge[]" value="0" >No.0<br/>
<input type="checkbox" name="hoge[]" value="1" >No.1<br/>
<input type="checkbox" name="hoge[]" value="2" >No.2<br/>
<input type="checkbox" name="hoge[]" value="3" >No.3<br/>
<input type="checkbox" name="hoge[]" value="4" >No.4<br/>
<input type="reset"/>
<input type="submit"/>

こちらのページで確認できます http://gachihomo.com/test.php

10
11
2

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
10
11