Topic: Validation Issues. Pages that link to <a href="https://ozoneasylum.com/backlink?for=11071" title="Pages that link to Topic: Validation Issues." rel="nofollow" >Topic: Validation Issues.\

 
Author Thread
H][RO
Bipolar (III) Inmate

From: Australia
Insane since: Oct 2002

IP logged posted posted 10-09-2003 09:44 Edit Quote

Hi all, i'm trying to validate my pages here at padprint.com.au but im getting some errors i need some help with. I'm going for HTML 4.01 Strict but im not sure if its possible with what im doing.

I did it on www.padprint.com.au/home.html and i get about 13 errors, however most of them are the same. The first five done like anything about this code:

<BODY background="white" topmargin=0 leftmargin=0 marginheight=0 marginwidth=0>

which i need in there for opera etc to recognise. (unless there is another way, it doesnt want to use my margin=0px; in the css)

The next errors 6 - 12, are all to do with the flash im embedding, maybe strict just doesnt allow it or maybe im doing it wrong? This is the code:

<object classid="clsid 27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" width="1024" height="120">
<param name=movie value="Art/Header.swf">
<param name=quality value=high>
<embed src="Art/Header.swf" quality=high pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="1024" height="120">
</embed>
</object>

The last error 13 is simply:

<a name="home"></a>

I have no idea why it does this one, maybe it doesnt like where it is, but i have other occurences of this and it doesnt complain about them.. so im very confused.

As you can see nothing major just a few annoying things stopping me from validating, any help would be great, thanks all!

H][RO
Bipolar (III) Inmate

From: Australia
Insane since: Oct 2002

IP logged posted posted 10-09-2003 09:49 Edit Quote

Another issue is with this code:

error: Line 50, column 54: there is no attribute "BORDER" (explain...).

<img src="art/Information-Process.gif" border="1"/>

Apparently there is no attribute border in an image tag, is this correct? I thought there was and it displays a border, maybe its just not part of html strict?

Lastly, whenever i have a php reference it doesnt like it, like something.php?option=xx&type=yy.
it doesnt validation with that sort of stuff, is it simply not possible to validate when including php?



[This message has been edited by H][RO (edited 10-09-2003).]

Emperor
Maniac (V) Mad Scientist with Finglongers

From: Cell 53, East Wing
Insane since: Jul 2001

IP logged posted posted 10-09-2003 10:48 Edit Quote

H][RO: OK:

1. Use CSS body { margin: 0px; } and Opera should be fine.

2. I'm afraid the Flash code is a validating nightmare - see ALA's Flash Satay.

3. I don't think it likes empty elements so jam in a &amp;nbsp;

4. I always try and avoid the border attribute and use styles where necessary (I thought it was OK in HTML 4.01 but..).

5. Yep it will not be happy with that and it is due to the & in the querystring - use &amp;amp;.

___________________
Emps

The Emperor dot org

H][RO
Bipolar (III) Inmate

From: Australia
Insane since: Oct 2002

IP logged posted posted 10-09-2003 11:40 Edit Quote

Thanks emp.

1. In my css file i have body { margin:0px;} but it doesnt set the margins to 0 in opera,mozila, or netscape unless i have it as ive shown above for some reason? it is supposed to work thought is it?

5.So putting &amp in a php string still works does does it?

HZR
Bipolar (III) Inmate

From: Cold Sweden
Insane since: Jul 2002

IP logged posted posted 10-09-2003 11:43 Edit Quote

Error 1-5 should all be set with CSS.
Error 6-12 has to do with the Flash. IMO it's not _that_ big of a deal if it doesn't validate. See the article Emperor talked about though: http://www.alistapart.com/stories/flashsatay/
Error 13, put it in a paragraph. Though I don't really see the need of it. If you want a link to go to the top of the page, just use href="#".



[This message has been edited by HZR (edited 10-09-2003).]

H][RO
Bipolar (III) Inmate

From: Australia
Insane since: Oct 2002

IP logged posted posted 10-09-2003 11:57 Edit Quote

I know 1-5 should be set in CSS and they ARE, my problem is that opera etc dont seem to recognise that they are, here is my css code i think its all i need isnt it for that part?

body /*Main Body Settings*/
{
padding: 0px;
margin: 0px;
background-color: white;
background-image: url(Art/background.jpg);
background-repeat: no-repeat;
background-position: top left;
}

Emperor
Maniac (V) Mad Scientist with Finglongers

From: Cell 53, East Wing
Insane since: Jul 2001

IP logged posted posted 10-09-2003 14:54 Edit Quote

H][RO: I can't see why that doesn't work - I have used similar styles and they work fine in Opera.

Some thoughts:

1. What version of Opera are you using to test? I wouldn't worry if it doesn't work in Op <= 6 as long as it works in 7.

2. It may be a DOCTYPE issue - its possible Opera might only allow this for XHTML?

3. Try applying the padding and margin to html not body?

I'm not overly convinced with them but if I was was having that problem they would be the first 3 things I'd fiddle with to see if that fixes it.

Emps

___________________
Emps

The Emperor dot org

H][RO
Bipolar (III) Inmate

From: Australia
Insane since: Oct 2002

IP logged posted posted 10-09-2003 16:10 Edit Quote

Yeh thanks.

Honestly im not too fussed about it, im not going to put a w3c logo on or anything. As long as most of the code validations (i.e i have done stupid stuff) then its ok for me. My main concern obviously is that it works in most browsers, and if i need to put something in the code that breaks validation to do that then i will.

Having said that it should work for opera =/ and im using version 6.03. Imight install version 7 see how that goes. But it was the same for netscape 6 and mozilla, they didnt want to recognise margin=0px either...

DL-44
Maniac (V) Inmate

From: under the bed
Insane since: Feb 2000

IP logged posted posted 10-09-2003 21:10 Edit Quote

interesting article about validation - http://development.gurusnetwork.com/discussion/showthread.php?s=&threadid=2313


Not sure what the problem with the margin is - do it all the time and have had no problems.

For kicks, try removing the 'px' from the value. It is not needed, and who knows - it could even be causing a problem...

so you'd have

body {
margin:0;
padding:0;
}

[This message has been edited by DL-44 (edited 10-09-2003).]

H][RO
Bipolar (III) Inmate

From: Australia
Insane since: Oct 2002

IP logged posted posted 10-10-2003 04:43 Edit Quote

Pretty good read that...
Anyhow i've had a go... Now i took out the 'px' in the .css file - no change.

The only way i could get it to work was putting the
body
{margin:0; padding:0;} in the header. for some reason it wont work from the linked file.

Can anyone explain why this would happen? The rest of the css formatting is working fine so it must be importing the file ok, and all it does is place the css code where that link is referenced anyhow so i dont see the problem.

Anyone? thanks all.

H][RO
Bipolar (III) Inmate

From: Australia
Insane since: Oct 2002

IP logged posted posted 10-10-2003 04:55 Edit Quote

Argg the nightmare...
this also only works for opera and not mozilla ...

ozphactor
Maniac (V) Inmate

From: California
Insane since: Jul 2003

IP logged posted posted 10-10-2003 07:06 Edit Quote

I see the problem. You have this in your CSS file:

quote:
<style type="text/css">


That's HTML, and you're forcing the browser to parse it as CSS, which obviously won't work. Remove it, and you shouldn't have any problems. You only need that code for embedded stylesheets, not for external ones.


H][RO
Bipolar (III) Inmate

From: Australia
Insane since: Oct 2002

IP logged posted posted 10-10-2003 10:22 Edit Quote

ack i did see that there, then just assumed it was meant to be there, stupid me.

Thanks for that looks like its fixed it!

H][RO
Bipolar (III) Inmate

From: Australia
Insane since: Oct 2002

IP logged posted posted 10-10-2003 10:31 Edit Quote

Back to the validating however, i cant seem to validate any html code that goes to php, is it possible?

so products.php?option=machines&type=1

it doesnt like the &, emporer said to use &amp but it doesnt like this, it then reads it at & amptype
etc.. is there anyway around this?

H][RO
Bipolar (III) Inmate

From: Australia
Insane since: Oct 2002

IP logged posted posted 10-10-2003 11:09 Edit Quote

Nevermind i had to put &amp;

i was leaving off the semicolon...

DL-44
Maniac (V) Inmate

From: under the bed
Insane since: Feb 2000

IP logged posted posted 10-10-2003 15:23 Edit Quote

For that you should be using '& a m p ;'

(that may be what you typed, and it was parsed as '&', but just in case.....)

smonkey
Paranoid (IV) Inmate

From: Northumberland, England
Insane since: Apr 2003

IP logged posted posted 10-11-2003 22:40 Edit Quote

I have problems with the margin in opera too - moz and ie seem to respect the body {margin:0px} but opera 6 and 7 both don't obey it - I use a valid XHTML Transitional Doctype and find that the only way to get opera to get rid of the left and right margins is to use marginheight="0" marginwidth="0" which immediately invalidates any code I write

I'm not to cut up about not validating, but it does suck a bit when browsers don't obey what they claim to.

As mentioned previously, maybe the Doctype needs to be XHTML Strict to fix opera. If I can be arsed I'll do some tests sometime soonish, but for now I'll just not validate and be proud of it!

H][RO
Bipolar (III) Inmate

From: Australia
Insane since: Oct 2002

IP logged posted posted 10-12-2003 10:43 Edit Quote

I got pretty much everything validated and working, one more issue in I.e5.0 and below to fix and then im happy as larry



Post Reply
 
Your User Name:
Your Password:
Login Options:
 
Your Text:
Loading...
Options:


« BackwardsOnwards »

Show Forum Drop Down Menu