Her er resultatet:
<!--#include file="connection.asp"-->
<%Response.Buffer=true%>
<html>
<head>
<STYLE type="text/css">
<!--
a{font-family:Verdana;font-size:11px;text-decoration:none}
body {font-family:Verdana;font-size:11px}
table, text, textarea, input {font-family:Verdana;font-size:11px}
TABLE#tblCoolbar
{
background-color:threedface; padding:1px; color:menutext;
border-width:1px; border-style:solid;
border-color:threedhighlight threedshadow threedshadow threedhighlight;
}
.cbtn
{
height:18;
BORDER-LEFT: threedface 1px solid;
BORDER-RIGHT: threedface 1px solid;
BORDER-TOP: threedface 1px solid;
BORDER-BOTTOM: threedface 1px solid;
}
.txtbtn {font-family:tahoma; font-size:70%; color:menutext;}
-->
</STYLE>
<link href="../style.css" rel="STYLESHEET" TYPE="text/css">
<title>Ret alle</title>
<script LANGUAGE="JavaScript">
function nytVindue()
{
window.open ("pop_forum_code.htm", "navn2", "width=400, height=500, toolbar=no, status=no, scrollbars=yes, top=100,left=100");
}
</script>
</head>
<body bgcolor=#a6bbd6 OnLoad="if (document.forms[0].testbtn){document.forms[0].testbtn.click()}">
<table border="0" width="800" cellspacing="1" bgcolor=#a6bbd1 align="center">
<tr><td>
<%
Response.Buffer=true
if request.servervariables("REQUEST_METHOD")="POST" THEN
P_cmd = Request.Form("cmd")
P_kat = Request.Form("kat")
P_sprog = Request.Form("sprog")
P_id = 0
P_id = cInt(Request.FORM("id"))
ELSE
P_cmd = Request.QueryString("cmd")
P_kat = Request.QueryString("kat")
P_sprog = Request.QueryString("sprog")
P_id = 0
P_id = cInt(Request.QueryString("id"))
END IF
IF (P_id=0 AND P_cmd <> "create" AND P_cmd <> "ny") Then
Response.Write "<h2>Redigeringsside</h2>"
Response.Write "<a href='artikel-ret.asp?cmd=ny'><b>Opret ny - </a><a href='../index.htm' target=""_top""> Til Hovedside - </b></a>"
Response.Write "<A HREF=""java script:nytVindue();""> Hjælp til artikler</A>"
Set objRec = DBforbindelse.execute("SELECT * FROM artikel ORDER BY kategori,sprog,id")
Response.Write "<center><form>"
Do While Not objRec.EOF
select case objRec("sprog")
case "dk": v_sprog = "Dansk"
case "de": v_sprog = "Fransk"
case else: v_sprog = "Engelsk"
end select
select case objRec("kategori")
case 6: v_kategori = "Booking"
case 15: v_kategori = "Vaugrenier"
case 24: v_kategori = "Lejlighederne"
case 25: v_kategori = "Kobe-Lejlighed"
case 35: v_kategori = "Information"
case 45: v_kategori = "Rivieraen"
case 64: v_kategori = "Nyheder"
case 75: v_kategori = "Medlemsside"
case 83: v_kategori = "Testside"
case 84: v_kategori = "Administration"
case else: v_kategori = "Sightseeing" 'case 1:
'else: v_kategori = "Sightseeing" 'case 1:
end select
Response.Write "<table width='700' align='center' style='border-width:1px;border-style:solid;'>"
Response.Write "<tr><td>" '1.row 1.column
Response.Write " <a href='artikel-ret.asp?cmd=ret&id=" & objRec("id") & "'>" & "Rediger </a>" & _
"<a href='artikel-ret.asp?cmd=slet&id=" & objRec("id") & "'>" & " Slet</a> "
Response.Write "<b>Kategori: </b>"&v_kategori&"<b> Sprog: </b>"&v_sprog&""
Response.write "<b> Overskrift: </b>" & objRec("overskrift")
Response.Write "</td></tr>"
Response.Write "</table>"
objRec.MoveNext
Response.Write "<div style='line-height:5px;font-size:5px'> </div>"
Loop
Response.Write "</form></center>"
objRec.Close
Set objRec = Nothing
DBforbindelse.Close
Set DBforbindelse = Nothing
ElseIf P_cmd="slet" AND cInt(P_id) <> 0 THEN
DBforbindelse.execute("Delete FROM artikel WHERE id=" & P_id)
Set DBforbindelse = Nothing
Response.Clear
Response.Redirect "artikel-ret.asp"
ELSEIf P_cmd="ret" AND cInt(P_id) <> 0 THEN
%>
<script language="JavaScript">
function button_over(eButton)
{
eButton.style.backgroundColor = "#B5BDD6";
eButton.style.borderColor = "darkblue darkblue darkblue darkblue";
}
function button_out(eButton)
{
eButton.style.backgroundColor = "threedface";
eButton.style.borderColor = "threedface";
}
function button_down(eButton)
{
eButton.style.backgroundColor = "#8494B5";
eButton.style.borderColor = "darkblue darkblue darkblue darkblue";
}
function button_up(eButton)
{
eButton.style.backgroundColor = "#B5BDD6";
eButton.style.borderColor = "darkblue darkblue darkblue darkblue";
eButton = null;
}
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
var isHTMLMode=false
function document.onreadystatechange()
{
idContent.document.designMode="On";
}
function cmdExec(cmd,opt)
{
if (isHTMLMode){alert("Please uncheck 'Edit HTML'");return;}
idContent.document.execCommand(cmd,"",opt);idContent.focus();
}
function setMode(bMode)
{
var sTmp;
isHTMLMode = bMode;
if (isHTMLMode){sTmp=idContent.document.body.innerHTML;idContent.document.body.innerText=sTmp;}
else {sTmp=idContent.document.body.innerText;idContent.document.body.innerHTML=sTmp;}
idContent.focus();
}
function createLink()
{
if (isHTMLMode){alert("Please uncheck 'Edit HTML'");return;}
cmdExec("CreateLink");
}
function insertImage()
{
if (isHTMLMode){alert("Please uncheck 'Edit HTML'");return;}
var sImgSrc=prompt("Insert Image File (You can use your local image file) : ", "
http://www.aspalliance.com/Yusuf/Article10/sample.jpg");
if(sImgSrc!=null) cmdExec("InsertImage",sImgSrc);
}
function Save()
{
if (isHTMLMode){alert("Please uncheck 'Edit HTML'");return;}
var sImgTag = idContent.document.body.all.tags("IMG");
var oImg;
for (var i = sImgTag.length - 1; i >= 0; i--)
{
oImg = sImgTag[i];
alert("Add your code to Upload local image file here. Image Inserted : " + oImg.src );
}
alert("Add your code to Save Document here");
alert("Your Document : " + idContent.document.body.innerHTML);
document.forms[0].indhold.value= idContent.document.body.innerHTML;
document.forms[0].submit();
}
function foreColor()
{
var arr = showModalDialog("selcolor.htm","","font-family:Verdana; font-size:12; dialogWidth:30em; dialogHeight:34em" );
if (arr != null) cmdExec("ForeColor",arr);
}
function LoadNews(news){
if(idContent.document.body)
idContent.document.body.innerHTML = news;
else
setTimeout("document.forms[0].testbtn.click()",300);
}
</script>
<%
' hvis kald intern hent data
Set objRec = DBforbindelse.execute("SELECT * FROM artikel WHERE id="& P_id)
Response.Write "<form ACTION='artikel-ret.asp' METHOD=""POST""><table bgcolor=""#a6bbd9"" width=""700"" border=""0"" align=""center"" style='border-width:1px;border-style:solid'>"
Response.Write "<tr><td>" '1.row 1.column
Response.Write "<tr><td>"
Response.Write "Rediger overskrift:<br>"
Response.Write "<input type=""HIDDEN"" VALUE='update' Name='cmd'>"
Response.Write "<input type=""HIDDEN"" VALUE=" & objRec("id") & " NAME='id'>"
'Anders - Styr på overskrifterne:
'Response.Write "<input type=""TEXT"" VALUE='" & objRec("overskrift") & "'NAME='overskrift' style='border-width:1px;border-style:solid;width:600px'>"
Response.Write "<input type=""TEXT"" VALUE=""" & objRec("overskrift") & """ NAME=""overskrift"" style=""border-width:1px;border-style:solid;width:600px"">"
Response.Write "</td></tr><tr><td>"
Response.Write "Rediger indhold:<br>"
%>
<table id="tblCoolbar" width=542 cellpadding="0" cellspacing="0">
<tr valign="middle">
<td colspan=16>
<select onchange="cmdExec('formatBlock',this[this.selectedIndex].value);this.selectedIndex=0" id=select1 name=select1>
<option selected>Style</option>
<option value="Normal">Normal</option>
<option value="Heading 1">Heading 1</option>
<option value="Heading 2">Heading 2</option>
<option value="Heading 3">Heading 3</option>
<option value="Heading 4">Heading 4</option>
<option value="Heading 5">Heading 5</option>
<option value="Address">Address</option>
<option value="Formatted">Formatted</option>
<option value="Definition Term">Definition Term</option>
</select>
<select onchange="cmdExec('fontname',this[this.selectedIndex].value);" id=select2 name=select2>
<option selected>Font</option>
<option value="Arial">Arial</option>
<option value="Arial Black">Arial Black</option>
<option value="Arial Narrow">Arial Narrow</option>
<option value="Comic Sans MS">Comic Sans MS</option>
<option value="Courier New">Courier New</option>
<option value="System">System</option>
<option value="Tahoma">Tahoma</option>
<option value="Times New Roman">Times New Roman</option>
<option value="Verdana">Verdana</option>
<option value="Wingdings">Wingdings</option>
</select>
<select onchange="cmdExec('fontsize',this[this.selectedIndex].value);" id=select3 name=select3>
<option selected>Size</option>
<option value="1">1</option>
<option value="2">2</option>
<option value="3">3</option>
<option value="4">4</option>
<option value="5">5</option>
<option value="6">6</option>
<option value="7">7</option>
<option value="8">8</option>
<option value="10">10</option>
<option value="12">12</option>
<option value="14">14</option>
</select>
</td>
</tr>
<tr>
<td><div class="cbtn" onClick="cmdExec('cut')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Cut.gif" alt="Cut">
</div></td>
<td><div class="cbtn" onClick="cmdExec('copy')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Copy.gif" alt="Copy">
</div></td>
<td><div class="cbtn" onClick="cmdExec('paste')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Paste.gif" alt="Paste">
</div></td>
<td><div class="cbtn" onClick="cmdExec('bold')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Bold.gif" alt="Bold">
</div></td>
<td><div class="cbtn" onClick="cmdExec('italic')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Italic.gif" alt="Italic">
</div></td>
<td><div class="cbtn" onClick="cmdExec('underline')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Under.gif" alt="Underline">
</div></td>
<td><div class="cbtn" onClick="cmdExec('justifyleft')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Left.gif" alt="Justify Left">
</div></td>
<td><div class="cbtn" onClick="cmdExec('justifycenter')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Center.gif" alt="Center">
</div></td>
<td><div class="cbtn" onClick="cmdExec('justifyright')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Right.gif" alt="Justify Right">
</div></td>
<td><div class="cbtn" onClick="cmdExec('insertorderedlist')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="2" vspace=1 align=absmiddle src="images/numlist.GIF" alt="Ordered List">
</div></td>
<td><div class="cbtn" onClick="cmdExec('insertunorderedlist')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="2" vspace=1 align=absmiddle src="images/bullist.GIF" alt="Unordered List">
</div></td>
<td><div class="cbtn" onClick="cmdExec('outdent')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="2" vspace=1 align=absmiddle src="images/deindent.gif" alt="Decrease Indent">
</div></td>
<td><div class="cbtn" onClick="cmdExec('indent')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="2" vspace=1 align=absmiddle src="images/inindent.gif" alt="Increase Indent">
</div></td>
<td><div class="cbtn" onClick="foreColor()" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="2" vspace=1 align=absmiddle src="images/fgcolor.gif" alt="Forecolor">
</div></td>
<td><div class="cbtn" onClick="cmdExec('createLink')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="2" vspace=1 align=absmiddle src="images/Link.gif" alt="Link">
</div></td>
<td><div class="cbtn" onClick="insertImage()" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="2" vspace=1 align=absmiddle src="images/Image.gif" alt="Image">
</div></td>
<td><div class="cbtn" onClick="Save()" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="2" vspace=1 align=left align=absmiddle src="images/Save.gif" alt="Save">
<font class=txtbtn>Save </font>
</div></td>
<td width=200></td>
</tr>
</table>
<iframe width="542" id="idContent" height="350"></iframe>
<br>
<input type="button" Value="Genindlæs" id="testbtn" name="testbtn" onclick="LoadNews('<%=Replace(objRec("indhold")&"",vbcrlf,"<br>")%>');">
<input type="checkbox" onclick="setMode(this.checked)" id=checkbox1 name=checkbox1 value="ON"> Edit HTML
<input type="hidden" name='indhold' rows='10' style='width:600px'><br>
<%
Response.Write "</td></tr><tr><td>"
select case objRec("sprog")
case "dk": v_sprog = "Dansk"
case "de": v_sprog = "Fransk"
case else: v_sprog = "Engelsk"
end select
select case objRec("kategori")
case 6: v_kategori = "Booking"
case 15: v_kategori = "Vaugrenier"
case 24: v_kategori = "Lejlighederne"
case 25: v_kategori = "Kobe-Lejlighed"
case 35: v_kategori = "Information"
case 45: v_kategori = "Rivieraen"
case 64: v_kategori = "Nyheder"
case 75: v_kategori = "Medlemsside"
case 83: v_kategori = "Testside"
case 84: v_kategori = "Administration"
case else: v_kategori = "Sightseeing" 'case 1:
'else: v_kategori = "Sightseeing" 'case 1:
end select
Response.Write "Kategorien af artikler er: <u>"& v_kategori & "</u> Og valgt sprog er: <u>"& v_sprog &"</u><br>"
Response.Write "<input type='button' VALUE='Opdater' style='border-width:1px;border-style:solid;height:20px;font-family:Verdana;font-size:11px' OnClick='Save()'>"
Response.Write " Indlæg oprettet den: "
Response.Write objRec("artikelstartdato")
Response.Write " Indlæg sidst rettet den: "
Response.Write objRec("redigeringsdato")
Response.Write " <button onClick='java script:history.back()' style='font-family:Verdana;font-size:11px;border-width:1px;border-style:solid;height:20px'>Fortryd</button>"
Response.Write "<A HREF=""java script:nytVindue();""> Hjælp </A>"
Response.Write "</td></tr>"
Response.Write "</td></tr></table></form>"
ELSEif P_cmd="ny" THEN
%>
<script language="JavaScript">
function button_over(eButton)
{
eButton.style.backgroundColor = "#B5BDD6";
eButton.style.borderColor = "darkblue darkblue darkblue darkblue";
}
function button_out(eButton)
{
eButton.style.backgroundColor = "threedface";
eButton.style.borderColor = "threedface";
}
function button_down(eButton)
{
eButton.style.backgroundColor = "#8494B5";
eButton.style.borderColor = "darkblue darkblue darkblue darkblue";
}
function button_up(eButton)
{
eButton.style.backgroundColor = "#B5BDD6";
eButton.style.borderColor = "darkblue darkblue darkblue darkblue";
eButton = null;
}
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
var isHTMLMode=false
function document.onreadystatechange()
{
idContent.document.designMode="On";
}
function cmdExec(cmd,opt)
{
if (isHTMLMode){alert("Please uncheck 'Edit HTML'");return;}
idContent.document.execCommand(cmd,"",opt);idContent.focus();
}
function setMode(bMode)
{
var sTmp;
isHTMLMode = bMode;
if (isHTMLMode){sTmp=idContent.document.body.innerHTML;idContent.document.body.innerText=sTmp;}
else {sTmp=idContent.document.body.innerText;idContent.document.body.innerHTML=sTmp;}
idContent.focus();
}
function createLink()
{
if (isHTMLMode){alert("Please uncheck 'Edit HTML'");return;}
cmdExec("CreateLink");
}
function insertImage()
{
if (isHTMLMode){alert("Please uncheck 'Edit HTML'");return;}
var sImgSrc=prompt("Insert Image File (You can use your local image file) : ", "
http://www.aspalliance.com/Yusuf/Article10/sample.jpg");
if(sImgSrc!=null) cmdExec("InsertImage",sImgSrc);
}
function Save()
{
if (isHTMLMode){alert("Please uncheck 'Edit HTML'");return;}
var sImgTag = idContent.document.body.all.tags("IMG");
var oImg;
for (var i = sImgTag.length - 1; i >= 0; i--)
{
oImg = sImgTag[i];
alert("Add your code to Upload local image file here. Image Inserted : " + oImg.src );
}
alert("Add your code to Save Document here");
alert("Your Document : " + idContent.document.body.innerHTML);
document.forms[0].indhold.value= idContent.document.body.innerHTML;
document.forms[0].submit();
}
function foreColor()
{
var arr = showModalDialog("selcolor.htm","","font-family:Verdana; font-size:12; dialogWidth:30em; dialogHeight:34em" );
if (arr != null) cmdExec("ForeColor",arr);
}
function LoadNews(news){
if(idContent.document.body)
idContent.document.body.innerHTML = news;
else
setTimeout("document.forms[0].testbtn.click()",300);
}
</script>
<%
' hvis kald intern hent data
Response.Write "<form ACTION='artikel-ret.asp' METHOD=""POST""><table bgcolor=""#a6cce1"" width=""700"" border=""0"" align=""center"">"&_
"<tr><td>"&_
"<tr><td>"&_
"Opret overskrift:<br>"&_
"<input type=""HIDDEN"" VALUE='create' Name='cmd'>"&_
"<input type=""TEXT"" VALUE='' NAME='overskrift' style='width:600px'>" &_
"</td></tr><tr><td>"&_
"Opret indhold:<br>"
%>
<table id="tblCoolbar" width=542 cellpadding="0" cellspacing="0">
<tr valign="middle">
<td colspan=16>
<select onchange="cmdExec('formatBlock',this[this.selectedIndex].value);this.selectedIndex=0" id=select1 name=select1>
<option selected>Style</option>
<option value="Normal">Normal</option>
<option value="Heading 1">Heading 1</option>
<option value="Heading 2">Heading 2</option>
<option value="Heading 3">Heading 3</option>
<option value="Heading 4">Heading 4</option>
<option value="Heading 5">Heading 5</option>
<option value="Address">Address</option>
<option value="Formatted">Formatted</option>
<option value="Definition Term">Definition Term</option>
</select>
<select onchange="cmdExec('fontname',this[this.selectedIndex].value);" id=select2 name=select2>
<option selected>Font</option>
<option value="Arial">Arial</option>
<option value="Arial Black">Arial Black</option>
<option value="Arial Narrow">Arial Narrow</option>
<option value="Comic Sans MS">Comic Sans MS</option>
<option value="Courier New">Courier New</option>
<option value="System">System</option>
<option value="Tahoma">Tahoma</option>
<option value="Times New Roman">Times New Roman</option>
<option value="Verdana">Verdana</option>
<option value="Wingdings">Wingdings</option>
</select>
<select onchange="cmdExec('fontsize',this[this.selectedIndex].value);" id=select3 name=select3>
<option selected>Size</option>
<option value="1">1</option>
<option value="2">2</option>
<option value="3">3</option>
<option value="4">4</option>
<option value="5">5</option>
<option value="6">6</option>
<option value="7">7</option>
<option value="8">8</option>
<option value="10">10</option>
<option value="12">12</option>
<option value="14">14</option>
</select>
</td>
</tr>
<tr>
<td><div class="cbtn" onClick="cmdExec('cut')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Cut.gif" alt="Cut">
</div></td>
<td><div class="cbtn" onClick="cmdExec('copy')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Copy.gif" alt="Copy">
</div></td>
<td><div class="cbtn" onClick="cmdExec('paste')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Paste.gif" alt="Paste">
</div></td>
<td><div class="cbtn" onClick="cmdExec('bold')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Bold.gif" alt="Bold">
</div></td>
<td><div class="cbtn" onClick="cmdExec('italic')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Italic.gif" alt="Italic">
</div></td>
<td><div class="cbtn" onClick="cmdExec('underline')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Under.gif" alt="Underline">
</div></td>
<td><div class="cbtn" onClick="cmdExec('justifyleft')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Left.gif" alt="Justify Left">
</div></td>
<td><div class="cbtn" onClick="cmdExec('justifycenter')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Center.gif" alt="Center">
</div></td>
<td><div class="cbtn" onClick="cmdExec('justifyright')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="1" vspace=1 align=absmiddle src="images/Right.gif" alt="Justify Right">
</div></td>
<td><div class="cbtn" onClick="cmdExec('insertorderedlist')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="2" vspace=1 align=absmiddle src="images/numlist.GIF" alt="Ordered List">
</div></td>
<td><div class="cbtn" onClick="cmdExec('insertunorderedlist')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="2" vspace=1 align=absmiddle src="images/bullist.GIF" alt="Unordered List">
</div></td>
<td><div class="cbtn" onClick="cmdExec('outdent')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="2" vspace=1 align=absmiddle src="images/deindent.gif" alt="Decrease Indent">
</div></td>
<td><div class="cbtn" onClick="cmdExec('indent')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="2" vspace=1 align=absmiddle src="images/inindent.gif" alt="Increase Indent">
</div></td>
<td><div class="cbtn" onClick="foreColor()" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="2" vspace=1 align=absmiddle src="images/fgcolor.gif" alt="Forecolor">
</div></td>
<td><div class="cbtn" onClick="cmdExec('createLink')" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="2" vspace=1 align=absmiddle src="images/Link.gif" alt="Link">
</div></td>
<td><div class="cbtn" onClick="insertImage()" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="2" vspace=1 align=absmiddle src="images/Image.gif" alt="Image">
</div></td>
<td><div class="cbtn" onClick="Save()" onmouseover="button_over(this);" onmouseout="button_out(this);" onmousedown="button_down(this);" onmouseup="button_up(this);">
<img hspace="2" vspace=1 align=left align=absmiddle src="images/Save.gif" alt="Save">
<font class=txtbtn>Save </font>
</div></td>
<td width=200></td>
</tr>
</table>
<iframe width="542" id="idContent" height="350"></iframe>
<br>
<input type="checkbox" onclick="setMode(this.checked)" id=checkbox1 name=checkbox1 value="ON"> Edit HTML
<input type="hidden" name='indhold' rows='10' style='width:600px'><br>
<% Response.write "Vælg Kategori <SELECT name=kat><OPTION value='1'>Sightseeing</OPTION>"&_
"<OPTION value='15'>Vaugrenier</OPTION><OPTION value='25'>Køb af Lejlighed</OPTION><OPTION value='24'>Lejlighederne</OPTION><OPTION value='35'>Information</OPTION><OPTION value='45'>Rivieraen</OPTION><OPTION value='64'>Nyheder</OPTION><OPTION value='75'>Medlemsside</OPTION><OPTION value='6'>Bookning-leje af lejl.</OPTION><OPTION value='84'>Administration</OPTION><OPTION value='83'>Testside</OPTION></SELECT>"&_
"Sæt artiklens Sprog "&_
"<SELECT name=sprog><OPTION value='dk'>Dansk</OPTION>"&_
"<OPTION value='de'>Fransk</OPTION>"&_
"<OPTION value='gb'>Engelsk</OPTION>"&_
"</SELECT>"&_
"</td></tr><tr><td>"&_
"<input type='submit' VALUE='Opret'>"&_
"<A HREF=""java script:nytVindue();""> Hjælp </A>"&_
"</td></tr>"&_
"</td></tr></table></form>"
ELSEIf (P_cmd="create") THEN
if request.servervariables("REQUEST_METHOD")="POST" THEN
p_overskrift= Replace(Request.Form("overskrift")&"", "'", "''")
p_indhold = Replace(Request.Form("indhold")&"", "'", "''")
ELSE
p_overskrift= Replace(Request.Querystring("overskrift")&"", "'", "''")
p_indhold = Replace(Request.Querystring("indhold")&"", "'", "''")
END IF
StrSql="INSERT INTO artikel (overskrift, indhold, artikelstartdato, kategori, sprog) "&_
"VALUES ('" & P_overskrift &"','" & p_indhold &"','" & Date &"','"& P_kat &"','"& P_sprog &"')"
DBforbindelse.execute(strsql)
'DBforbindelse.Execute
Set DBforbindelse = Nothing
Response.Clear
Response.Redirect "artikel-ret.asp"
ELSEIF ((P_cmd="update") AND (P_id <> 0)) THEN
if request.servervariables("REQUEST_METHOD")="POST" THEN
p_overskrift= Replace(Request.Form("overskrift")&"", "'", "''")
p_indhold = Replace(Request.Form("indhold")&"", "'", "''")
ELSE
p_overskrift= Replace(Request.Querystring("overskrift")&"", "'", "''")
p_indhold = Replace(Request.Querystring("indhold")&"", "'", "''")
END IF
StrSql="UPDATE artikel SET overskrift='"&P_overskrift&"', indhold='" & p_indhold & "', redigeringsdato='" & date &"' WHERE id=" & p_id
DBforbindelse.execute(strsql)
Set DBforbindelse = Nothing
Response.Clear
Response.Redirect "artikel-ret.asp"
END IF 'update
%>
</td>
</tr>
</table>
</body>
</html>