涼月貳陸 2022-09-14 11:30 采纳率: 66.7%
浏览 54
已结题

如何使用vs2022中的ask.net写出这个页面。

img


img


利用其中的控件,将这两个页面结合起来,如果可以的话,最好从一开始回答。

  • 写回答

2条回答 默认 最新

  • CSDN专家-showbo 2022-09-14 11:45
    关注

    这2个页面不难吧,服务器端控件或者客户端html控件都可以

    登录.aspx

    <%@ Page Language="C#" %>
    <!DOCTYPE html>
    <script runat="server">
    
    </script>
    
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head runat="server">
    <meta charset="utf-8"/>
        <title>登录</title>
        <style>
            h1 {
                text-align: center
            }
            table td{padding:10px}
            
            .field{text-align:center;width:215px}
        </style>
    </head>
    <body>
        <h1>ASP.NET开发技术基础!!!</h1>
        <form id="form1" runat="server" style="border:solid 1px #999;display:block;width:760px;margin:10px auto">
           <table>
               <tr>
                   <td class="field">性别:</td>
                   <td><asp:RadioButtonList runat="server" ID="sex" RepeatDirection="Horizontal">
                       <asp:ListItem></asp:ListItem>
                       <asp:ListItem></asp:ListItem>
                       </asp:RadioButtonList></td>
               </tr>
               <tr>
                   <td class="field">爱好:</td>
                   <td>
                       <asp:CheckBoxList runat="server" ID="hobby" RepeatDirection="Horizontal" RepeatColumns="3">
                           <asp:ListItem>读书</asp:ListItem>
                           <asp:ListItem>看电源</asp:ListItem>
                           <asp:ListItem>摄影</asp:ListItem>
                           <asp:ListItem>旅行</asp:ListItem>
                           <asp:ListItem>美食</asp:ListItem>
                           <asp:ListItem>上网</asp:ListItem>
                       </asp:CheckBoxList>
                   </td>
               </tr>
               <tr>
                   <td class="field">头像:</td>
                   <td>
                       <select name="face" id="face" runat="server" onchange="imgFace.src=this.value">
                           <option value="http://www.nongmu168.com/images/head/0.gif">清新1</option>
                           <option value="http://www.nongmu168.com/images/head/1.gif">清新2</option>
                           <option value="http://www.nongmu168.com/images/head/2.gif">清新3</option>
                       </select>
                       <img id="imgFace" src="http://www.nongmu168.com/images/head/0.gif"  style="height:50px"/>
                   </td>
               </tr>
               
               <tr>
                   <td class="field">出生范围:</td>
                   <td>
                       <asp:DropDownList ID="birth" runat="server" size="4">
                           <asp:ListItem>1999-2000</asp:ListItem>
                           <asp:ListItem>2000-2001</asp:ListItem>
                           <asp:ListItem>2001-2002</asp:ListItem>
                           <asp:ListItem>2002-2003</asp:ListItem>
                       </asp:DropDownList>
                   </td>
                   </tr>
               
               <tr>
                   <td class="field">单选题:</td>
                   <td>
                       <asp:RadioButtonList runat="server" ID="choice" RepeatDirection="Horizontal">
                           <asp:ListItem>A</asp:ListItem>
                           <asp:ListItem>B</asp:ListItem>
                           <asp:ListItem>C</asp:ListItem>
                           <asp:ListItem>D</asp:ListItem>
                       </asp:RadioButtonList></td>
                   </tr>
           </table>
        </form>
    </body>
    </html>
    
    
    
    

    注册.aspx

    <%@ Page Language="C#" %>
    <!DOCTYPE html>
    <script runat="server">
    
    </script>
    
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head runat="server">
    <meta charset="utf-8"/>
        <title>用户注册</title>
        <style>
            h1 {
                text-align: center
            }
            table td{padding:10px}
            
            .field{text-align:center;width:50%}
        </style>
    </head>
    <body>
        <h1>用户注册</h1>
        <form id="form1" runat="server" style="border:solid 1px #999;display:block;width:760px;margin:10px auto">
           <table width="100%">
               <tr>
                   <td class="field">姓名:</td>
                   <td><asp:TextBox runat="server" ID="userName"></asp:TextBox></td>
               </tr>
               <tr>
                   <td class="field">密码:</td>
                   <td><asp:TextBox runat="server" ID="password" TextMode="Password"></asp:TextBox></td>
               </tr>
               <tr>
                   <td class="field">留言:</td>
                   <td><asp:TextBox runat="server" ID="message" TextMode="MultiLine" Rows="5" Columns="22"></asp:TextBox></td>
               </tr>
               <tr>
                   <td class="field" colspan="2"><asp:Button runat="server" Text="注册" /></td>
                   </tr>
               <tr>
                   <td class="field">
                       我已注册成功<br />
                       我已点击该图片按钮
                   </td>
                   <td>
                       <img src="http://www.nongmu168.com/images/head/tom.jpg" />
                   </td>
               </tr>
               <tr>
                   <td class="field"><a href="注册.aspx">注册页</a></td>
                   <td class="field"><a href="登录.aspx">登录页</a></td>
               </tr>
           </table>
        </form>
    </body>
    </html>
    
    
    
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论 编辑记录
查看更多回答(1条)

报告相同问题?

问题事件

  • 系统已结题 9月23日
  • 已采纳回答 9月15日
  • 创建了问题 9月14日

悬赏问题

  • ¥20 要做柴油机燃烧室优化 需要保持压缩比不变 请问怎么用AVL fire ESE软件里面的 compensation volume 来使用补偿体积来保持压缩比不变
  • ¥15 python螺旋图像
  • ¥15 算能的sail库的运用
  • ¥15 'Content-Type': 'application/x-www-form-urlencoded' 请教 这种post请求参数,该如何填写??重点是下面那个冒号啊
  • ¥15 找代写python里的jango设计在线书店
  • ¥15 请教如何关于Msg文件解析
  • ¥200 sqlite3数据库设置用户名和密码
  • ¥15 AutoDL无法使用docker install吗?
  • ¥15 cups交叉编译后移植到tina sdk的t113,只需要实现usb驱动打印机,打印pdf文件
  • ¥30 关于#wireshark#的问题:需要网络应用流量数据集需要做长度序列的实验,需要与应用产生的会话的数据包的长度,如视频类或者聊天类软件