Computing index HTML GUIDE
CODING STYLE

TOC


SOME HINTS ON CREATING GOOD CODE

You don't need vast experience to write good code.
Indeed, the main cause of bad code is that authors have too much experience in writing in a bad style.

Good code just requires a bit common sense and a fair amount of patience.
As a result you'll probably think the tips on this page are blatantly obvious - but you'd be surprised at how many people ignore them or just can't be bothered.


Code Layout

In any computer language the code you write must achieve two purposes.
Obviously, the program must work, but more important than this, it must be well presented.
I know this sounds a bit back-to-front, but programs are modified more often than they are written. If the code is badly laid out, it can take hours to understand and alter.

So how can you make it easy for yourself in the future when it comes to modifying your pages?



The main point when writing code is to know what you want and how you're going to achieve it.


Page Layout

Obviously, it's not my place to tell you how to structure your page, but don't fall into the trap of thinking that everyone else has your computer using your browser and your options setup.

UNIX, Mac & PC machines, aswel as the type of browser, all spurn peculiarities in the way pages are shown on screen. Although the basic layout of the page will remain true, often text on PCs is larger than on UNIX, which can cause alignment problems.



Try to view your page with as many different options, browsers (and even computers) as you can.
It doesn't matter how you see your page, but how it appears to other people.




[ Index Page | HTML Guide | JavaScript | Free Images | My Scripts | Resources Links ]

©1998 Stephen Battey
This page hosted by Get your own free home page