样式回声输出不起作用

时间:2017-10-29 13:25:53

标签: php html css

我想设置代码的输出样式。

CSS:

.wrapper{
    width: 60%;
    right: 0px;
    min-height: 560px;  
    margin: 0px auto;   
    width: 500px;
    position: relative; 
}

HTML / PHP:

    <div class="wrapper">
    <?php if ($re) echo "welcome to

     thescrow $username,Your Registration was successfull"; ?>
    <?php } ?>
</div>

但输出仍然很明显。我没有看到任何错误。请更正代码。我是这一切的新手,无法弄清楚。

编辑:(完整的php)

<?php
//our included config file
include "config.php";

//check whether data with the name usename has been submitted
if (isset($_POST['username'])) {
    //variables to hold our submitted data with post
    $email = $_POST['email'];
    $username = $_POST['username'];
    $password = md5($_POST['password']);
        $hash=md5( rand(0,1000) ); 
    //our sql statement that we will execute
    $sql = "INSERT INTO `user` (`id`, `username`, `email`, `password`,`hash`) VALUES (NULL, '$username', '$email', '$password','$hash')";

    //Executing the sql query with the connection
    $re = mysqli_query($con, $sql);

    //Check to see whether request was true or false
    ?>

    <div class="to_register">
    <?php if ($re) echo "welcome to

     thescrow $username,Your Registration was successfull"; ?>
    <?php } ?>
</div>

0 个答案:

没有答案