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

asp.netÒ³ÃæÎÞ·¨»ñµÃÊý¾Ý¿âµÄÖµ

Êý¾Ý¿âÄÜÁ¬½Ó£¬Èç¹û²»¼ÓwhereÌõ¼þtxtKeyword.Text ¿ÉÒÔÏÔʾ¡°keyWords¡±Öµ£¬µ«¼ÓÉÏwhereÓÉÎı¾¿òÊäÈëµÄÌõ¼þ¾Í²»Äܵõ½Êý¾Ý¿âµÄÖµÁË£¬ÎªÊ²Ã´ÄØ£¿
protected void txtProperTitle_TextChanged(object sender, EventArgs e)
    {
        string strConn = " Server=xiao\\SQLEXPRESS;Initial Catalog=catalogue;User ID=sa;Password=123";
        SqlConnection cn = new SqlConnection(strConn);
       
        string SqlString = "select keyWords from dbo.cat where name="+txtProperTitle.Text;

        try
        {
            cn.Open();

            SqlCommand objCommand = new SqlCommand(SqlString, cn);
            SqlDataReader objReader = objCommand.ExecuteReader();
            while (objReader.Read())
            {
                txtKeyword.Text = objReader.GetString(0);
            }
            cn.Close();

        }
        catch (Exception e2)
        {
         


Ïà¹ØÎÊ´ð£º

aspÉý¼¶µ½asp.net£¬ºÃ¶à½á¹¹¶¼²»ÖªµÀÈçºÎת»»

aspÏÂÃæ£¬µ±Òª¸ù¾Ý²»Í¬µÄȨÏÞÏÔʾһЩ¹¦Äܰ´Å¥µÄ»°»áд³É
<%
if ȨÏÞ=1 then
%>
<input type="submit" name="Submit" value="Ìá½»" />
<%
end i ......

asp.netµ¯³ö¿òÎÊÌâ

ÔÚµ¯³ö¿òÖеã»÷Ò»¸ö°´Å¥£¬Ôõôµ÷תµ½ÁíÒ»¸öä¯ÀÀÆ÷£¬²¢ÇÒÔÚ¸Ãä¯ÀÀÆ÷´ò¿ªÁ½¸öÒ³Ãæ
ÄãµÄÒâ˼Ӧ¸ÃÊÇ
response.write("<script>alert('È·ÈÏ'); window.location.href('xxxx.aspx'); </script>"); ......

ASP.NETÈÕÆÚÊäÈëÎÊÌ⣿

ÇëÎÊһϣ¬ASP.NETÎÒÓÃÒ»¸ö²ãÖзÅÁËÒ»¸öÈÕÀú¿Ø¼þ£¬ÔÚµãÒ»¸ö°´Å¥Ê±£¬ÏÔʾÕâ¸ö²ã£¿ÏÖÔÚÎÊÌâÊÇÎÒÔڵ㰴ťʱ£¬ÎÒÏë°Ñ²ãÏÔʾÔÚ°´Å¥µÄÏ·½£¿¾ÍÏñÏÂÀ­ÈÕÆÚ¿Ø¼þÒ»Ñù£¬ÎÒÓÃÊǵÄASP.NET C#
ÎÒÓÐÕâôһ¸öÈÕÆÚ¿Ø¼þ£¬£¡µã»÷¿ÉÒÔÑ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