读书人

asp.net点击网页html中的链接跳转页

发布时间: 2012-09-19 13:43:54 作者: rapoo

asp.net点击网页html中的链接,跳转页面的样式失效了。。。。什么情况??求救
前台代码:
<div class="thubpiccur" id="tmb0" onmouseover="setfoc(0);" onmouseout="playit();">
<a href="<%=href1 %>" target="_blank"><img height="48" alt="" src="<%=flashPic1 %>" width="63" /></a>
</div>

cs代码:

href1 = "FlashInfoDisplay.aspx?ID=" + dsFlash.Tables[0].Rows[0]["ID"].ToString();



[解决办法]
检查下样式引用的路径是否正确
[解决办法]
你的图片链接有错误,刚刚帮你试了下图片链接正确就没问题了~
[code=HMTL]
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
<%
string href1 = "FlashInfoDisplay.aspx?ID=1";
string flashPic1 = "../Images/Chrysanthemum.jpg";
%>

<div class="thubpiccur" id="tmb0">
<a href=" <%=href1 %>" target="_blank">
<img height="48" alt="" src=" <%=flashPic1 %>" width="63" /> </a>
</div>

</asp:Content>
[/code]
[解决办法]

HTML code
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">    <%        string href1 = "FlashInfoDisplay.aspx?ID=1";        string flashPic1 = "../Images/Chrysanthemum.jpg";        %>    <div class="thubpiccur" id="tmb0">        <a href=" <%=href1 %>" target="_blank">            <img height="48" alt="" src=" <%=flashPic1 %>" width="63" /> </a>    </div></asp:Content> 

读书人网 >asp.net

热点推荐