Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

asp.netÉú³É¾²Ì¬Ò³

ÏȽ¨¸öhtmlÄ£°æÒ³(template.htm)£º
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>$title</title>
</head>
<body>
<table $htmlformat[0] height="100%" border="0" width="100%" cellpadding="10" cellspacing="0" bgcolor="#eeeeee" style="border:1px solid #000000">
<tr>
<td width="100%" valign="middle" align="left">
<span style="color: $htmlformat[1];font-size: $htmlformat[2]">$htmlformat[3]</span>
</td>
</tr>
</table>
</body>
</html>
ÔÚasp.netÖеÄÓ¦ÓÃ(c#):
   string[] format=new string[4];//¶¨ÒåºÍhtmlyem±ê¼ÇÊýÄ¿Ò»ÖµÄÊý×é
   StringBuilder htmltext=new StringBuilder();
   try
   {
    using (StreamReader sr= new StreamReader(base.Server.MapPath(".")+"\\template.htm"))
¡¡    {
¡¡¡¡    String line;
¡¡¡¡    while ((line = sr.ReadLine()) != null)
¡¡¡¡    {
¡¡¡¡¡¡     htmltext.Append(line);
¡¡¡¡    }
¡¡¡¡    sr.Close();
¡¡    }
   }
   catch
   {
¡¡    Response.Write("<Script>alert('¶ÁÈ¡Îļþ´íÎó')</Script>");
   }
   //---------------------¸ø±ê¼ÇÊý×鸳ֵ------------
   string title="Ä£°å²âÊÔ";
   format[0]="background=\"bg.jpg\"";//±³¾°Í¼Æ¬
   format[1]= "#990099";//×ÖÌåÑÕÉ«
   format[2]="150px";//×ÖÌå´óС
   format[3]= "<marquee>Éú³ÉµÄÄ£°åhtmlÒ³Ãæ</marquee>";//ÎÄ×Ö˵Ã÷
   //----------Ìæ»»htmÀïµÄ±ê¼ÇΪÄãÏë¼ÓµÄÄÚÈÝ
   htmltext.Replace("$title",title);//°Ñtitle²»·ÅÔÚÊý×éÊÇΪÁ˱ȽÏһϣ¬£º£©¡£ÕâÑùд±È½ÏÈÝÒ׿´¶®
   for(int i


Ïà¹ØÎĵµ£º

ASP.NET(C#)³£ÓôúÂë30Àý

ASP.NET³ÌÐòÖг£ÓõÄÈýÊ®ÈýÖÖ´úÂë 
1. ´ò¿ªÐµĴ°¿Ú²¢´«ËͲÎÊý£º 
¡¡¡¡´«ËͲÎÊý£º
response.write("£¼script£¾window.open(’*.aspx?id="+this.DropDownList1.SelectIndex+"&id1="+...+"’)£¼/script£¾")
¡¡¡¡½ÓÊÕ²ÎÊý£º
string a = Request.QueryString("id");
string& ......

asp.net ÖÐÓÃJSµ¯³öģ̬´°¿ÚµÄ·ÖÒ³ÎÊÌâ

ÔÚasp.netÖÐÓÃjs¿ØÖƵ¯³öÒ»¸öģ̬´°¿Ú£¬Ä£Ì¬´°¿ÚÈ´²»ÄÜ·ÖÒ³¡£µ¥¶ÀÔËÐдËÒ³·ÖҳЧ¹ûÊÇ¿ÉÒÔ´ïµ½µÄ¡£
Îҵĵ¯³öģ̬´°¿ÚµÄ´úÂëÊÇ£º
var param=window.showModalDialog("../StorageList.aspx",null,"height=100px;width=950px;status=yes;toolbar=no,location=nu");
²»ÖªµÀΪʲô»á³öÏÖÕâÖÖЧ¹û£¿
½â¾ö·½·¨ÊÇÔÚÒªµ¯³öµÄģ̬´ ......

ASP.NETÒ³Ãæˢз½·¨×ܽá

ÏÈ¿´¿´ASP.NETÒ³ÃæˢеÄʵÏÖ·½·¨£º
µÚÒ»£º
private void Button1_Click( object sender, System.EventArgs e )     {        Response.Redirect( Request.Url.ToString( ) );   }  
µ ......

ASP.NET³ÌÐòÖг£ÓõÄÈýÊ®ÈýÖÖ´úÂë


1. ´ò¿ªÐµĴ°¿Ú²¢´«ËͲÎÊý£º 
¡¡¡¡´«ËͲÎÊý£º
response.write("£¼script£¾window.open(’*.aspx?id="+this.DropDownList1.SelectIndex+"&id1="+...+"’)£¼/script£¾")
¡¡¡¡½ÓÊÕ²ÎÊý£º
string a = Request.QueryString("id");
string b = Request.QueryStrin ......

ASP.NET Routing for URLRewriting with QueryStrings

In the last post I showed how to use the ASP.NET 3.5 Routing Engine
for URLRewriting purposes. I want to go further in this post by adding
the ability to add variables into a route path and forward and append
query string variables to the destination Web Form request.
A route can contain one or ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