Home  >  Article  >  Backend Development  >  PHP跳转菜单读取值有关问题

PHP跳转菜单读取值有关问题

WBOY
WBOYOriginal
2016-06-13 13:14:53863browse

PHP跳转菜单读取值问题
我把的值的方法呢?

------解决方案--------------------
select返回的就只指定的值。是不是select的name用加了[]

PHP code


 


<?php if(isset($_POST['abc']))
{
var_dump($_POST['abc']);

var_dump($_POST);
}else  
{
 echo ('
<form action="'.$_SERVER['PHP_SELF'].'" method="post">
 <select name="abc">
    <option value="1">1</option>
    <option value="2">2</option>
    <option value="3">3</option>
 </select>
<input type="submit" value="submit">
');
}
?>


<br><font color="#e78608">------解决方案--------------------</font><br>你是怎么写的代码?
<br><font color="#e78608">------解决方案--------------------</font><br>用js就能获取
<br><font color="#e78608">------解决方案--------------------</font><br>两次foreach <div class="clear">
                 
              
              
        
            </div>

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn