亚洲国产日韩欧美一区二区三区,精品亚洲国产成人av在线,国产99视频精品免视看7,99国产精品久久久久久久成人热,欧美日韩亚洲国产综合乱

小張
Follow

After following, you can keep track of his dynamic information in a timely manner

Course notes
  • Courses in the relevant section:Database construction for PHP development login page

    <?php header("Content-type:text/html;charset=utf-8"); $servername="localhost"; $username="root"; $password=""; $conn = mysqli_connect($servername,$username,$password); mysqli_set_charset($conn,'utf8'); if(!$conn){ die("鏈接失敗:" . mysqli_connect_error()); } $sql = "CREATE DATABASE login"; if(mysql_query($conn,$sql)){ echo "數(shù)據(jù)庫(kù)創(chuàng)建成功"; }else{ echo "數(shù)據(jù)庫(kù)創(chuàng)建失敗:" . mysql_error($conn); } mysqli_close($conn); ?>

    2018-05-100個(gè)贊

  • Courses in the relevant section:Database Design

    create database onecms;//創(chuàng)建數(shù)據(jù)庫(kù) create table message( id int(11) not null primary key auto_increment, title varchar(255) NOT NULL, content text NOT NULL) ENGINT=innoDB DEFAULT CHARSET=utf8;

    2018-05-090個(gè)贊

  • Courses in the relevant section:Add function to message page

    <form action="insertdb.php" method="post"> 標(biāo)題:<input type="text" id="title" name="title"><br> 內(nèi)容:<br><span><textarea name="content" rows="13" cols="80" id="content"></textarea> <script> KindEditor.ready(fonction(K){ window.editor = K.create('#content',{ afterBlur:function(){this.sync(); } }) }) </script> </span> <input type="submit" name="dosub" id="btn" value="上傳留言"> </form>

    2018-05-090個(gè)贊

  • Courses in the relevant section:Database Connectivity

    <?php //conn.inc.php define("HOST",'localhost'); define("USER",'root'); define("PWD",'root'); ?> <?php //mysqli.php include 'conn.inc.php'; $mysqli=new mysqli(HOST,USER,PWD,DBNADM); if($mysqli->connect_errno){ die('數(shù)據(jù)庫(kù)鏈接出錯(cuò)'.$mysqli->connect_error); } ?>

    2018-05-090個(gè)贊

  • Courses in the relevant section:Message page display function

    include 'mysqli.php'; $sql="select * from message"; $result=$mysqli->query($sql); if($result->num_rows>0){ while($row=$result->fetch_assoc()){ $arr[$row["id"]]["title"]=$row["title"];//$arr[1]["title"]=$row["title"] $arr[$row["id"]]["content"]=$row["content"];//$arr[1]["content"]=$arr["content"] } } echo json_encode($arr);

    2018-05-090個(gè)贊