zoukankan      html  css  js  c++  java
  • dede调用文章的栏目,作者,发布时间.以及连接数据库输出一个表

    发布时间:
    {dede:field.pubdate function="MyDate('Y-m-d H:i',@me)"/}
    类目:{dede:field.typename/}
    发布人:{dede:field.writer/}

    <?php
    $con=mysql_connect("localhost","root","120911");
    if(!$con)
    {
    die('Could not connect'.mysql_error());
    }
    mysql_select_db("dedecms",$con);

    $result=mysql_query("
    select*from dede_archives where arcrank=-1"
    );

    echo "<table border='1' width='960px' cellpadding='0' cellspacing='1' bordercolor='#eaeaea'>
    <tr bgcolor='#FBFCE2' height='25' align='center'>
    <td>ID</td>
    <td>选择</td>
    <td>文章标题</td>
    <td>更新时间</td>
    <td>类目</td>
    <td>发布人</td>
    <td>操作</td>
    </tr>";
    while($row=mysql_fetch_array($result))
    {
    echo "<tr height='25'>";
    echo "<td align='center'>".$row['id']."</td>";
    echo "<td align='center'><input type='checkbox'></td>";
    echo "<td>".$row['title']."</td>";
    echo "<td align='center'>".$row['pubdate']."</td>";
    echo "<td align='center'>".$row['keywords']."</td>";
    echo "<td align='center'>".$row['writer']."</td>";
    echo "<td align='center'><input type='submit' value='审核通过'></td>";
    echo "</tr>";
    }
    echo "</table>";
    mysql_close();

    ?>

  • 相关阅读:
    jdk git maven Jenkins的配置
    jar包部署脚本
    Mybaits和Spring的那点事
    HashMap三两事
    排序算法学习
    MySQL杂谈
    一个最简单的微服务架构
    SpringBoot全家桶
    nginx上传
    使用xshell在linux服务器上部署node项目
  • 原文地址:https://www.cnblogs.com/275147378abc/p/5088335.html
Copyright © 2011-2022 走看看