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();

    ?>

  • 相关阅读:
    VSCode 配置 Python 开发环境
    出现:Microsoft Visual C++ 14.0 is required 的解决方案
    python3 pathlib库中的Path类的使用
    使用 AI 绘制箭头
    Adobe Illustrator 入门 新建 保存图片
    jinja2
    Java 读取和写入文本文件
    Affy包 estrogen包
    GEOquery
    apply() 函数家族介绍
  • 原文地址:https://www.cnblogs.com/275147378abc/p/5088335.html
Copyright © 2011-2022 走看看