小编Gle*_*en 的帖子

我的PHP代码只是我的html中的注释

对不起,伙计们这可能很简单,但我现在已经太晚了.我有一个基本的html页面,上面有一些javascript,当我尝试将任何php放入正文时,它会将其作为注释读取.

    <html>
    <head>
    <link rel="stylesheet" href="style.css" type="text/css" media="screen">
    <script type="text/javascript" src="jquery-1.3.2.min.js"></script> 
    <script type="text/javascript" src="jquery.tablesorter.min.js"></script> 
    <script type="text/javascript" src="jquery.tablesorter.pager.js"></script> 
     <script type="text/javascript">
     $(function() {
      $("table")
       .tablesorter({widthFixed: true, widgets: ['zebra']})
       .tablesorterPager({container: $("#pager")});
     });
     </script>
    </head>
    <body>
    <div id="main">
    <h1>Demo</h1>

    php in here

    <?php  
    echo "test php";
    ?>

...
main code for a table here
</div>
</body>
</html>
Run Code Online (Sandbox Code Playgroud)

html javascript php comments

2
推荐指数
1
解决办法
1688
查看次数

标签 统计

comments ×1

html ×1

javascript ×1

php ×1