www.HighRiseTimes.dk

<% strFarve = "FFFFFF" %>

| aviser: |

<% MyDay = Day(Now) MyMonth = Month(Now) MyHour = Hour(Now) MyMinute = Minute(Now) MySecond = Second(Now) If len(MyDay) < 2 then strD = "0" else strD = "" end if If len(MyMonth) < 2 then strM = "0" else strM = "" end if If len(MyHour) < 2 then strH = "0" else strH = "" end if If len(MyMinute) < 2 then strMi = "0" else strMi = "" end if If len(MySecond) < 2 then strS = "0" else strS = "" end if strLigeNu = strD & Day(Now) & "-" & strM & Month(Now) & "-" & Year(Now) & " " & strH & Hour(Now) & ":" & strMi & Minute(Now) & ":" & strS & Second(Now) strLigeNow = strD & Day(Now) & "-" & strM & Month(Now) & "-" & Year(Now) Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN strSQL = "Select * from aviser Order by id desc" Set rs = Conn.Execute(strSQL) strSidsteAvis = rs("avis") strSQL = "Select * from aviser Where active = true Order by id desc" Set rs = Conn.Execute(strSQL) strSidsteWAvis = rs("avis") Conn.Close Set Conn = Nothing %> <% If request.QueryString("hrt") = "ja" Then Response.Write "

tilføj artikel | godkend | søg | start

" Else Response.Write "

" End If %>

<% strMode = Request.QueryString("side") Select Case strMode Case "skriv" If session ("login") <> "adminlogin" then Response.Redirect "../nyhed/nyheder.asp?side=adminlogin" End If Response.Write "OBS: Husk at din nyhed mindst må fylde de 100 tegn og du kan bruge visse HTML koder, dem som du må bruge kan du se længere nede.
" %> Overskrift:
Forfatter:
Til avis (f.eks. 28):
Artikel:
HTML koder, der må anvendes:
Koden <BR> skal IKKE bruges mere, bare lav et traditionelt mellemrum med [ENTER] tasten.

Link: | <A HREF=siden.asp>teksten</A>
Billede: | <IMG SRC=billedet.gif>
Billede i midten: | <CENTER><IMG SRC=billedet.gif></CENTER>
Fed: | <B>teksten</B>
Kursiv: | <I>teksten</I>
Understregning: | <U>teksten</U>
Gemmenstreget: | <STRIKE>teksten</STRIKE>

| tilføj artikel |

<% Case "opret" If session ("login") <> "adminlogin" then Response.Redirect "../nyhed/nyheder.asp?side=adminlogin" End If Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN If Len(Request.Form("artikel")) < 50 Then Response.Write "OBS: Lidt for kort artikel." ElseIf Request.Form("artikel") = "" Then Response.Write "OBS: Du skal skrive artiklen." Else strOver = Request.Form("overskrift") strOver = Replace(strOver, "'", "''") strArtikel = Request.Form("artikel") strArtikel = Replace(strArtikel, "'", "''") strSQL = "Insert into aviser (" strSQL = strSQL & "overskrift, " strSQL = strSQL & "forfatter, " strSQL = strSQL & "artikel, " strSQL = strSQL & "avis, " strSQL = strSQL & "dato, " strSQL = strSQL & "ip) " strSQL = strSQL & "values( " strSQL = strSQL & "'" & Server.HTMLEncode(strOver) & "', " strSQL = strSQL & "'" & Server.HTMLEncode(Request.Form("forfatter")) & "', " strSQL = strSQL & "'" & strArtikel & "', " strSQL = strSQL & "'" & Server.HTMLEncode(Request.Form("avis")) & "', " strSQL = strSQL & "'" & strLigeNu & "', " strSQL = strSQL & "'" & Request.ServerVariables("REMOTE_HOST") & "')" Conn.Execute(strSQL) Conn.Close Set Conn = Nothing Response.Write "Artiklen blev tilføjet." End if %> <% Case "aleas" If Len(Session("login")) = 0 Then Response.Redirect "http://www.highrisetimes.dk/unlogged.asp" End If Function StripHtml(Str) Str = Replace(Str, vbCrLf, "
") StripHtml = Str End Function Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN strSQL = "Select * from aviser Where id = " & Request.QueryString("aid") Set rs = Conn.Execute(strSQL) If Not (rs.BOF Or rs.EOF) Then Do overskrift = rs("overskrift") avis = rs("avis") response.write "" & overskrift & "
" & StripHtml(rs("artikel")) & "
Artiklen var taget fra " & avis & " .avis og skrevet af " Response.write rs("forfatter") & "
" rs.MoveNext Loop until rs.EOF Else End if Conn.Close Set Conn = Nothing %> <% Case "add" If Len(Session("login")) = 0 Then Response.Redirect "http://www.highrisetimes.dk/unlogged.asp" End If Response.Write "OBS: Husk at din nyhed mindst må fylde de 100 tegn og du kan bruge visse HTML koder, dem som du må bruge kan du se længere nede.
" %> " method="post"> Overskrift:
<% Response.Write "OBS: I den seneste avis (" & strSidsteAvis & ") er der blevet skrevet om:
" Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/crew.mdb") Conn.Open DSN strSQL = "Select * from nyheder Where id = " & Session("login") & "" Set rs = Conn.Execute(strSQL) strEnsNavn = rs("hhnavn") Conn.Close Set Conn = Nothing Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN strSQL = "Select * from aviser Where avis = " & strSidsteAvis & " Order by id" Set rs = Conn.Execute(strSQL) Response.Write "

