Will data order in post form be the same to it in web form?

后端 未结 6 532
春和景丽
春和景丽 2021-01-13 00:25

Assuming there are 5 inputs in web form





        
6条回答
  •  臣服心动
    2021-01-13 00:45

    Better way to do in html:

    
    

    Then in server:

    $the_same = new array();
    foreach($_POST['the_same'] as $data) // or $_GET if you prefer
        $the_same[] = $data;
    

    In this way no variable will be overwrite.

提交回复
热议问题