<!--#include file=\"includes/services.asp\"-->
<!--#include file=\"includes/db_link.asp\"-->
<!--#include file=\"includes/config.asp\"-->
<%
function makeLink(str)
\'*** Make the reqular expr object
Set objRegExp = New RegExp
objRegExp.IgnoreCase = True
objRegExp.Global = True
\'***Make html links
objRegExp.Pattern = \"(\\bhttp\\:\\/\\/)?(\\bw{3}\\.\\S+\\.[a-z][a-z]+\\b)(\\/\\S+\\b)?(\\?\\S+\\b)?\"
str = objRegExp.Replace(str, \"<a href=\"&chr(34)&\"
http://$2$3$4\"&chr(34)&\" target=\"&chr(34)&\"_blank\"&chr(34)&\">$1$2$3$4</a>\")
\'***Make html mailto
objRegExp.Pattern = \"(\\S+@{1}\\S+\\.[a-z][a-z]+\\b)\"
str = objRegExp.Replace(str, \"<a href=\"&chr(34)&\"mailto:$1\"&chr(34)&\" target=\"&chr(34)&\"_blank\"&chr(34)&\">$1</a>\")
Set objRegExp = Nothing
makelink = str
end function
%>
<%
\' -------------------------------------------------
\' CD-Board v1.0
\' (C) Copyright 2001, Clandestine Development
\' -------------------------------------------------
\' Se filen \"readme.htm\" for licensbetingelser.
\'
\' Mere info, updates og andre programmer på:
\'
http://www.clandestine.dk \' -------------------------------------------------
Dim Conn, RS, Text, Topic
Set Conn = Server.CreateObject(\"ADODB.Connection\")
Conn.Open UsrConnect()
Session.LCID = 2057
Set RS = Server.CreateObject(\"ADODB.RecordSet\")
RS.Open \"SELECT * FROM News WHERE TID = \"& Request(\"TID\"), Conn, 1, 3
If not RS.EOF Then
Text = Replace(RS(\"Text\"), VbCrLf, \"<br>\")
Text = makelink(Text)
Topic = RS(\"Topic\")
%>
<html>
<head>
<title><%= Page_Title %></title>
<link rel=\"stylesheet\" type=\"text/css\" href=\"includes/styles.asp\">
</head>
<body>
<div align=\"center\">
<center>
<table border=\"0\" cellpadding=\"0\" width=\"<%= Table_Width %>\" cellspacing=\"0\">
<tr>
<td colspan=\"2\"><b><%= Topic %></b></td>
</tr>
<tr>
<% If Not RS(\"Email\") = \"\" Then %>
<td valign=\"top\"><font size=\"1\"><i>af <a href=\"mailto:<%= RS(\"Email\") %>?subject=<%= Mail_Subject &\" \"& Topic %>\"><%= RS(\"Name\") %></a></i></font></td>
<% Else %>
<td valign=\"top\"><font size=\"1\"><i>af <%= RS(\"Name\") %></i></font></td>
<% End If %>
</center>
<td valign=\"top\">
<p align=\"right\"><font size=\"1\">Oprettet d. <%= Timestamp(RS(\"Date\")) %><br> </font></td>
</tr>
<tr>
<td colspan=\"2\"><%= Text %></td>
</tr>
</table>
</div>
<hr width=\"<%= Line_Width %>\" noshade color=\"#<%= Line_Color %>\">
<%
End If
RS.Close
RS.Open \"SELECT * FROM Comments WHERE TID = \"& Request(\"TID\") &\" ORDER BY Date ASC, CID ASC\", Conn, 1, 3
While Not RS.EOF
Text = Replace(RS(\"Text\"), VbCrLf, \"<br>\")
%>
<div align=\"center\">
<center>
<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"<%= Table_Width %>\">
<tr>
<td colspan=\"2\"><%= Text %></td>
</tr>
<tr>
<% If Not RS(\"Email\") = \"\" Then %>
<td><font size=\"1\"><br><i>af <a href=\"mailto:<%= RS(\"Email\") %>?subject=<%= Mail_Note &\" \"& Topic %>\"><%= RS(\"Name\") %></a></i></font></td>
<% Else %>
<td><font size=\"1\"><br><i>af <%= RS(\"Name\") %></i></font></td>
<% End If %>
<td><p align=\"right\"><font size=\"1\">Oprettet d. <%= Timestamp(RS(\"Date\")) %></font></td>
</tr>
</table>
</center>
</div>
<hr width=\"<%= Line_Width %>\" noshade color=\"#<%= Line_Color %>\">
<%
RS.MoveNext
Wend
RS.Close
Set RS = Nothing
Conn.Close
Set Conn = Nothing
%>
<p align=\"center\"><font face=\"Verdana\" size=\"1\"><a href=\"new_comment.asp?TID=<%= Request(\"TID\") %>\">Opret kommentar</a></font></p>
<p align=\"center\"><font face=\"Verdana\" size=\"1\"><a href=\"default.asp\">Tilbage til oversigten</a></font></p>
</body>
</html>