...

View Full Version : Validation



PitbullMean
02-22-2009, 10:31 PM
I got rid of like 50 errors on my site but I dont know why or how to correct this errors

http://validator.w3.org/check?uri=http%3A%2F%2Fwww.habugfx.com%2Fportfolio.php&charset=(detect+automatically)&doctype=Inline&ss=1&group=0&No200=1&user-agent=W3C_Validator%2F1.606#line-57


<td width="50%" height="21"><p align="left"><a href="#" onClick="backward();return false">Previous Design </a></p></td>


http://validator.w3.org/check?uri=http%3A%2F%2Fwww.habugfx.com%2Fcontact.php&charset=(detect+automatically)&doctype=Inline&ss=1&group=0&user-agent=W3C_Validator%2F1.606


<div style="padding-left:10px" align="left">Name:</div>

<div style="padding-left:10px" align="left"><br />

<div style="padding-left:10px" align="left"><br />


Any Help with this will be appreciated.

`Jeremy
02-22-2009, 10:47 PM
The align attribute is deprecated.

Just throw "text-align:left;" in your style attribute.

gnomeontherun
02-22-2009, 10:48 PM
1) I believe it must be lower case.


<td width="50%" height="21"><p align="left"><a href="#" onclick="backward();return false">Previous Design </a></p></td>

2) I believe a <div> is not allowed inside of a <label>, try <p> or nothing at all really. <label> is a text wrapper already.

PitbullMean
02-22-2009, 11:29 PM
I just removed the div tag and added a class to the label tag thank jeremywilken

PitbullMean
02-23-2009, 12:08 AM
I got another validation problem, some XML Parse problem on a friend of mines site

http://validator.w3.org/check?uri=http%3A%2F%2Fwww.elite-rangers.com%2FWGH%2Forder.html&charset=(detect+automatically)&doctype=Inline&ss=1&group=0&user-agent=W3C_Validator%2F1.606

gnomeontherun
02-23-2009, 12:39 AM
Looks like your missing a closing </div> and on Line 20, Column 74: there is no attribute "srcover", meaning you meant 'src' but have 'srcover'.

The rest might sort out when you fix those.

PitbullMean
02-23-2009, 01:03 AM
well the srcover is a image rollover in the navigation.

.nav {
background: url(../images/navigation/nav_bg.jpg) repeat-x;
width:100%;
height:30px;
margin:auto;
text-align:center;
}


<div class="nav">
<a href="index.html"><img src="images/navigation/homeoff.jpg" srcover="images/navigation/homeon.jpg" alt=""/></a>
<a href="#"><img src="images/navigation/supportoff.jpg" srcover="images/navigation/supporton.jpg" alt=""/></a>
<a href="demo.html"><img src="images/navigation/demooff.jpg" srcover="images/navigation/demoon.jpg" alt=""/></a>
<a href="testimonial.html"><img src="images/navigation/testoff.jpg" srcover="images/navigation/teston.jpg" alt=""/></a>
<a href="#"><img src="images/navigation/voiceoff.jpg" srcover="images/navigation/voiceon.jpg" alt=""/></a>
<a href="packages.html"><img src="images/navigation/packoff.jpg" srcover="images/navigation/packon.jpg" alt=""/></a>
</div>

Heres the link to the site;

http://elite-rangers.com/WGH/

gnomeontherun
02-23-2009, 11:29 AM
It is not an attribute in that DOCTYPE. You should use CSS to do that instead with a :hover attribute to switch between images instead of that attribute.

PitbullMean
02-23-2009, 06:51 PM
Can you give me an example

2 or 3 links so i can see what u did.

gnomeontherun
02-23-2009, 09:19 PM
http://www.tutorio.com/tutorial/pure-css-image-rollovers/

PitbullMean
02-23-2009, 10:13 PM
ok i did what the code shows but its not going horizontal its vertical maybe im doing something wrong.



.rollover a {
display:block;
width: 118px;
height:30px;
font: bold 13px sans-serif;;
color:#fff;
background: url(../images/navigation/nav.jpg) 0 0 no-repeat;
text-decoration: none;
padding-top:7px;
}
.rollover a:hover {
background-position: 0 -30px;
color: #fff;
}


<div class="rollover">

<a href="#">Item 1</a>
<a href="#">Item 2</a>
<a href="#">Item 3</a>
<a href="#">Tutorio</a>
</div>

PitbullMean
02-23-2009, 10:54 PM
Any help would be appreciated

http://elite-rangers.com/WGH/ to see what i mean

gnomeontherun
02-24-2009, 12:36 AM
Hey, I don't mind helping but I do appreciate not being pushed. I'm aware when you post, its in my user panel, so please don't take advantage of the people here.

So my challenge to you is this: determine the reason this code forces each item on a new line.


display:block;
width: 118px;
height:30px;

PitbullMean
02-24-2009, 01:29 AM
How am I taking advantage of people I give help too when i understand the topic this is why im asking cause i dont fully understand CSS.

Anyway I added this instead of what u posted

height:23px;
width:118px;
float:left;

Its now horizontal but not centered, Any Idea?

gnomeontherun
02-24-2009, 09:55 AM
I'm saying not to be pushy by sending a PM for me to check it, it makes it seem like you are somewhat demanding my help asap. It just makes me feel like I'm being used, which is why I mention it. I'm glad you help too, thats very important and rates high in my mind.

Now to the point at hand.

With a block element everything forces the next element down, unless you make it float. However you should leave the display:block statement.


display:block;
width: 118px;
height:30px;
float:left;
text-align: center;

If you are trying to center the stuff inside the anchor add the last line. If you are trying to center the whole nav bar, then try this (change the width as appropriate), and it will center the rollover list inside of its container.


.rollover
{
width: 472px;
margin: 0 auto;
}

PitbullMean
02-24-2009, 05:08 PM
Ya i figured that out when i was looking at the code for a good 20 mins.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum