<%
if Request.Form("Gem") = "Gem" then
%><!--#include file="includes\asp_conn.inc"--><%
dim oprettet, menu, linknavn, link
oprettet = "MBI"
menu = Request.Form("under")
linknavn = Request.Form("link_navn")
link = Request.Form("type") & Request.Form("url")
strSQL = "INSERT INTO menuer (oprettet_af,menu_navn,link_navn,link) VALUES ('"&oprettet&"','"&menu&"','"&linknavn&"','"&link&"')"
Conn.Execute(strSQL)
Conn.Close
Set Conn = Nothing
end if
%>
<html>
<head>
<link rel="stylesheet" type="text/css" href="style/stylesmenu.css">
<title>Opret ny link</title>
</head>
<body>
<script>
function selectone()
{
document.minform.urlone.value="";
document.minform.urltwo.value="";
document.minform.urlone.disabled=false;
document.minform.urltwo.disabled=false;
if(document.minform.type.value=="
http://")
{
document.minform.urltwo.disabled=true;
document.minform.urltwo.style.display='none';
document.minform.urlone.style.display='normal';
document.minform.urlone.disabled=false;
document.minform.urlone.value="";
document.minform.urlone.focus();
}
else
{
document.minform.urlone.disabled=true;
document.minform.urloen.style.display='none';
document.minform.urltwo.style.display='normal';
document.minform.urltwo.disabled=false;
document.minform.urltwo.value="skriv her";
document.minform.urltwo.focus();
}
}
</script>
<table align='center'>
<form method="POST" name="minform" action="opretmenupunkt.asp">
<tr>
<td colspan="2" align="center" class="overskrift" height="50">Opret link
</td>
<tr>
<tr><td>
<p class='broedtekst'>Hvem skal kunne se linket</p>
</td>
<td>
<select size="1" name="status" class='broedtekst'>
<option value="alle" selected>Alle
<option value="personligt">Kun mig
<option value="afdelinger">Afdelingen
</select>
</td>
<tr><td>
<p class='broedtekst'>Menupunkt oprettes under</p>
</td>
<td>
<select size="1" name="under" class='broedtekst'>
<option value="ddd">ddd
<option value="personale">Personale
<option value="projekter">Projekter
<option value="teknik">Teknik
<option value="drift">Drift
<option value="udvikling">Udvikling
<option value="dokumentation">Dokumentation
<option value="links">Links
</select>
</td>
<tr>
<td>
<p class='broedtekst'>Navn</p>
</td>
<td>
<input type="text" name="link_navn" size="20" class='broedtekst'>
</td>
</tr>
<tr>
<td>
<p class='broedtekst'>Adressen</p>
</td>
<td>
<select size="1" name="type" class='broedtekst' onchange="java script:selectone();">
<option value="
http://" selected>http://
<option value="
file://">file://</select>
<input type='text' name='urlone' size='20'>
<input type='file' name='urltwo' size='20'>
</td>
</tr>
<tr>
<td colspan="2" align="left" height="50">
<input type='submit' class="button1" value="Gem" name="Gem">
<input type='reset' class="button1" value='Nulstil'>
<input type='button' class="button1" value='Luk' onclick="window.close()";>
</td>
</tr>
</form>
</table>
</body>
</html>