php join函数应用

前端之家收集整理的这篇文章主要介绍了php join函数应用前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

<div class="codetitle"><a style="CURSOR: pointer" data="56356" class="copybut" id="copybut56356" onclick="doCopy('code56356')"> 代码如下:

<div class="codebody" id="code56356">
$key = array();
$val = array();
foreach ($_POST as $k=>$v)
{
$key[] = ''.strip_tags(<a href="https://www.jb51.cc/tag/MysqL/" target="_blank" class="keywords">MysqL</a>_real_escape_string(trim($k))).'';
$val[] = "'".strip_tags(MysqL_real_escape_string(trim($v)))."'";
} $keys = join(",",$key);
$vals = join(",$val);

原文链接:https://www.f2er.com/php/28006.html

猜你在找的PHP相关文章