" If Not (rs.BOF or rs.EOF) Then Do Response.Write "

- " & rs("overskrift") & "

" If strEnsNavn = rs("forfatter") Then Response.Write "Rediger" End If Response.Write "

" rs.MoveNext Loop Until rs.EOF Response.Write "

" Else Response.Write "OBS: Vigtigt, du må ikke indtaste en artikel FØR at indledning er blevet oprettet, hvis du vil have indledning oprettet skal du kontakte The Leader, Kjutie, St Deck eller IndiCator med det sammen :)" End If Conn.Close Set Conn = Nothing %>
Artikel:
HTML koder, der må anvendes:
Koden <BR> skal IKKE bruges mere, bare lav et traditionelt mellemrum med [ENTER] tasten.

Link: | <A HREF=siden.asp>teksten</A>
Billede: | <IMG SRC=billedet.gif>
Billede i midten: | <CENTER><IMG SRC=billedet.gif></CENTER>
Fed: | <B>teksten</B>
Kursiv: | <I>teksten</I>
Understregning: | <U>teksten</U>
Gemmenstreget: | <STRIKE>teksten</STRIKE>

| tilføj artikel |

<% Case "tilfoj" If Len(Session("login")) = 0 Then Response.Redirect "http://www.highrisetimes.dk/unlogged.asp" End If Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/crew.mdb") Conn.Open DSN strSQL = "Select * from nyheder Where id = " & Session("login") Set rs = Conn.Execute(strSQL) strSkriveNavn = rs("hhnavn") Conn.Close Set Conn = Nothing Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN strArtikler = Request.Form("artikel") strArtikler = Replace(strArtikler, "'", "''") strOverskrift = Request.Form("overskrift") strOverskrift = Replace(strOverskrift, "'", "''") strSQL = "Select * from aviser Where artikel = '" & strArtikler & "'" Set rs = Conn.Execute(strSQL) If Not (rs.BOF Or rs.EOF) Then response.write "OBS: Artiklen findes allerede." Else If len(Request.Form("artikel")) < 300 Then Response.Write "OBS: Din artikel er lige for kort." ElseIf Request.Form("artikel") = "" Then Response.Write "OBS: Du mangler at skrive artiklen." Else strSQL = "Insert into aviser (" strSQL = strSQL & "overskrift, " strSQL = strSQL & "forfatter, " strSQL = strSQL & "artikel, " strSQL = strSQL & "avis, " strSQL = strSQL & "dato, " strSQL = strSQL & "ip) " strSQL = strSQL & "values( " strSQL = strSQL & "'" & Server.HTMLEncode(strOverskrift) & "', " strSQL = strSQL & "'" & strSkriveNavn & "', " strSQL = strSQL & "'" & strArtikler & "', " strSQL = strSQL & "'" & strSidsteAvis & "', " strSQL = strSQL & "'" & strLigeNu & "', " strSQL = strSQL & "'" & Request.ServerVariables("REMOTE_HOST") & "')" Conn.Execute(strSQL) Conn.Close Set Conn = Nothing Response.Write "Artiklen blev tilføjet." End If End if %> <% Case "crewrediger"' If Len(Session("login")) = 0 Then Response.Redirect "http://www.highrisetimes.dk/unlogged.asp" End If Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/crew.mdb") Conn.Open DSN strSQL = "Select * from nyheder Where id = " & Session("login") & "" Set rs = Conn.Execute(strSQL) strEnsNavn = rs("hhnavn") Conn.Close Set Conn = Nothing Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN strSQL = "Select * from aviser Where Id = " & Request.Querystring("nr") Set rs = Conn.Execute(strSQL) If strEnsNavn <> rs("forfatter") Then Response.Redirect "aviser.asp?side=add&br=" & Request.QueryString("br") End If Response.Write "

