lesser-equity

Magazine
Go Back   Computer Juice > Computer Software > Web Design, Hosting & SEO

Register


Default Help with bad code :(

I'm new to this whole scene and wondered if anyone could help with quite a few errors I now have in my code. Thanks http://validator.w3.org/check?uri=ww...Inline&group=0...


Reply
 
Thread Tools
  #1  
Old 3rd Apr 2008, 13:20
Member Group
 
Posts: 30
Default Help with bad code :(

I'm new to this whole scene and wondered if anyone could help with quite a few errors I now have in my code. Thanks

http://validator.w3.org/check?uri=ww...Inline&group=0
  #2  
Old 4th Apr 2008, 02:22
Donor Group
 
Skill Level: Advanced
Posts: 1,271
Default Help with bad code :(

Quote:
Originally Posted by Breaker3D View Post
I'm new to this whole scene and wondered if anyone could help with quite a few errors I now have in my code. Thanks

http://validator.w3.org/check?uri=ww...Inline&group=0


All this means is that the attributes you are using do not exist in XHTML (Strict).

For instance if you said:

Quote:
<img roadsurface="asphalt" />
in HTML then the element img does not define an attribute roadsurface.


In general, you need a copy of the XHTML strict spec, which you can get from http://www.w3.org/ and then just keep to it! If you want to be lax, don't use the strict version. Use transitional instead. If that doesn't solve the problem, you are using tags and attributes that have been invented by morons at Microsoft or the former Netscape, which only work in their own browsers. An example is
Quote:
<font>
, which appears in no standard for anything! use
Quote:
style="..."
instead or a stylesheet and a class.

As for the rest, tags must be nested correctly, so

Quote:
<a><b> <c/><b><a>
is ok, but

Quote:
<a><b><c></a></d></b>
is certainly not!
__________________
I think I am a signature, therefore I exist!
I believe a higher being has me as a signature...

  #3  
Old 6th Apr 2008, 05:32
Member Group
 
Posts: 30
Default Help with bad code :(

Right then, still a bit confused. There's something wrong with it because it's not displaying correctly in dreamweaver, which is making it quite hard to edit my site. I get this error on screen which says: </div> invalid markup. Thanks for the help.
  #4  
Old 6th Apr 2008, 10:09
Donor Group
 
Skill Level: Beginner
Posts: 722
Default Help with bad code :(

I can get it clean.

I changed the header to html4.01 transitional

I replaced all the space slash > with >

I removed all the </input>

There's two <form statements, I took out the GET

There's two </form>s and I took out the first of them

I dropped a border="0" from alt="PayPal - The safer, easier way to pay online."

The edited validated version is at http://cb6.dyndns.org/techportal.html but I'm not suggesting you use it, just that it's clean so you can compare it back. I've no dea whether it works the way you intend it to.
__________________

My System: Tim

Processor(s):
Athlon 64 3500+
Motherboard:
Asus A8N-VM CSM
RAM Memory:
Corsair PC3200 CL2 DDR-400 2GB
Graphics Card(s):
nVidia Geforce 6600 512MB
Sound Card:
Cherry RS 6000 M keyboard
Hard Drive(s):
Barracuda.7+ 2x200GB 58MB/s sustain
Optical Drive(s):
Samsung DVD-ROM TS-H352
Case / PSU:
Thermaltake Soprano
Cooling:
Stock
Network / Internet:
Telewest 2x20Mb/sec
Monitor(s):
SXGA flat panel
Operating System(s):
Slackware (2.6.27.7) (Fluxbox)
  #5  
Old 6th Apr 2008, 12:41
Member Group
 
Posts: 30
Default Help with bad code :(

Wow that's great. Works superbly, not getting any errors in dreamweaver, looks very clean. Think I will most definately use this. Thanks alot for the help :)
  #6  
Old 7th Apr 2008, 00:40
Donor Group
 
Skill Level: Advanced
Posts: 1,271
Default Help with bad code :(

Quote:
Originally Posted by Breaker3D View Post
Wow that's great. Works superbly, not getting any errors in dreamweaver, looks very clean. Think I will most definately use this. Thanks alot for the help :)
Don't feel too confident though, as Dreamweaver sometimes introduces errors like this into the html!
__________________
I think I am a signature, therefore I exist!
I believe a higher being has me as a signature...

  #7  
Old 7th Apr 2008, 01:14
Donor Group
 
Skill Level: Beginner
Posts: 722
Default Help with bad code :(

I just went to download Dreamweaver since it's cropped up twice this week. It costs $400 to register an online copy! What on earth is it, the world's first Artificial Intelligence? It's an odd thing to buy, it strikes me. It sits between the user and his website and mediates what the user wants to achieve, to the extent that one has to learn the Dreamweaver package in order to generate a website. I'd have thought it would be both easier and more satisfying to learn the component web languages.

I'm sure I've got the wrong end of the stick, if someone can explain why Dreamweaver is a benefit I'd be grateful. I'm sure it's faster to implement a website than writing a one from scratch but nobody ever does that whatever approach they take to building one, everybody re-uses existing code. I used to get annoyed at Frontpage too. I even met someone once who saved some pages from Word as HTML and then asked me how to add things to it!
  #8  
Old 7th Apr 2008, 04:46
Member Group
 
Posts: 30
Default Help with bad code :(

Well in my case dreamweaver is good because I just wanted a simple site which I could upload easily but the software provided by the host was terrible and didn't work at all.
  #9  
Old 8th Apr 2008, 01:21
Donor Group
 
Skill Level: Advanced
Posts: 1,271
Default Help with bad code :(

Quote:
Originally Posted by spot View Post
I just went to download Dreamweaver since it's cropped up twice this week. It costs $400 to register an online copy! What on earth is it, the world's first Artificial Intelligence? It's an odd thing to buy, it strikes me. It sits between the user and his website and mediates what the user wants to achieve, to the extent that one has to learn the Dreamweaver package in order to generate a website. I'd have thought it would be both easier and more satisfying to learn the component web languages.

I'm sure I've got the wrong end of the stick, if someone can explain why Dreamweaver is a benefit I'd be grateful. I'm sure it's faster to implement a website than writing a one from scratch but nobody ever does that whatever approach they take to building one, everybody re-uses existing code. I used to get annoyed at Frontpage too. I even met someone once who saved some pages from Word as HTML and then asked me how to add things to it!
Spot is spot on! If you want to use a gui rather than a text editor, download KompoZer.

Don't expect standards-compliant code from commercial packages. HTML-tidy is worth investigating.
__________________
I think I am a signature, therefore I exist!
I believe a higher being has me as a signature...

Reply

Donate

Register

Bookmarks

Similar Threads
Thread Thread Starter Forum Replies Last Post
Finding a Servers Warranty Code (asset Code) aresnalfc General Hardware Chat 0 20th Aug 2009 02:55
Strange code!!!!!!!!!!!!!!!!!!!!!!1 bradleyjoes Digital Imaging & Printers 1 7th Dec 2008 12:50
Code 10 lynne9999 Sound, Speakers & MP3 Players 7 30th Jan 2008 22:07
WEP Code. ComputerGuy Networking, Modems & VoIP 4 20th Jan 2008 16:59
Myspace TM Code book2cool Web Design, Hosting & SEO 5 20th Mar 2007 06:15
Thread Tools




Arabic Bulgarian Chinese (Simplified) Chinese (Traditional) Croatian Czech Danish Dutch English Finnish French German Greek Hebrew Hungarian Italian Japanese Korean Latvian Lithuanian Norwegian Polish Portuguese Romanian Russian Serbian Slovak Spanish Swedish Thai Turkish Ukrainian

Copyright ©2006 - 2009 Computer Juice.

Powered by vBulletin® Copyright ©2000 - 2009 Jelsoft Enterprises Ltd. SEO by vBSEO ©2009, Crawlability, Inc.