ImageButton1”必须放在具有 runat=server 的窗体标记内
<headrunat="server"><title>信息发布页</title></head><bodyrunat="server"><divclass="top"><a...
<head runat ="server">
<title>信息发布页</title>
</head>
<body runat ="server">
<div class="top">
<asp:Image SkinID="logoImage" ID="Image1" runat ="server"/>
</div>
<table style="width: 405px; height: 279px" runat ="server">
<tr >
<td >
<asp:ImageButton ID="ImageButton1" ImageUrl="~/images/1.jpg" runat="server" /></td>
<td>
<asp:ImageButton ID="ImageButton2" ImageUrl="~/images/2.jpg" runat="server" /></td>
<td style="width: 132px">
<asp:ImageButton ID="ImageButton3" ImageUrl="~/images/3.jpg" runat="server" /></td>
</tr >
<tr>
<td>
<asp:ImageButton ID="ImageButton4" ImageUrl="~/images/4.jpg" runat="server" /></td>
<td>
<asp:ImageButton ID="ImageButton5" ImageUrl="~/images/5.jpg" runat="server" /></td>
<td style="width: 132px">
<asp:ImageButton ID="ImageButton6" ImageUrl="~/images/6.jpg" runat="server" /></td>
</tr>
<tr>
<td>
<asp:ImageButton ID="ImageButton7" ImageUrl="~/images/7.jpg" runat="server" /></td>
<td>
<asp:ImageButton ID="ImageButton8" ImageUrl="~/images/8.jpg" runat="server" /></td>
<td style="width: 132px">
<asp:ImageButton ID="ImageButton9" ImageUrl="~/images/9.jpg" runat="server" /></td>
</tr>
</table>
</body>
我家有RUNat=server怎么运行报错 展开
<title>信息发布页</title>
</head>
<body runat ="server">
<div class="top">
<asp:Image SkinID="logoImage" ID="Image1" runat ="server"/>
</div>
<table style="width: 405px; height: 279px" runat ="server">
<tr >
<td >
<asp:ImageButton ID="ImageButton1" ImageUrl="~/images/1.jpg" runat="server" /></td>
<td>
<asp:ImageButton ID="ImageButton2" ImageUrl="~/images/2.jpg" runat="server" /></td>
<td style="width: 132px">
<asp:ImageButton ID="ImageButton3" ImageUrl="~/images/3.jpg" runat="server" /></td>
</tr >
<tr>
<td>
<asp:ImageButton ID="ImageButton4" ImageUrl="~/images/4.jpg" runat="server" /></td>
<td>
<asp:ImageButton ID="ImageButton5" ImageUrl="~/images/5.jpg" runat="server" /></td>
<td style="width: 132px">
<asp:ImageButton ID="ImageButton6" ImageUrl="~/images/6.jpg" runat="server" /></td>
</tr>
<tr>
<td>
<asp:ImageButton ID="ImageButton7" ImageUrl="~/images/7.jpg" runat="server" /></td>
<td>
<asp:ImageButton ID="ImageButton8" ImageUrl="~/images/8.jpg" runat="server" /></td>
<td style="width: 132px">
<asp:ImageButton ID="ImageButton9" ImageUrl="~/images/9.jpg" runat="server" /></td>
</tr>
</table>
</body>
我家有RUNat=server怎么运行报错 展开
2个回答
展开全部
<body>
<form id="form1" runat="server">
<div class="top">
<asp:Image SkinID="logoImage" ID="Image1" runat ="server"/>
</div>
<table id="Table1" style="width: 405px; height: 279px" runat ="server">
<tr >
<td >
<asp:ImageButton ID="ImageButton1" ImageUrl="~/images/1.jpg" runat="server" /></td>
<td>
<asp:ImageButton ID="ImageButton2" ImageUrl="~/images/2.jpg" runat="server" /></td>
<td style="width: 132px">
<asp:ImageButton ID="ImageButton3" ImageUrl="~/images/3.jpg" runat="server" /></td>
</tr >
<tr>
<td>
<asp:ImageButton ID="ImageButton4" ImageUrl="~/images/4.jpg" runat="server" /></td>
<td>
<asp:ImageButton ID="ImageButton5" ImageUrl="~/images/5.jpg" runat="server" /></td>
<td style="width: 132px">
<asp:ImageButton ID="ImageButton6" ImageUrl="~/images/6.jpg" runat="server" /></td>
</tr>
<tr>
<td>
<asp:ImageButton ID="ImageButton7" ImageUrl="~/images/7.jpg" runat="server" /></td>
<td>
<asp:ImageButton ID="ImageButton8" ImageUrl="~/images/8.jpg" runat="server" /></td>
<td style="width: 132px">
<asp:ImageButton ID="ImageButton9" ImageUrl="~/images/9.jpg" runat="server" /></td>
</tr>
</table>
</form>
</body>
<form id="form1" runat="server">
<div class="top">
<asp:Image SkinID="logoImage" ID="Image1" runat ="server"/>
</div>
<table id="Table1" style="width: 405px; height: 279px" runat ="server">
<tr >
<td >
<asp:ImageButton ID="ImageButton1" ImageUrl="~/images/1.jpg" runat="server" /></td>
<td>
<asp:ImageButton ID="ImageButton2" ImageUrl="~/images/2.jpg" runat="server" /></td>
<td style="width: 132px">
<asp:ImageButton ID="ImageButton3" ImageUrl="~/images/3.jpg" runat="server" /></td>
</tr >
<tr>
<td>
<asp:ImageButton ID="ImageButton4" ImageUrl="~/images/4.jpg" runat="server" /></td>
<td>
<asp:ImageButton ID="ImageButton5" ImageUrl="~/images/5.jpg" runat="server" /></td>
<td style="width: 132px">
<asp:ImageButton ID="ImageButton6" ImageUrl="~/images/6.jpg" runat="server" /></td>
</tr>
<tr>
<td>
<asp:ImageButton ID="ImageButton7" ImageUrl="~/images/7.jpg" runat="server" /></td>
<td>
<asp:ImageButton ID="ImageButton8" ImageUrl="~/images/8.jpg" runat="server" /></td>
<td style="width: 132px">
<asp:ImageButton ID="ImageButton9" ImageUrl="~/images/9.jpg" runat="server" /></td>
</tr>
</table>
</form>
</body>
本回答被提问者采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
2019-01-18
展开全部
在body标签下加form标签 另外记得给form加属性runat="server"
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询