" Response.Write "Overskrift: " Response.Write " |  | Artikel: " & rs("artikel") & "

" %> Koden <BR> skal IKKE bruges mere, bare lav et traditionelt mellemrum med [ENTER] tasten.

Link: | <A HREF=siden.asp>teksten</A>
Billede: | <IMG SRC=billedet.gif>
Billede i midten: | <CENTER><IMG SRC=billedet.gif></CENTER>
Fed: | <B>teksten</B>
Kursiv: | <I>teksten</I>
Understregning: | <U>teksten</U>
Gemmenstreget: | <STRIKE>teksten</STRIKE>

<% Response.Write "

| opdater |

" Conn.Close Set Conn = Nothing Response.Write "" Case "crewopdater" If Len(Session("login")) = 0 Then Response.Redirect "http://www.highrisetimes.dk/unlogged.asp" End If Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/crew.mdb") Conn.Open DSN strSQL = "Select * from nyheder Where id = " & Session("login") Set rs = Conn.Execute(strSQL) strEnsNavn = rs("hhnavn") Conn.Close Set Conn = Nothing Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN strSQL = "Select * from aviser Where Id = " & Request.Querystring("nr") Set rs = Conn.Execute(strSQL) If strEnsNavn <> rs("forfatter") Then Response.Redirect "aviser.asp?side=add&br=" & Request.QueryString("br") End If If len(Request.Form("artikel")) < 50 Then Response.Write "OBS: Din nyhed er for kort." Else strArtikle = Request.Form("artikel") strArtikle = Replace(strArtikle, "'", "''") strSQL = "Update aviser set " strSQL = strSQL & "artikel= '" & strArtikle & "', " strSQL = strSQL & "overskrift= '" & Server.HTMLEncode(Request.Form("overskrift")) & "'" strSQL = strSQL & " Where Id = " & Request.Querystring("nr") & "" Conn.Execute(strSQL) Conn.Close Set Conn = Nothing Response.Redirect "aviser.asp?side=add&br=" & Request.QueryString("br") End If Case "rediger" If Session("login") <> "adminlogin" then Response.Redirect "../nyhed/nyheder.asp?side=adminlogin" End If Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN strSQL = "Select * from aviser Where Id = " & Request.Querystring("nr") Set rs = Conn.Execute(strSQL) Response.Write "

" Response.Write "Overskrift: Forfatter: Til avis (f.eks. 28): " Response.Write " |  | Artikel: " & rs("artikel") & "

" %> Koden <BR> skal IKKE bruges mere, bare lav et traditionelt mellemrum med [ENTER] tasten.

