Avatar billede dj.iceman Nybegynder
27. oktober 2002 - 14:13 Der er 7 kommentarer og
1 løsning

CSS i ASP

Hvorfor virker dette ikke i ASP?!?
<style type=\"text/css\">
.Submit {
  background-color : #D6DEE7;   
  border : 1px solid #2B4A7B;
  font-size: 10px;
  font-family: Century Gothic;
  font-weight: ;
  color: #2B4A7B
}
.knap {
  background-color : #D6DEE7;   
  border : 1px solid #2B4A7B;
  font-size: 10px;
  font-family: Century Gothic;
  font-weight: ;
  color: #2B4A7B
}
</style>
Avatar billede grunken Nybegynder
27. oktober 2002 - 14:19 #1
det kommer vist helt an på hvor du placerer det i din kode :)

<html>
<head>
<style type="text/css">
.Submit {
  background-color : #D6DEE7;   
  border : 1px solid #2B4A7B;
  font-size: 10px;
  font-family: Century Gothic;
  font-weight: ;
  color: #2B4A7B
}
.knap {
  background-color : #D6DEE7;   
  border : 1px solid #2B4A7B;
  font-size: 10px;
  font-family: Century Gothic;
  font-weight: ;
  color: #2B4A7B
}
</style>
</head>

<%
Response.write blabla
%>

</html>
Avatar billede neteffect Nybegynder
27. oktober 2002 - 14:35 #2
font-weight: ;
Hvad siger w3c-validatoren til dét?
Avatar billede hells Nybegynder
27. oktober 2002 - 14:36 #3
<style type=\"text/css\">
skråstregerne er dre vist ikke brug for her. hvis det er fordi du udskriver det med response.write skal det laves sådan her:
Response.Write "<style type=""text/css"">"
Avatar billede dj.iceman Nybegynder
27. oktober 2002 - 14:41 #4
Hvad skal man så når man har
<input type="submit" class="Submit" value="Login" name="Action">
mht. response.write
Avatar billede hells Nybegynder
27. oktober 2002 - 14:44 #5
vel nok:
Response.Write "<input type=""submit"" class=""Submit"" value=""Login"" name=""Action"">"
det specielle er at " skrives som ""
Avatar billede dj.iceman Nybegynder
28. oktober 2002 - 16:28 #6
Kan fandeme ikke få det til at virke, så nu poster jeg lige hele siden, er der så ikke en der kan få det til (sætter lige pointene lidt op)!
Hele koden:
<html>
<head>
<title>Login script</title>
<style type=\"text/css\">
.Submit {
  background-color : #D6DEE7;   
  border : 1px solid #2B4A7B;
  font-size: 10px;
  font-family: Century Gothic;
  font-weight: ;
  color: #2B4A7B
}
.knap {
  background-color : #D6DEE7;   
  border : 1px solid #2B4A7B;
  font-size: 10px;
  font-family: Century Gothic;
  font-weight: ;
  color: #2B4A7B
}
</style>
</head>
<body>
<form method="POST" action="login.asp">
  <p><font face="Century Gothic" style="font-size: 9pt">Angiv brugernavn og adgangskode</font></p><%=strErr%>
  <table border="0">
    <tr>
      <td width="50%"><font face="Century Gothic" style="font-size: 9pt">Brugernavn:</font></td>
      <td width="50%"><font face="Century Gothic" style="font-size: 9pt"><input type="text" class="knap" name="Brugernavn" size="20"> </font></td>
    </tr>
    <tr>
      <td width="50%"><font face="Century Gothic" style="font-size: 9pt">Adgangskode:</font></td>
      <td width="50%"><font face="Century Gothic" style="font-size: 9pt"><input type="password" class="knap" name="Adgangskode" size="20"> </font></td>
    </tr>
  </table>
  <p><font face="Century Gothic" style="font-size: 9pt"><input type="submit" class="Submit" value="Login" name="Action"></font></p>
</form>
</body>
</html>
Avatar billede neteffect Nybegynder
28. oktober 2002 - 16:48 #7
<html>
<head>
<title>Login script</title>
<style type="text/css">
.Submit {
  background-color : #D6DEE7;   
  border : 1px solid #2B4A7B;
  font-size: 10px;
  font-family: Century Gothic;
  font-weight: normal;
  color: #2B4A7B
}
.knap {
  background-color : #D6DEE7;   
  border : 1px solid #2B4A7B;
  font-size: 10px;
  font-family: Century Gothic;
  font-weight: normal;
  color: #2B4A7B
}
</style>
</head>
<body>
<form method="POST" action="login.asp">
  <p><font face="Century Gothic" style="font-size: 9pt">Angiv brugernavn og adgangskode</font></p><%=strErr%>
  <table border="0">
    <tr>
      <td width="50%"><font face="Century Gothic" style="font-size: 9pt">Brugernavn:</font></td>
      <td width="50%"><font face="Century Gothic" style="font-size: 9pt"><input type="text" class="knap" name="Brugernavn" size="20"> </font></td>
    </tr>
    <tr>
      <td width="50%"><font face="Century Gothic" style="font-size: 9pt">Adgangskode:</font></td>
      <td width="50%"><font face="Century Gothic" style="font-size: 9pt"><input type="password" class="knap" name="Adgangskode" size="20"> </font></td>
    </tr>
  </table>
  <p><font face="Century Gothic" style="font-size: 9pt"><input type="submit" class="Submit" value="Login" name="Action"></font></p>
</form>
</body>
</html>
Avatar billede dj.iceman Nybegynder
28. oktober 2002 - 17:00 #8
Thanks man!
Avatar billede Ny bruger Nybegynder

Din løsning...

Tilladte BB-code-tags: [b]fed[/b] [i]kursiv[/i] [u]understreget[/u] Web- og emailadresser omdannes automatisk til links. Der sættes "nofollow" på alle links.

Loading billede Opret Preview
Kategori
Kurser inden for grundlæggende programmering

Log ind eller opret profil

Hov!

For at kunne deltage på Computerworld Eksperten skal du være logget ind.

Det er heldigvis nemt at oprette en bruger: Det tager to minutter og du kan vælge at bruge enten e-mail, Facebook eller Google som login.

Du kan også logge ind via nedenstående tjenester