标签:lod set bsp pre blog html hello ade 中文乱码
第一种是添加html标签变为如下格式:
<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> </head> <body> <?php $array = array("12",345); echo is_array($array); $atr = "北京 顺平 天津 宋江"; $str = explode(" ", $atr); foreach($str as $hello) { echo $hello; } ?> </body> </html>
第二种是直接在PHP文本中添加:
header("content-type: text/html; charset=utf-8");
<?php header("content-type: text/html; charset=utf-8"); $array = array("12",345); echo is_array($array); $atr = "北京 顺平 天津 宋江"; $str = explode(" ", $atr); foreach($str as $hello) { echo $hello; } ?>
标签:lod set bsp pre blog html hello ade 中文乱码
原文地址:http://www.cnblogs.com/zhichun/p/7223695.html