Link: | <A HREF=siden.asp>teksten</A>
Billede: | <IMG SRC=billedet.gif>
Billede i midten: | <CENTER><IMG SRC=billedet.gif></CENTER>
Fed: | <B>teksten</B>
Kursiv: | <I>teksten</I>
Understregning: | <U>teksten</U>
Gemmenstreget: | <STRIKE>teksten</STRIKE>

<% Response.Write "

| opdater |

" Conn.Close Set Conn = Nothing %> <% Case "opdater" If session ("login") <> "adminlogin" then Response.Redirect "../nyhed/nyheder.asp?side=adminlogin" End If Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN If len(Request.Form("artikel")) < 50 Then Response.Write "OBS: Din nyhed er for kort." ElseIf Request.Form("forfatter") = "" Then Response.Write "OBS:Du mangler at skrive forfatteren." ElseIf Request.Form("avis") = "" Then Response.Write "OBS:Du mangler at skrive avis nummeret." ElseIf Request.Form("overskrift") = "" Then Response.Write "OBS:Du mangler at skrive overskriften." Else strArtikle = Request.Form("artikel") strArtikle = Replace(strArtikle, "'", "''") strSQL = "Update aviser set " strSQL = strSQL & "artikel= '" & strArtikle & "', " strSQL = strSQL & "overskrift= '" & Server.HTMLEncode(Request.Form("overskrift")) & "', " strSQL = strSQL & "avis= '" & Server.HTMLEncode(Request.Form("avis")) & "', " strSQL = strSQL & "forfatter= '" & Server.HTMLEncode(Request.Form("forfatter")) & "' " strSQL = strSQL & " Where Id = " & Request.Querystring("nr") & "" Conn.Execute(strSQL) Conn.Close Set Conn = Nothing Response.Redirect "aviser.asp?side=adminlist&hrt=ja" End if %> <% Case "avis" Response.Write Request.QueryString("aid") & ". avis
" Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN strSQL = "Select * from aviser Where avis = " & Request.QueryString("aid") & " AND active = True Order by id" Set rs = Conn.Execute(strSQL) If Not (rs.BOF Or rs.EOF) Then Do Overskrift = rs("overskrift") Response.Write "
- " & Overskrift & "
" rs.MoveNext Loop until rs.EOF Else strUrl = Request.QueryString("aid") - 1 Response.Redirect "aviser.asp?side=avis&aid=" & strUrl & "" End if Conn.Close Set Conn = Nothing Response.Write "
" Function StripHtml(Str) Str = Replace(Str, vbCrLf, "
") StripHtml = Str End Function Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN strSQL = "Select * from aviser Where avis = " & Request.QueryString("aid") & " AND active = True Order by id" Set rs = Conn.Execute(strSQL) If Not (rs.BOF Or rs.EOF) Then Do strOverskrift = rs("overskrift") Response.Write "
" & strOverskrift & "
" & StripHtml(rs("artikel")) & "
" Response.Write "Skrevet af " & rs("forfatter") & "
" rs.MoveNext Loop until rs.EOF Else End if Conn.Close Set Conn = Nothing %> <% Case "leasnyhed" Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN strSQL = "Select * from aviser Where id = " & Request.QueryString("aid") & " AND active = True" Set rs = Conn.Execute(strSQL) If Not (rs.BOF Or rs.EOF) Then Do overskrift = rs("overskrift") avis = rs("avis") response.write "" & overskrift & "
" & rs("artikel") & "
Artiklen var taget fra " & avis & " .avis og skrevet af " Response.write rs("forfatter") & "
" rs.MoveNext Loop until rs.EOF Else End if Conn.Close Set Conn = Nothing %> <% Case "godkendliste" If session ("login") <> "adminlogin" then Response.Redirect "../nyhed/nyheder.asp?side=adminlogin" End If Response.Write "Artiklerne skal godkendes før de kan bruges og det sker her. Udover det kan artiklerne slettes og læses..
" Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN strSQL = "Select * from aviser Where active = False" Set rs = Conn.Execute(strSQL) If Not (rs.BOF Or rs.EOF) Then Do id = rs("id") response.write "
" & rs("overskrift") & "
" & left(server.HTMLEncode(rs("artikel")),100) & "...
- Skrevet af " & rs("forfatter") & " og til avis nummer " & rs("avis") & ", oprettet den " & rs("dato") & "
" Response.write "

