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

PHP開發(fā)文章發(fā)布系統(tǒng)之后臺添加頁面

添加頁面

后臺添加頁面大概布局如下:

后臺發(fā)布布局.png

代碼如下:

<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no"> 
 <meta name="format-detection" content="telephone=no" /> 
<title>發(fā)布文章</title>
<meta charset="utf-8" />
    <style>
    .box{
        background-color:#f0f0f0;
    }
    .title{
        background-color:#f0f0f0;
        width:400px;
        height:100px;
        border-bottom:1px solid black;
    }
    .menu{
        margin:-25px 0px 1px 319px;
        width:80px;
    }    
    .middle{
        border-bottom:1px solid black;
    } 
    .bottom{
    }    
    </style>
</head>
<body>
<div class="box">
    <div class="title">
        <h1>后臺管理系統(tǒng)</h1>
        <div class="menu">
            <a href="admin_add.php">發(fā)布文章</a><br/>
            <a href="admin_manage.php">管理文章</a>
        </div>
    </div>
    <div class="middle">
            <form method="post" action="admin_add_handle.php">
                <div><h2>發(fā)布文章</h2></div>
                <div>標題:<input type="text" name="title" /></div><br/>
                <div>作者:<input type="text" name="author" /></div><br/>
                <div>簡介:<br/><textarea name="description" cols="50" rows="4"></textarea></div><br/>
                <div>內容:<br/><textarea name="content" cols="50" rows="9" ></textarea></div><br/>
                <div><input type="submit" name="button" value="提交" /></div><br/>
            </form>
    </div>
    <br/><div class="bottom">歡迎聯(lián)系我們<a href="http://ipnx.cn">php中文網</a></div>
</div>
</body>
</html>


注釋

  • 主要使用了DIV+CSS的布局方式,由于我們主要是介紹功能,所以頁面比較簡陋,有興趣的同學可以試著去美化這個頁面

  • 添加頁面的核心主要在form表單里面,通過post方式提交給文章添加處理程序(admin_add_handle.php)

  • 簡介和內容都使用了<textarea>標簽

繼續(xù)學習
||
<!DOCTYPE html> <html> <head> <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no"> <meta name="format-detection" content="telephone=no" /> <title>發(fā)布文章</title> <meta charset="utf-8" /> <style> .box{ background-color:#f0f0f0; } .title{ background-color:#f0f0f0; width:400px; height:100px; border-bottom:1px solid black; } .menu{ margin:-25px 0px 1px 319px; width:80px; } .middle{ border-bottom:1px solid black; } .bottom{ } </style> </head> <body> <div class="box"> <div class="title"> <h1>后臺管理系統(tǒng)</h1> <div class="menu"> <a href="admin_add.php">發(fā)布文章</a><br/> <a href="admin_manage.php">管理文章</a> </div> </div> <div class="middle"> <form method="post" action="admin_add_handle.php"> <div><h2>發(fā)布文章</h2></div> <div>標題:<input type="text" name="title" /></div><br/> <div>作者:<input type="text" name="author" /></div><br/> <div>簡介:<br/><textarea name="description" cols="50" rows="4"></textarea></div><br/> <div>內容:<br/><textarea name="content" cols="50" rows="9" ></textarea></div><br/> <div><input type="submit" name="button" value="提交" /></div><br/> </form> </div> <br/><div class="bottom">歡迎聯(lián)系我們<a href="http://ipnx.cn">php中文網</a></div> </div> </body> </html>
提交重置代碼