求助thinkphp3.2,2中为什么jquery效果无效?

浏览:1075 发布日期:2014/09/24 分类:求助交流
<!DOCTYPE html>
<html>
<head>
<script src="http://127.0.0.1/public/static/jquery-2.1.1.min.js">
</script>
<script>
$(document).ready(function(){
  $("p").click(function(){
    $(this).hide();
  });
});
</script>
</head>
<body>
<p>如果您点击我,我会消失。</p>
<p>点击我,我会消失。</p>
<p>也要点击我哦。</p>
</body>
</html>
这是login.html视图文件

大神们这是为什么?这段代码html文件中运行很正常的,有效果,但是控制器中使用就无效<?php
namespace Home\Controller;
use Think\Controller;
class AdminhwController extends Controller {
    
    public function index(){
    
        $this->display();
    }

    public function login(){
    
        $this->display();
    }
}
这是控制器
最佳答案
评论() 相关
后面还有条评论,点击查看>>