| læs |  | " response.write " |  | slet |  | " response.write " |  | rediger |  | " response.write " |  | godkend |

" rs.MoveNext Loop until rs.EOF Else Response.write "Der blev ikke fundet nogen artikler!" End if Conn.Close Set Conn = Nothing %> <% Case "oversigt" Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN strSQL = "Select * from aviser Where avis = 2 AND active = False" Set rs = Conn.Execute(strSQL) If Not (rs.BOF Or rs.EOF) Then Do response.write rs("forfatter") & "
" rs.MoveNext Loop until rs.EOF Else Response.Redirect "aviser.asp" End if Conn.Close Set Conn = Nothing %> <% Case "showall" Response.Write "Her ses artikler fra alle aviser, klik her for at se artikler fra de 3 seneste aviser.
Klik her for at oprette en færdiggjort avis.
" If session ("login") <> "adminlogin" then Response.Redirect "../nyhed/nyheder.asp?side=adminlogin" End If Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN strSQL = "Select * from aviser Order by id desc" Set rs = Conn.Execute(strSQL) If Not (rs.BOF Or rs.EOF) Then do id = rs("id") response.write "
" & rs("avis") & " " & rs("overskrift") & "
" & rs("artikel") & "
Af: " & rs("forfatter") & ",
Ip: " & rs("ip") & "
slet - rediger" if rs("active") = "False" then response.write "- godkend
" else response.write "
" end if rs.MoveNext Loop until rs.EOF Else Response.Write "OBS: Der blev ikke fundet nogen artikler." End if Conn.Close Set Conn = Nothing %> <% Case "adminlist" Function StripHtml(Str) Str = Replace(Str, vbCrLf, "
") StripHtml = Str End Function Response.Write "Her ses artikler fra de 3 seneste aviser, klik her for at se alle.
Klik her for at oprette en færdiggjort avis.
" If session ("login") <> "adminlogin" then Response.Redirect "../nyhed/nyheder.asp?side=adminlogin" End If Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN strSQL = "Select * from aviser Where avis > " & strSidsteAvis - 3 & " Order by id desc" Set rs = Conn.Execute(strSQL) If Not (rs.BOF Or rs.EOF) Then do id = rs("id") response.write "
" & rs("avis") & " " & rs("overskrift") & "
" & StripHtml(rs("artikel")) & "
Af: " & rs("forfatter") & ",
Ip: " & rs("ip") & "
slet - rediger" if rs("active") = "False" then response.write "- godkend
" else response.write "
" end if rs.MoveNext Loop until rs.EOF Else Response.Write "OBS: Der blev ikke fundet nogen artikler." End if Conn.Close Set Conn = Nothing %> <% Case "slet" If session ("login") <> "adminlogin" then Response.Redirect "../nyhed/nyheder.asp?side=adminlogin" End If Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath ("../../database/aviser.mdb") Conn.Open DSN strSQL = "Delete * From aviser Where Id = " & Request.Querystring("id") Conn.Execute(strSQL) Conn.Close Set Conn = Nothing Response.Redirect "aviser.asp?side=adminlist&hrt=ja" %> <% Case "godkend" If session ("login") <> "adminlogin" then Response.Redirect "../nyhed/nyheder.asp?side=adminlogin" End If Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN Conn.Execute ("UPDATE aviser SET active = TRUE WHERE id = " & Request.QueryString("nr") & ";") Conn.Close Set Conn = Nothing Response.Redirect "aviser.asp?side=godkendliste&hrt=ja" %> <% Case "artikelsog" %> Søg på en
som
:

| søg |

