We like your style
Posted on 24 Apr 2006 at 12:05
Paul Ockenden looks at CSS and definition lists, while Mark Newton is forced to tailor a website with Access
It's always nice to receive emails from readers, and it's especially nice when we hear that something we've written has been of help or has had a profound influence. Paul received one such email from reader Nick Lauro:
'Thanks for your recent articles in PC Pro, where you highlighted the use of CSS in web design. As a wannabe web designer/dabbler since 1999, I struggled for not long enough with raw HTML before being introduced to Dreamweaver. Ever since then, I've wondered how so many sites manage to look so great without the use of lots of JavaScript or formatting mark-up within the source. It was only after reading your article, which also turned me onto Style Master, that the light bulb went on.
'It's changed my whole view of web-page design and given me real focus. Instead of hitting Dreamweaver and throwing in a load of tables and a few JavaScript tricks generated by Dreamweaver, I've now gone right back to school to learn the power of CSS. My use of Dreamweaver was akin to putting a huge pan of plain pasta on the stove and adding every conceivable ingredient I thought might enhance its taste, but without knowing exactly why it might make it taste better. But thanks to your article, I've discovered the real use of CSS and I'm a reformed character, learning all the time.'
Getting emails like that makes this job worthwhile. Nick goes on to recommend some tutorials and a book, and then asks a question about CSS-designed pages:
'I still use Dreamweaver to create updatable templates and also in code view, but my main weapon is Style Master and some of the excellent tutorials by Russ Weakley, which you can find at www.maxdesign.com.au. I also recommend his Sams Teach Yourself CSS in 10 Minutes book for anyone wanting to drop Dreamweaver-driven layouts for CSS.
'Just one question, do you still use tables for forms? Do you think this is possibly one of the few situations where tables are better for positioning elements than CSS?'
Well, Nick, the answer to your question is 'it depends'. Although some CSS zealots think tables are the spawn of Satan, they're usually missing one important point: tables do have a perfectly valid use, which not surprisingly is for displaying tabular data. Consider this example: if you want to display a matrix of monthly sales figures for half-a-dozen products, a table would be the perfect mark-up to use. And, likewise, if you had a form where the user could input those sales figures, a table would work well. However, for a typical website contact form, where you might ask for a name, email address, 'how did you hear about us' and so on, tables aren't necessarily the best mark-up to use.
So what are the alternatives? Well, we're going to be slightly controversial here and show an example using a definition list. Let's get the controversy out of the way first. A definition list is a listing of related items, whose two parts are the term and the definition, for example:
- Camembert
- Smelly French cheese, sometimes runny
- Stilton
- English cheese, blue
In fact, entries in the list can contain multiple terms and/or definitions:
- Grass
- The green stuff in your lawn
- To snitch on someone
- A snitch
- Herbal Cannabis
- Greenhouse
- Glasshouse
- A place to grow tomatoes
The disputes arise because some people believe definition lists should only be used for terms and definitions - things like dictionaries and encyclopedia entries - while others hold that they may be used for any list of related data. At first, you might lean toward the former view, as after all those tags are called 'definition term' and 'definition description'. However, if you take a look at the relevant W3C specs (www.w3.org), the authors state: 'Another application of DL, for example, is for marking up dialogues, with each DT naming a speaker, and each DD containing his or her words'. That's a fairly clear and unambiguous permission to use a definition list without sticking strictly to terms and their definitions. If W3C can do it, so can we.
Download a year of Paul Ockenden's Mobile & Wireless columns by heading to our Free Downloads site
From around the web
advertisement
- Why you have to be left in the dark on OS patches
- Is Microsoft mismanaging Windows on ARM?
- Dealing with spam surrogates
- Why 3G broadband can be better and cheaper than ADSL
- Is Twitter bad for business?
- Publishing your email address isn't a security disaster
- Why you'll need a fax machine to develop iOS apps
- Learning to adapt to the mobile web
- Why you shouldn't use WPS on your Wi-Fi network
- Disabled users suffer when software breaks the rules
- Laptop bag reviews: nine tested
- Sony VAIO T Series Ultrabook review: first look
- Revealed: the military standards and robots HP uses to test its laptops
- Windows 8: multi-monitors and double standards?
- Why is TalkTalk's year-old porn filter suddenly big news?
- Why are laptop screens so far behind mobiles?
- HP EliteBook Folio review: first look
- The shoebox-sized all-in-one printer
- Forget the Ultrabook: here comes the HP Sleekbook
- HP Spectre XT review: first look
- Autonomy's Lynch joins 27,000 on way out of HP
- ICO: no fines for breaking cookie rules
- HP set to slash up to 30,000 jobs
- Government sites to miss cookie deadline
- Microsoft tweaks multi-monitor support in Windows 8
- Apple patches Leopard, despite ending support last year
- Defra opens rural broadband funding applications
- BT's broadband sales surpass calls revenue
- Apple patches multiple security issues
- FBI warns travellers to beware attacks via hotel Wi-Fi
advertisement

