Home >Backend Development >PHP Tutorial > php代码求分析,该如何处理

php代码求分析,该如何处理

WBOY
WBOYOriginal
2016-06-13 12:45:24762browse

php代码求分析

<br />
echo join(' - ', $_GET), '<br>';  // ①<br />
$dict = array(<br />
  'area' => array('内地', '港台'),<br />
  'type' => array('动作', '爱情'),<br />
  'year' => array('2001', '2013'),<br />
);<br />
foreach($dict as $key=>$item) {<br />
  $param = $_GET;                 //②<br />
  foreach($item as $v) {<br />
    $param[$key] = $v;             //③<br />
    $t = http_build_query($param); //④<br />
    echo "<a href='/search.php?$t'>$v</a> ";<br />
  }<br />
  echo '<br>';<br />
}



第①句什么意思,有什么作用?
第②句把GET赋值有会用特别的用意?直接用就挺好嘛?
第③什么意思呢/
第④句什么意思呢,因为感觉好像第三句没什么意义。。。。。。谢谢

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