HTML
Javascript
Flash Actionscript
PHP
mySQL
ASP
MS-SQL
Linux
Others
Ziwoo Board
Portfolio
About
|
 |
ASP |
ÀÛ¼º |
2007-03-14 07:43:35 Ãßõ: 78 Á¶È¸: 2135 |
Á¦¸ñ |
ÀÚµ¿¸µÅ© ÇÔ¼ö |
À̸§(ID) |
Áö¿ì (ziwoo)
|
|
<%
Function RegExpContent(str)
Dim ptrn, repstr
ptrn = "((http|https|ftp|telnet|news):\/\/[a-z0-9-]+\.[][a-zA-Z0-9:&#@=_~%;\?\/
\.\+-]+)"
repstr = "<a href=""$1"" target=""_blank"">$1</a>"
RegExpContent = ReplaceEreg(ptrn, repstr, str)
End Function
Function ReplaceEreg(ptrn, repstr, str)
Dim regEx
Set regEx = New RegExp
regEx.Pattern = ptrn
regEx.IgnoreCase = True
regEx.Global = True
ReplaceEreg = regEx.Replace(str, repstr)
End Function
content = "´ÙÀ½Àº asprun ȨÆäÀÌÁö ÁÖ¼ÒÀÌ´Ù. http://www.asprun.co.kr ±â¾ïÇØÁÖ¼¼¿ä"
content = RegExpContent(content)
content = "<pre>"& content &"</pre>"
response.write content
%>
|
|
|