<% Case "sog" Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath ("../../database/aviser.mdb") Conn.Open DSN If Request.Form("navn") = "" Then Response.Redirect "aviser.asp?side=artikelsog" Else Response.Write "Du søgte på " & Server.HTMLEncode(Request.Form("navn")) & ", som gav følgende resultat:

" if request.form("select") = "ligmed" then strSQL = "Select * From aviser Where " & Server.HTMLEncode(request.form("slags"))& " = '" & request.form("navn") & "' AND active = True Order by id desc" elseif request.form("select") = "startermed" then strSQL = "SELECT * FROM aviser WHERE (" & Server.HTMLEncode(request.form("slags")) & " LIKE '" & request.form("navn") & "%' AND active = True) Order by id desc" elseif request.form("select") = "indeholder" then strSQL = "Select * From aviser where (" & request.form("slags") & " like '%" & request.form("navn") & "%' AND active = True) Order by id desc" end if Set rs = Conn.Execute(strSQL) If Not (rs.BOF Or rs.EOF) Then Do Response.Write "
| " & rs("overskrift") & " " & left(Server.HTMLEncode(rs("artikel")),200) & "...... - af " & rs("forfatter") & "
" rs.MoveNext Loop While Not rs.EOF Else Response.Write "
OBS: Intet søgeresultat." End if Conn.Close Set Conn = Nothing End if Response.write "

" %> <% Case "avisskriv" If session ("login") <> "adminlogin" then Response.Redirect "../nyhed/nyheder.asp?side=adminlogin" End If %> Avis nummer:

| opret avis |

<% Case "avisopret" If session ("login") <> "adminlogin" then Response.Redirect "../nyhed/nyheder.asp?side=adminlogin" End If Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath("../../database/aviser.mdb") Conn.Open DSN strSQL = "Select * from avis Where avis = " & Request.Form("avis") Set rs = Conn.Execute(strSQL) If Not (rs.BOF Or rs.EOF) Then response.write "OBS: Avisen er allerede oprettet." Else strSQL = "Insert into avis (" strSQL = strSQL & "avis, " strSQL = strSQL & "ip, " strSQL = strSQL & "dato) " strSQL = strSQL & "values( " strSQL = strSQL & "'" & Server.HTMLEncode(Request.Form("avis")) & "', " strSQL = strSQL & "'" & Request.ServerVariables("REMOTE_HOST") & "', " strSQL = strSQL & "'" & strLigeNu & "')" Conn.Execute(strSQL) Conn.Close Set Conn = Nothing Response.Redirect "aviser.asp?side=avis&aid=" & Server.HTMLEncode(request.form("avis")) & "&hrt=ja" End if %> <% Case Else Response.write "

" Set Conn = Server.CreateObject("ADODB.Connection") DSN = "DRIVER={Microsoft Access Driver (*.mdb)}; " DSN = DSN & "DBQ=" & Server.MapPath ("../../database/aviser.mdb") Conn.Open DSN set rscount = conn.execute("select count(id) as tags from aviser Where active = True") tags = rscount("tags") set rscount = nothing Response.write "Der er i alt " & tags & " artikler fordelt udover " & strSidsteWAvis & " aviser, altså i gennemsnit " & left(tags / strSidsteWAvis,4) & " pr. avis.
" strSQL = "Select * From avis Order by id desc" Set rs = Conn.Execute(strSQL) If Not (rs.BOF Or rs.EOF) Then Do avis = rs("avis") Response.write "
" & avis & ". avis | " & rs("dato") & "
" rs.MoveNext Loop until rs.EOF Else Response.Write "OBS: HighRiseTimes har ikke udgivet nogen aviser, beklager." End if Conn.Close Set Conn = Nothing Response.write "

" %>
ekstra udgaver:
1. ekstra udgave

| Brugernes Hjørne Har du et forslag, en artikel eller en mening, som du gerne vil ud med, er Brugernes Hjrøendet perfekte sted. Hver onsdag udvælger HighRiseTimes nogle artikler fra Brugernes Hjørne og sætter dem i den kommende avis. - Skriv ind til hjørnet

<% End Select %>