JavaScript and client side scripting.
Moderator: General Moderators
m2babaey
Forum Contributor
Posts: 364 Joined: Sun May 20, 2007 9:26 am
Post
by m2babaey » Sat Jul 28, 2007 7:29 pm
Hi
I want to code something like this:
http://pedia.sys17.net/css1.htm
using the code below:
Code: Select all
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=windows-1250">
<meta name="generator" content="PSPad editor, http://www.pspad.com">
<title></title>
<style type="text/css">
img.1 {z-index:-1;}
img.2 {top:20px;
left=0px;
}
div {display: none}
</style>
</head>
<body>
<img class="1" border="0" src="big.jpg" width="720" height="180">
<img class="2" src="login.gif" >
<img class="2" border="0" src="logout.gif" width="144" height="72"><img class="2" border="0" src="add.gif" width="144" height="72"><img class="2" border="0" src="pass.gif" width="144" height="72"></p>
</body>
</html>
but you see it's not working. what is wrong?
Charles256
DevNet Resident
Posts: 1375 Joined: Fri Sep 16, 2005 9:06 pm
Post
by Charles256 » Sat Jul 28, 2007 7:39 pm
You could try absolute positioning (i.e. position:absolute;) but in your case I'd just use a background color to replicate that instead of that big huge background image
califdon
Jack of Zircons
Posts: 4484 Joined: Thu Nov 09, 2006 8:30 pm
Location: California, USA
Post
by califdon » Sat Jul 28, 2007 9:25 pm
I ran into this recently. You can't name, or even begin the name of a class with a numeral. Change to img.a and img.b.
Charles256
DevNet Resident
Posts: 1375 Joined: Fri Sep 16, 2005 9:06 pm
Post
by Charles256 » Sat Jul 28, 2007 9:58 pm
Wow.. I can't believe I didn't notice he did that. Good eyes califdone.
superdezign
DevNet Master
Posts: 4135 Joined: Sat Jan 20, 2007 11:06 pm
Post
by superdezign » Sun Jul 29, 2007 8:27 am
califdon wrote: I ran into this recently. You can't name, or even begin the name of a class with a numeral. Change to img.a and img.b.
I think that IE allows it though. Ahh, Microsoft...