请问:php输出div为何不显示

WBOY
Freigeben: 2016-06-13 13:34:10
Original
1366 Leute haben es durchsucht

请教:php输出div为何不显示?

PHP code
<!--

Code highlighting produced by Actipro CodeHighlighter (freeware)
http://www.CodeHighlighter.com/

-->

<?php if(!isset($_POST['username'])) {
    header("location: index.php");
}
if (!$_POST['name']) error("请输入名称"); 
if (!$_POST['name']) error("请输入姓名"); 
if (!$_POST['username']) error("请输入账号"); 
if (!$_POST['password']) error("请输入密码"); 
  $link = @mysql_connect($db_host, $db_user, $db_pwd)
  or die("无法连接资料库<br>" . mysql_errno() . " " . mysql_error());
  mysql_query("SET NAMES '$charset'");
  mysql_select_db($db_name, $link) or die("无法进入资料库$db_name");
  $sql = "SELECT * FROM uc_members where username='$_POST[username]'";
  if (mysql_num_rows(mysql_query($sql, $link)) != 0) error("此账号已经被注册");

  $sql = "INSERT INTO uc_members(bbsname,bbstype,name,username,password,email,regtime,regip,phone,idnumber,address,ps)
  VALUES('$_POST[bbsname]','$_POST[bbstype]','$_POST[name]','$_POST[username]','".md5($_POST['password'])."','$_POST[email]','".date("Y-m-d H:i:s",time()+$time_ctrl*3600)."','$_SERVER[REMOTE_ADDR]','$_POST[phone]','$_POST[idnumber]','$_POST[address]','')";
  $result = @mysql_query($sql, $link) or die("无法新增记录<br>" . mysql_errno() . " " . mysql_error());
  mysql_close($link);
  $html = file_get_contents("$html_dir/reg_ok.htm");
  echo preg_replace("/\\$([a-z0-9\_]+)/sie","$\\1", $html);
$username=$_POST['username'];
$password=$_POST['password'];
$name=$_POST['name'];
$phone=$_POST['phone'];
$idnumber=$_POST['idnumber'];
$address=$_POST['address'];
$email=$_POST['email'];
$copy = $_POST['username'];
$countFile = 0;
$countDir = 0; 
function copyDir($dirFrom,$dirTo){   
    global $countFile;   
    global $countDir;   
    if(is_file($dirTo)){ 
        die("创建失败!");   
    }elseif(is_dir($dirTo)){
        die(" 此 $dirTo 账号已有人申请:请回到<a href="javascript:history.back();">上一页</a>重新输入用户名!");   
    }elseif(!is_dir($dirFrom)){ 
        die(" $dirFrom 不存在!");
    }else{ 
        if(!mkdir($dirTo)){   
            die("发生未知错误,$dirTo 建立失败!有可能权限不足!");   
        }   
        $countDir++;   
    }   
    $handle = opendir($dirFrom);   
    while(($file_name = readdir($handle))!==false ){   
        $file_path_from = $dirFrom.DIRECTORY_SEPARATOR.$file_name;   
        $file_path_to = $dirTo.DIRECTORY_SEPARATOR.$file_name;   
        if($file_name!="." && $file_name!=".."){
            if(is_dir($file_path_from)){
                copyDir($file_path_from,$file_path_to);  
            }else{
                if(!copy($file_path_from,$file_path_to)){   
                    die("$file_path_from的时候发生未知错误,有可能权限不足!");   
                }   
                $countFile++;
            }   
        }   
    }   
    closedir($handle);
}   
copyDir("client","$copy");

echo "<div class='\"main_center' minwidth>
    <div class='\"main_middle\"'>
        <div class='\"main_checking\"'>
            <div class='\"main_checking01\"'>
                <div class='\"main_checking01fl\"'></div>
                <div class='\"main_checking01f\"'>
                    <div class='\"main_checking01fr_title\"'>创建成功:建立 $countFile 个文件!</div>
                </div>
            </div>
        </div>
    </div>
</div>";
?>

Nach dem Login kopieren



为什么这段不能显示呢?

PHP code
<!--

Code highlighting produced by Actipro CodeHighlighter (freeware)
http://www.CodeHighlighter.com/

-->
echo "<div class='\"main_center' minwidth>
    <div class='\"main_middle\"'>
        <div class='\"main_checking\"'>
            <div class='\"main_checking01\"'>
                <div class='\"main_checking01fl\"'></div>
                <div class='\"main_checking01f\"'>
                    <div class='\"main_checking01fr_title\"'>创建成功:建立 $countFile 个文件!</div>
                </div>
            </div>
        </div>
    </div>
</div>";
 <div class="clear">
                 
              
              
        
            </div>
Nach dem Login kopieren
Verwandte Etiketten:
Quelle:php.cn
Erklärung dieser Website
Der Inhalt dieses Artikels wird freiwillig von Internetnutzern beigesteuert und das Urheberrecht liegt beim ursprünglichen Autor. Diese Website übernimmt keine entsprechende rechtliche Verantwortung. Wenn Sie Inhalte finden, bei denen der Verdacht eines Plagiats oder einer Rechtsverletzung besteht, wenden Sie sich bitte an admin@php.cn
Beliebte Tutorials
Mehr>
Neueste Downloads
Mehr>
Web-Effekte
Quellcode der Website
Website-Materialien
Frontend-Vorlage