´ç½Å¿¡°Ô·Î ¶°³ª´Â ²Þ¼Ó¿©Çà - ²Þ¼Ó³ª¶ó(http://www.inyourdream.net)
ID¿Í Password¸¦ ÀÔ·ÂÇϼ¼¿ä.
ÀÔ±¹Çϱâ
|
¿µÁÖ±Ç ½Åû
¸öºÎ¸² °ñ¶ó°ñ¶ó
¼Ò±Ù¼Ò±Ù
µµ¶õµµ¶õ
³«¼¸¶´ç
Âø°¢ÇѾÆÀÌ
¼ýÀÚ¸ÂÃß±â
¼Ò¿øºô±â
ÈçÀû³²±â±â
²Þ¼Ó¿©Çà
Ä£±¸Áý ³î·¯°¡±â
¸ðµÎµå¸²´ÔÀÇ È¨
î¤éÞ´ÔÀÇ È¨
Çö¿ì´ÔÀÇ È¨
º°¾ÆÇØ´ÔÀÇ È¨
ÇÞ»ì´ÔÀÇ È¨
À̳ª´Ï´ÔÀÇ È¨
À¯¸®¾Ë´ÔÀÇ È¨
³È³ÈÀÌ´ÔÀÇ È¨
²ÀÁö´ÔÀÇ È¨
´ë¼º´ÔÀÇ È¨
¼öÁ¤ÇϽǶ§´Â ÇʼöÇ׸ñÀ» ¸ðµÎ ÀÔ·ÂÇÏ¼Å¾ß ÇÕ´Ï´Ù.
À̸§
*
°øÁö»çÇ×
ºñ°ø°³
HTML »ç¿ë
Á¦¸ñ
*
¼±ÅÃ
ÀÚÀÛ
»ç¶û
À¯¸Ó
ÀÚÀ¯
̵̧
¾Ë¸²
Áú¹®
±âŸ
³»¿ë
*
> Microsoft OLE DB Provider for ODBC Drivers (0x80040E14) > [Microsoft][ODBC SQL Server Driver][SQL Server]The name 'name' is not permitted in this context. Only constants, expressions, or variables allowed here. Column names are not permitted. > /tasp/mysite/write_ok.asp, line 40 > ------------------------------------ > ÇØ´ç¼Ò½º > --------------------------------- > <% > 'request°´Ã¼¸¦ ÅëÇØ ³Ñ¾î¿Â °ªµéÀ» º¯¼ö¿¡ ÀúÀåÇÑ´Ù. (ÃßõµÇ´Â ¹æ¹ýÀÌ´Ù) > name = request("name") > email = request("email") > homepage = request("homepage") > title = request("title") > pwd = request("pwd") > content = request("content") > writeday = now > > 'Äõ¸®¿¡ '°¡ µé¾î°¡¸é ¿¡·¯°¡ ³ª±â¿¡ ±×°ÍÀ» replace ó¸®ÇØÁØ´Ù. > title = replace(title,"'","''") > content = replace(content,"'","''") > content = replace(content,"|","chr(124)_pipe") > > 'HTML ű×(tag) È¿°ú¸¦ Á¦ÇÑÇÏ°í ½ÍÀ¸½Ã´Ù¸é > 'title = replace(title,"&","&") > 'title = replace(title,"<","<") > 'title = replace(title,">",">") > > 'content = replace(content,"&","&") > 'content = replace(content,"<","<") > 'content = replace(content,">",">") > > Set db = Server.CreateObject("ADODB.Connection") > db.Open "MySiteDB","sa" > > SQL = "Select Max(num) from MyBoard" > > Set rs = Server.CreateObject("ADODB.Recordset") > rs.Open SQL, db > > If IsNULL(rs(0)) Then > num = 1 > else > num = rs(0) + 1 <---ÇØ´ç40¶óÀÎ > End If > > SQL = "INSERT INTO MyBoard (name,email,homepage,title,pwd,num,writeday,readnum,content) VALUES (name,email,homepage,title,pwd,num,writeday,0,content)" > db.Execute(SQL) > > rs.Close > db.close > Set rs = Nothing > Set db = Nothing > > Response.redirect "list.asp" > %> ----------------------------------------------------------- SQL = "INSERT INTO MyBoard (name,email,homepage,title,pwd,num,writeday,readnum,content) VALUES (name,email,homepage,title,pwd,num,writeday,0,content)" db.Execute(SQL) ¿¡¼ VALUESÀÌÇÏÀÇ ±¸¹®¿¡¼ °ª ÇÒ´çÀÌ ¿ÇÁö ¾Ê´Â °Í °°±º¿ä.... If IsNULL(rs(0)) Then num = 1 else num = rs(0) + 1 <---ÇØ´ç40¶óÀÎ End If ¿¡¼ If IsNULL(rs(0)) Then num = 1 else num = rs(0) num=num+1 End If ·Î Çغ¸½Ã±¸¿ä...
Ãß°¡ÇÒ À̹ÌÁö¸¦ ÀÔ·ÂÇϼ¼¿ä.
À̹ÌÁö 1
À̹ÌÁö¼³¸í 1
Ãß°¡ÇÒ ÀڷḦ ÀÔ·ÂÇϼ¼¿ä.
ÀÚ·á 1
ÀÚ·á¼³¸í 1
Ãß°¡ÇÒ ½ÎÀÌÆ®¸¦ ÀÔ·ÂÇϼ¼¿ä.
°ü·Ã½ÎÀÌÆ® 1
½ÎÀÌÆ®¼³¸í 1
Password
*