The web browser only knows the code that
you give it. If "it's not working", it's
only the code you gave!
So the only solution is: check your code:
If we are having a problem with a web page, our natural reaction is to want to try to fix the problem right on that page, which often ends up in frustration.
But when someone builds a house, he doesn't throw up an entire wall here and there, build half the roof, and then start building another wall. First one brick, then another brick, then another brick ...
The same principle works for building web pages (and programs)! And this is the real way that real developers (and programmers) do things.
Best thing is to start small, then add things. Don't try to do everything at once in the full page.
So if you are having some problem on a page:
Make another, simple, html page, that contains only the code for the problem. Then practice doing stuff with that problem.
Example:
If you are having trouble figuring out how to
make a div float to the right:
<div>
and a little text in it.
<div style="float: right;">
The usual problem with our html or css code is some stupid little thing that we just aren't finding with our human eyes. We can let the computer find it for us!
There are many useful tools that will check our code. Here are three of the easiest to get (and probably the best!)
Most good text editors and broswers make different colors for different parts of your code. If you see the pattern of the colors doesn't look right, you can probably see where your html went wrong.
"Validate" means let a program check your html code and make sure that all tags have endings, quotes are in right place ... all those little things that our eyes can miss. http://validator.w3.org/
Under the FireFox "Tools" menu is "Error console". It will show you any problems with your css code. (Also javascript problems. Also every problem on every web page that is loaded in your browser! So to see only *your* page problems, hit the "clear" button, and then load your problem web page again.)
This is a great extension (add-on) to FireFox that shows all kinds of things about our html and css code.
Any serious web developer in the world is using Firebug.
Without you are working with one arm tied behind your back!
Get it here:
https://addons.mozilla.org/en-US/firefox/addon/firebug/
(More useful Firefox extensions are
here.)
Check your CSS code — let this program find all the little things that cause trouble: http://jigsaw.w3.org/css-validator/
| copyright / license |
top ↑ |
|---|---|
|
Q: Can i copy this file? Can i give to other people? Answer: Sure, you can give it to anyone, according to the terms of the license below. It is copyright © 2004 James Walker. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.1 or any later version published by the Free Software Foundation; with no Invariant Sections, with no Front-Cover Texts, and with no Back-Cover Texts. A copy of the license is included here. If not found, find it at www.fsf.org - the Free Software Foundation. |
|
| translation |
top ↑ |
|---|---|
|
It would be very useful to have translations of this document in any language. Most preferred would be Tibetan and Chinese. Please contact me if you can do a translation for us. |
|
| contact |
top ↑ |
|---|---|
|
Was this helpful? Is it clear, or confusing? I would be happy to hear anything about how to make this better. You can contact me at the email address i have given you, or at http://www.webwalker.to/contact.php |
|