Go Back   CodingForums.com > :: Client side development > HTML & CSS

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 07-18-2007, 11:52 AM   PM User | #1
AndyArmstrong
Regular Coder

 
Join Date: Jun 2007
Posts: 145
Thanks: 0
Thanked 0 Times in 0 Posts
AndyArmstrong is an unknown quantity at this point
Cool Fixed 80 Errors, 6 to go and stuck!

I have been having problems with resolution compatibility of my new website being built at :
http://www.new.3genergi.co.uk
Username:newsite
Password:123newsite

It is best viewed at 1280x1024 - i say best - it just plain doesnt work currently on any other resolution. You guys suggested getting the code to validate for the homepage and that would be a great start - so off to work i went!

I have gone from around 85 horrid errors, to 6 pretty simple things errors found within a javascript and I dont know how to fix the last 6 errors.

I am using the http://validator.w3.org/ and if you run the source code for the homepage through that - maybe some of you could shed some insight on how to keep the validator happy here!

Thanks very much

Andy
AndyArmstrong is offline   Reply With Quote
Old 07-18-2007, 12:03 PM   PM User | #2
ahallicks
Senior Coder

 
ahallicks's Avatar
 
Join Date: May 2006
Location: Lancaster, UK
Posts: 1,134
Thanks: 1
Thanked 57 Times in 55 Posts
ahallicks is on a distinguished road
What a mess! Your code and the page in FF2!

You may be sorting through those validation errors, but you still have a long way to go after that to tidy up your code and make everything work as it should in all browsers!

As a hint I will say that style belongs in the head section of your page between the <head> and </head>. You also have an empty <ul> that you need to get rid of. As for the javascript errors I can help you I'm afraid but you might want to consider putting the javascript and CSS into external pages and linking to them in your head?
__________________
"write it for FireFox then hack it for IE."
Quote:
Originally Posted by Mhtml View Post
Domains are like women - all the good ones are taken unless you want one from some foreign country.
Reputation is your friend

Development & SEO Tools
ahallicks is offline   Reply With Quote
Old 07-18-2007, 12:04 PM   PM User | #3
VIPStephan
The fat guy next door


 
VIPStephan's Avatar
 
Join Date: Jan 2006
Location: Halle (Saale), Germany
Posts: 7,585
Thanks: 5
Thanked 864 Times in 841 Posts
VIPStephan is a jewel in the roughVIPStephan is a jewel in the roughVIPStephan is a jewel in the rough
In X(HT)ML you need to enclose JavaScript in CDATA tags. You did it with your CSS already (probably not being aware why), and while I haven’t encountered any problem leaving those out there, they are required for JS code:
Code:
<script type="text/javascript">
// <![CDATA[
// Copyright 2003 Eddie Traversa
// http://www.dhtmlnirvana.com/
// free to use as long as this copyright notice stays intact
var tags = new Array( 'p','b');
var pixelArray =  new Array('10','12','16','20','24','30','40');
var emArray =  new Array('0.7','0.9','1.0','1.4','1.8','2.2','2.6');
var initSize = 3;

function fontSizer(inc,unit) {
	if (!document.getElementById) 
		return;
	var size = initSize;
		size += inc;
	if (size < 0 ) {
		size = 0;
}
	if (size > 6 ) {
		size = 6;
}
		initSize = size;
		getBody = document.getElementsByTagName('body')[0];
	for (i = 0 ; i < tags.length ; i++ ) {
		getallTags = getBody.getElementsByTagName(tags[i]);
	for (k = 0 ; k < getallTags.length ; k++) 
		getallTags[k].style.fontSize = (unit=='px') ? pixelArray[size]+unit: emArray[size]+unit;
	}
}
// ]]>
</script>
__________________
Don’t click this link!
VIPStephan is offline   Reply With Quote
Old 07-18-2007, 12:44 PM   PM User | #4
AndyArmstrong
Regular Coder

 
Join Date: Jun 2007
Posts: 145
Thanks: 0
Thanked 0 Times in 0 Posts
AndyArmstrong is an unknown quantity at this point
Right! Now - its finally validated XHTML - what next! Thanks so far guys!
AndyArmstrong is offline   Reply With Quote
Old 07-18-2007, 01:40 PM   PM User | #5
ahallicks
Senior Coder

 
ahallicks's Avatar
 
Join Date: May 2006
Location: Lancaster, UK
Posts: 1,134
Thanks: 1
Thanked 57 Times in 55 Posts
ahallicks is on a distinguished road
Errrmmm.... read my above post?
__________________
"write it for FireFox then hack it for IE."
Quote:
Originally Posted by Mhtml View Post
Domains are like women - all the good ones are taken unless you want one from some foreign country.
Reputation is your friend

Development & SEO Tools
ahallicks is offline   Reply With Quote
Old 07-18-2007, 02:13 PM   PM User | #6
AndyArmstrong
Regular Coder

 
Join Date: Jun 2007
Posts: 145
Thanks: 0
Thanked 0 Times in 0 Posts
AndyArmstrong is an unknown quantity at this point
I did :

Remove unusued ul - done
Styles in head - they already were
Link javascript and styles to external documents - could do but it would do nothing but tidy up the code a little bit.

What more can i do now?
AndyArmstrong is offline   Reply With Quote
Old 07-18-2007, 02:32 PM   PM User | #7
ahallicks
Senior Coder

 
ahallicks's Avatar
 
Join Date: May 2006
Location: Lancaster, UK
Posts: 1,134
Thanks: 1
Thanked 57 Times in 55 Posts
ahallicks is on a distinguished road
You could look at it in Firefox and then start trying to fix that
__________________
"write it for FireFox then hack it for IE."
Quote:
Originally Posted by Mhtml View Post
Domains are like women - all the good ones are taken unless you want one from some foreign country.
Reputation is your friend

Development & SEO Tools
ahallicks is offline   Reply With Quote
Old 07-18-2007, 03:43 PM   PM User | #8
AndyArmstrong
Regular Coder

 
Join Date: Jun 2007
Posts: 145
Thanks: 0
Thanked 0 Times in 0 Posts
AndyArmstrong is an unknown quantity at this point
haha come on now - of course I am! Thats what I am trying to do, but I genuinly dont know what needs changing!
AndyArmstrong is offline   Reply With Quote
Old 07-18-2007, 05:25 PM   PM User | #9
AndyArmstrong
Regular Coder

 
Join Date: Jun 2007
Posts: 145
Thanks: 0
Thanked 0 Times in 0 Posts
AndyArmstrong is an unknown quantity at this point
OK on ff i decreased the set of photos on the top right which should have moved that back up - but the menu is still flying in the middle of the page - WHY!!!!!!
AndyArmstrong is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 02:17 PM.


Advertisement
Log in to turn off these ads.