源文件代码是
文件名:a\Home\Controller\UserController.class.php
<?php
namespace Home\Controller;
use Think\Controller;
class UserController extends Controller {
public function login(){
$this -> display();
//echo '大家好';
}
}
文件名:a\View\User\login.html
无标题文档
welcome
文件名:a\index.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
欢迎Thinkphp
<?php
define('APP_DEBUG',true);//开发调试模式
//define('APP_DEBUG',false);
include("../ThinkPHP/ThinkPHP.php");
?>
运行 http://localhost/thinkphp3/a/index.php/Home/User/login
出现乱码,查看html代码
{<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
�ޱ����ĵ�
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
无标题文档
welcome
}
为什么运行出来的时候,我点查看源码出现两个4个html标签呢?正常应该是2个html啊!