成人无码视频,亚洲精品久久久久av无码,午夜精品久久久久久毛片,亚洲 中文字幕 日韩 无码

資訊專欄INFORMATION COLUMN

028、HTML 標(biāo)簽3表單標(biāo)簽插入組件

番茄西紅柿 / 3370人閱讀

摘要:屬性用于明確提交的方式。提交,將提交的數(shù)據(jù)顯示在地址欄。提交,提交敏感信息安全。區(qū)別數(shù)據(jù)的體積。提交,將提交信息封裝到了請求行。和服務(wù)端交互有三種方式,地址欄輸入。

內(nèi)容:表單標(biāo)簽插入組件(經(jīng)常使用)
##############################################################

form表單標(biāo)簽和input組件
<form>
    用戶名稱:<input type="text" name="username" value="hehe" /><br/>
    輸入密碼:<input type="password" name="psw" /><br/>
    選擇性別:<input type="radio" name="sex" value="nan" /><input type="radio" name="sex" value="nv" checked="checked"/><br/>
    選擇技術(shù):<input type="checkbox" name="tech" value="java" />JAVA
            <input type="checkbox" name="tech" value="html" />HTML
            <input type="checkbox" name="tech" value="css" />CSS<br/>
    一個按鈕:<input type="button" value="有個按鈕" onclick="alert(有個按鈕,我彈!)"/><br/>
    隱藏組件:<input type="hidden" name="zhangsan" value="20"/><br/>        
    選擇文件:<input type="file" name="file" /><br/>
    圖片組件:<input type="image" src="1.jpg" /><br/>
    
    選擇國家:
    <select name="country">
        <option value=none>--選擇國家--option>
        <option value="cn" selected="selected">中國option>
        <option value="usa">美國option>
        <option vaue=en>英國option>
    select>
    <br/>
    個人介紹:<textarea rows="4" cols="20">textarea>
    <input type="submit" value="提交"/><input type="reset" value="恢復(fù)默認"/>

form>


如果這些值需要提交到服務(wù)端的,每個組件的屬性都需要name




####################################################################################
瀏覽器兩種提交方式
以下get和post提交數(shù)據(jù)來自代碼




#############################################
加入表格標(biāo)簽,好看,下面實現(xiàn)簡單提交

<body>
<form action="127.0.0.1:8080" method="get">
    <table border="1" bordercolor="blue" width="700px" cellspacing="0" cellpadding="10">
        <tr>
            <th colspan="2">用戶注冊th>
        tr>
        <tr>
            <th>用戶名稱:th>
            <td><input type="text" name="usename">td>
        tr>
        <tr>
            <th>輸入密碼:th>
            <td><input type="password" name="pwd">td>
        tr>
        <tr>
            <td>選擇性別:td>
            <td><input type="radio" name="sex" value="male"/><input type="radio" name="sex" value="female">td>
        tr>
        <tr>
            <td>選擇技術(shù):td>
            <td><input type="checkbox" name="tech" value="java">java
                <input type="checkbox" name="tech" value="HTML">HTML
                td>
        tr>
        <tr>
            <td>一個按鈕td>
            <td><input type="button" value="按鈕" onclick="alert(love)">td>
        tr>
        <tr>
            <th colspan="2"><input type="submit" value="提交">th>
        tr>
    table>

form>
body>

 

##簡單服務(wù)器用于執(zhí)行上面的提交:

public static void main(String[] args) throws IOException
{
    ServerSocket ss = new ServerSocket(8080);
    Socket s = ss.accept();
    InputStream is = s.getInputStream();
    byte[] buf = new byte[1024];
    int len = is.read(buf);
    String str = new String(buf,0,len);
    System.out.println(str);
    
    PrintWriter out = new PrintWriter(s.getOutputStream(),true);
    out.println("注冊成功");
    
    s.close();
    ss.close();
}

 

 

############################################################################
其他標(biāo)簽

<meta http-equiv="Content-Type" content="text/html; charset=utf-8">

<body>
<b>演示b><i>一下i><u>其他u><strong>標(biāo)簽strong>。語義化
X<sub>2sub>  X<sup>2sup>
<marquee behavior="slide" direction="down">哇,我會飛啦!marquee>
<pre>
class Demo
{
    public static void main(String[] args)
    {
        System.out.println("hello");
    }
}
pre>
body>

 

