码迷,mamicode.com
首页 > 其他好文 > 详细

如何获取表头,如何获取表头,如何获取表头,!!

时间:2016-07-24 10:38:29      阅读:132      评论:0      收藏:0      [点我收藏+]

标签:

//取得表头
$stamt1=$pdo->prepare("SHOW COLUMNS FROM shop");
$stamt1->execute();
while ($c1=$stamt1->fetch(PDO::FETCH_NUM)){
    $list1[]=$c1;
}
var_dump($list1);
//取得表头
echo  "<table border=1>";
echo "<th>{$list1[0][0]}</th>";
echo "<th>{$list1[1][0]}</th>";

 

如何获取表头,如何获取表头,如何获取表头,!!

标签:

原文地址:http://www.cnblogs.com/h-g-f-s123/p/5700163.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!