文章版權(quán)歸作者所有,未經(jīng)允許請勿轉(zhuǎn)載,若此文章存在違規(guī)行為,您可以聯(lián)系管理員刪除。

轉(zhuǎn)載請注明本文地址:http://m.hztianpu.com/yun/1572.html

相關(guān)文章

  • 028、HTML 標(biāo)簽2超鏈接,框架標(biāo)簽

    摘要:內(nèi)容超鏈接,框架標(biāo)簽超鏈接聯(lián)系我們變形金剛變形金剛迅雷下載超鏈接定位標(biāo)記,比如返回頂部位置頂部位置這里定義名字返回頂部表示本頁面的那個名字位置取消默認的點擊事件,加入新的操作框架標(biāo)簽框架標(biāo)簽的特點可以將瀏覽器窗口內(nèi)容:超鏈接,框架標(biāo)簽############################################################## baidu.com ...

    番茄西紅柿 評論0 收藏0
  • 動態(tài)生成form表單,不再為表單煩惱

    摘要:具有數(shù)據(jù)收集校驗和提交功能的表單生成器,支持雙向數(shù)據(jù)綁定和事件擴展,組件包含有復(fù)選框單選框輸入框下拉選擇框等表單元素以及省市區(qū)三級聯(lián)動時間選擇日期選擇顏色選擇滑塊評分框架樹型文件圖片上傳等功能組件。 form-create 具有數(shù)據(jù)收集、校驗和提交功能的表單生成器,支持雙向數(shù)據(jù)綁定和事件擴展,組件包含有復(fù)選框、單選框、輸入框、下拉選擇框等表單元素以及省市區(qū)三級聯(lián)動,時間選擇,日期選擇,...

    kamushin233 評論0 收藏0
  • VUE

    摘要:注意指令前面需要加,對指令傳遞數(shù)據(jù)賦值使用例如約定速成加上,表示自定義指令不要使用駝峰式命名。需要通過方法實現(xiàn)自定義指令注冊完成。 vue Vue.js 構(gòu)建數(shù)據(jù)驅(qū)動的web界面庫。集中實現(xiàn)MVVM 的 VM層。容易與其他庫或項目整合 通過盡可能簡單的API實現(xiàn)相應(yīng)的數(shù)據(jù)綁定和組合的視圖組件核心:相應(yīng)的數(shù)據(jù)綁定系統(tǒng), 數(shù)據(jù)與DOM保持同步數(shù)據(jù)驅(qū)動的視圖,普通的HTML模板中使用特殊的語...

    bergwhite 評論0 收藏0
  • HTML表單元素及CSS

    摘要:表單一介紹標(biāo)簽表示為表單,表單元素是允許用戶在表單中輸入內(nèi)容。屬性值被提交表單的類型二表單組件組件一般被定義在表單中標(biāo)簽中標(biāo)簽表示輸入框,為空標(biāo)簽。屬性,屬性規(guī)定要顯示的元素的類型。冒號表示分隔符,分號表示結(jié)束符。 表單 一、介紹 標(biāo)簽表示為表單,表單元素是允許用戶在表單中輸入內(nèi)容。 屬性:action-提交表單的地址 Method-提交表單的方式。屬性值:get/post ...

    MyFaith 評論0 收藏0
  • HTML表單元素及CSS

    摘要:表單一介紹標(biāo)簽表示為表單,表單元素是允許用戶在表單中輸入內(nèi)容。屬性值被提交表單的類型二表單組件組件一般被定義在表單中標(biāo)簽中標(biāo)簽表示輸入框,為空標(biāo)簽。屬性,屬性規(guī)定要顯示的元素的類型。冒號表示分隔符,分號表示結(jié)束符。 表單 一、介紹 標(biāo)簽表示為表單,表單元素是允許用戶在表單中輸入內(nèi)容。 屬性:action-提交表單的地址 Method-提交表單的方式。屬性值:get/post ...

    jayzou 評論0 收藏0

發(fā)表評論

0條評論

閱讀需要支付1元查看
<