Web Designer's Reference 416
Web Designers' Reference: An Integrated Approach to Web Design with XHTML and CSS | |
author | Graig Grannell |
pages | 389 |
publisher | Friends of ED |
rating | 8 |
reviewer | jsuda |
ISBN | 1590594304 |
summary | Comprehensive guide to standards-compliant web design |
The reasons are clear and compelling: The World Wide Web Consortium, which promulgates Web design standards, has decreed HTML as obsolete. Newer, more compliant browsers, will in time not support the older tags and code; the new standards facilitate much better use by the disabled of screen readers and non-graphic browsers. Not least, the newer code makes writing and revising code easier and more efficient, as well as more capable.
These are certainly good reasons for Web designers to move to the new code. Nevertheless, surveys show that most Web pages are not compliant and that thousands of designers continue to use deprecated code. I confess that I am one of them -- after a number of years learning and getting used to HTML, the need to learn new and more code is onerous. The inertia of habit is a factor, I'm sure.
For those Web designers like me, Mr. Grannell's book is a welcome addition to the literature because it systematically deals with the topics under discussion. In its coverage of XHTML, CSS, Javascript, and complementary coding (like PHP), it provides a nice framework guiding "old dogs" like me into standards-compliant code. Not only does it provide some historical perspectives on these codes, it compares the old with the new in regard to all of the important elements of Web design.
The author is an experienced Web designer and operates a design and writing agency. He also writes articles for a number of computer magazines.
Grannell's goals are to teach cutting-edge, efficient coding, and how to master standards-compliant XHTML 1.0 and CSS 2.1. There are a dozen chapters. He breaks down the elements of Web design into modular components so that one can focus on each element separately, like page structure, content structure, layout, navigation, text control, user feedback, and multimedia. Relevant technologies are explained in context of producing a typical Website.
If one finally decides to move forward, as many suggest, this is a very good volume by which to get your start. For new designers, this is a nice primer to learn what is expected, in an overall sense, of good, advanced Web design.
This is a well-produced book with clear writing, comprehensive approach, dozens of practical examples, and downloadable files with the code examples used in the book. The author writes in a logical sequence much like an engineer would. It is a heavy textbook-like read, only lightly sprinkled with style and personality. It should appeal primarily to novice designers, but has enough advanced information to satisfy an experienced designer who is looking for that fresh start.
And in fact, the structure of the book facilitates the "fresh-start" idea. It starts with a Web design overview, giving an experienced user's tips on what software to use to write code, what browsers to design for, how to build pages from the very top to the bottom. (XHTML, unlike HTML, requires a preliminary document-type definition (DTD) to validate. Only after the introductory section does the first HTML tag appear.)
Like others writing in this area, Grannell firmly advocates designing for standards compliance, usability, accessibility, and last and least, visual design. Marketing Department people may choke on that priority list, but there is no inherent conflict between function and aesthetics; Grannell simply does not spend a lot of time on the aesthetics.
The middle chapters concentrate on modular construction of pages -- the XHTML introduction, the structural elements like text blocks and images, the logical structure of the links and navigation flow, and finally, the stylizing with CSS. Comparisons between pages styled with HTML vs. CSS compellingly demonstrate the benefits and advantages of CSS. There will be no going back once you've decided to upgrade your technical approach.
Basic CSS concepts are explained and illustrated with code samples and screenshots. Grannell describes how to use CSS for text control, navigation, and layouts. There is a broad section on frames and another on forms and interactive components.
The last chapter covers testing and tweaking including how to create a 7-item browser test suite. Strategies overcoming browser quirks are discussed throughout the book. There is detailed technical information, especially in regard to the XHTML introductory section of the page, which I have not seen elsewhere.
There are three welcome reference appendices at the end covering XHTML tags and attributes, Web color coding, and a very comprehensive entities chart noting currencies, European characters, math symbols and more.
Much of this material is covered elsewhere in the growing set of publications about standards-compliant code. This book has the virtue of having a useful overall perspective on Web design and acts as a framework for new designers and converting designers to renew and upgrade their technical approaches.
You can purchase Web Designers' Reference: An Integrated Approach to Web Design with XHTML and CSS from bn.com. Slashdot welcomes readers' book reviews -- to see your own review here, read the book review guidelines, then visit the submission page.
Wow. (Score:2, Funny)
Standards, Schmandards.. (Score:5, Funny)
Mod parent down (Score:2, Funny)
Have you no eyes, man?
Re:Standards, Schmandards.. (Score:2)
Re:Standards, Schmandards.. (Score:2)
> > Obviously a troll. Have you no eyes, man?
> dasbinken {text-decoration: blink;}
Meesa not troll! Meesa got biggie eyes!
dasbinksen {text-makeypretty: yousathinkymediedinRevisionOfTheStandard3; }
Re:Standards, Schmandards.. (Score:5, Informative)
{
text-decoration:blink;
}
Oblig (Score:5, Funny)
Re:Oblig (Score:4, Funny)
I get this image of cooking french toast on an iron. Ooh you could fill the iron with syrup which would drizzle all over the toast when you pushed the steam button.
Sorry, I skipped lunch.
Re:Oblig (Score:3, Funny)
Web standards!!?? (Score:4, Insightful)
This begs the question: "Whose implementation does this book emphasize/teach?"
whoa daddy (Score:2, Informative)
Firefox whiffs some CSS2.1 rules [chipx86.com] among other things.
Re:Web standards!!?? (Score:4, Insightful)
Sometimes the standards are just vague enough that cases pop up where it's not clear what the rendering engine is supposed to do, or the standards don't cover every possible case, so each browser might handle those cases a little differently.
So, I guess the thing to remember is that the W3C sets down what each tag should do and how, but then the people making the browsers have to actually come up with a system that takes those tags and does those thing with them. It's just not as easy as plugging in the W3C standards and you have a web browser.
Re:Web standards!!?? (Score:5, Interesting)
The reason is because the spec is incredibly difficult to implement. Mozilla is damn close to full compliance, but the fact is that the CSS spec suffers from varying levels of vagueness when it comes time to actually sit down and implement a rendering engine.
The real problem is that it's impossible to anticipate all the ways that people might attempt to use CSS, and the gray areas can really only be standardized by browser makers after years of web development by the public at large. CSS 2 is really just starting to hit its stride now that Netscape 4 is effectively dead, but it won't be able to take another quantum leap until IE6 is dead (assuming IE7 makes good on their standards-compliancy promises).
Sadly, web design is one of the most difficult technical disciplines because browsers grew like cancer in the 90s and now the browser makers are all obligated to support all that cruft. IE has some truly mind boggling bugs that will probably have to remain because people depend on that buggy behaviour.
Ah, well, that's job security for me.
Re:Web standards!!?? (Score:3, Insightful)
Both Opera and Konqueror have implemented a lot more.
Re:Web standards!!?? (Score:2)
Hey! It uses sentences, you set up what the screen should look like in advance, and it can now even handle graphics. What more could you want?
[For the joke impaired - this is a joke!]
Re:Web standards!!?? (Score:2, Interesting)
These are all great points, and I can't wait for CSS2 to be more fully implemented and for IE6 to be replaced to allow more robust CSS2/XHTML development.
However, as broadband usage propogates, web dev products that can deliver entire web applications to the desktop/browser before the content is even seen (such as Macromedia's Flex or MS's XAML) will eventually become the tool of choice for web development because 1) they ensure "standardized" layout, and 2) the end product is much sleeker and user-friend
Re:Web standards!!?? (Score:5, Informative)
Then suprise is your meal of the day. Amaya not only failed the acid2 test [webstandards.org], but actually did much worse than even Firefox. Here's a screenshot [student.uu.se] for your amusement.
Re:Web standards!!?? (Score:2)
Yeah, I'm getting ready... (Score:4, Funny)
I setup my cron to push the site live in 2007.
Elaboration? (Score:5, Insightful)
For ANY web designer who has at least some experience with html/css, this is the single most difficult aspect of web design. That is, getting the page to work in all the popular browsers takes the most time and really has no logic to it. What I would like to see is a book that skips all the fluff that we've seen before and goes straight to browser bugs. If they can be avoided in the first pass at making a web site it makes perfecting the final presentation all that much easier.
Comment removed (Score:5, Insightful)
Re:Elaboration? (Score:5, Informative)
Absolutely. There are a million tutorials that will teach you all about CSS in theory, and once you have a reasonable base knowledge you can actually go into the W3C spec [w3.org] itself and dig into the details, but when it comes time to make your pretty new XHTML/CSS2 page work in IE you better have a boatload of knowledge.
After 5 years, and the thankful death of NS4 and IE5 (for the most part), I can debug my XHTML/CSS pages extremely efficient, but good references are still necessary. My two favorites:
CSS-discuss mailing list wiki [incutio.com]
&
Position is Everything [positioniseverything.net]
Re:Elaboration? (Score:2)
The problem is that any book that has a comprehensive list of browser bugs will be outdated by the time it hits the shelves. Firefox and Mozilla change quickly, Opera and Sefari, nearly as quickly. IE is the only thing that hasn't changed much recently, but with IE7 coming out soon, the only thing the book could cover are old and unsupported browsers anymore.
Re:Elaboration? (Score:2)
Imagine if GMail, even just in it's beta phase, had said 'Sorry, Internet Explorer does not support the features necessary to use this website. Download Firefox for free here [getfirefox.com].' Imagine what that could have done to pressure microsoft to start supporting the standards.
I really think all it's gonna take is somebody with the right application that everyb
Baby + Bathwater (Score:5, Insightful)
Newer, more compliant browsers, will in time not support the older tags and code;
Yeah that's a great idea. Lets just stop supporting a simple markup and make it impossible to view all the legacy HTML in existence. While we're at it let's force everyone to change to a newer, more complicated standard, even if they have no need for it.
Now I'm all for using CSS and XHTML, but that is because it makes things easier to maintain for me. Calling for browsers to stop supporting HTML, however, is taking it about three steps too far.
Re:Baby + Bathwater (Score:3, Interesting)
Ummm, you do realize that "not supporting" the older tags just means they'll have no effect, not that their content won't show up, right?
The variable names are shown in italic text and the keywords are in bold. Any text in red indicates a command that requires su.
Oh wait, I guess the bold, italic, and font tags don't work anymore. That will really make the document usable. You know there are literally thousands of examples like that on the internet and in documentation all around the world. Markup t
Gilding the lilly (Score:2)
Re:Gilding the lilly (Score:5, Informative)
<b> and <i> are visual tags: they make text look bold or italicised without altering the meaning of the sentence they are in. <strong> and <em> are logical tags: <strong> provides emphasis in web page readers, as well as looking bold, for example. <em> does the same, but renders differently in text browsers. There are other italic tags such as <cite> that are used for citing references, for example.
This page says it better than I do. [think-ink.net]
Re:Gilding the lilly (Score:2)
Re:Gilding the lilly (Score:2)
However, it's not solely in XHTML. The tags exist in HTML 4.
I'm personally amazed that people talk so much about the strong and em tags so much when there's a ton of nicer introductions such as label [w3schools.com] and optgroup [w3schools.com] that get little to no press.
Re:Gilding the lilly (Score:2)
The purpose of XHTML is to decouple the presentation from the information. "strong" just tells whatever is interpreting it to do whatever it thinks is best to make it stand out.
Re:Gilding the lilly (Score:2)
Part of the idea in those renamings is to increase the separation between content and presentation. In the two examples you give, changing the semantic behind the markup allows them to imply content information instead of presentation information. "b[old]" and "i[talics]" specify the appearance of a b
...so why aint people doing it? (Score:3, Insightful)
So if that is the case, then why the heck doesn't more people do it? I mean, if we assume that people learn to code webpages from books, why do they buy the old shitty books and code their pages with godawful font-tags and something that closely resembles MS-Word-HTML?
With that said, XHTML and CSS is love.
Web standards are stupid. (Score:4, Insightful)
Re:Web standards are stupid. (Score:2, Informative)
If the developers of Netscape Navigator had this fanatical devotion to the W3C that seems to be popular lately, we wouldn't have tables, scripts, or any kind of styles (neither nor CSS). None of that was in the standard (HTML 2.0) at the time.
Bzzt, wrong. Tables were proposed as part of HTML 3.0 [w3.org] which was being worked on at the time. HTML 2.0 already had a way of incorporating stylesheets into documents [w3.org], and in fact it's the same code that is used today.
Even if that wasn't true, Netscape had nothi
XHTML is a bad solution (Score:5, Interesting)
I coordially invite someone to give me one reason why XHTML (in its current form, served as text/html or text/xml) is better than HTML 4.0 strict? Is closing my link and meta tags really that life-changing?
Re:XHTML is a bad solution (Score:5, Informative)
The main is that XHTML really FORCES you (if you want your page to pass W3C validation) to seperate design from content in a way that facilitates the ease of updating pages.
A side effect of this is smaller filesizes. A recent conversion from HTML to XHTML+CSS for a client of mine brought their homepage size down from 25k to 9k. This to me is reason enough to use XHTML+CSS.
A side effect of this is better code/content ratio.... a side effect of this is better search engine placement.... a side effect of this is...
So using XHTML over HTML actually has a cascading (mind the pun) list of benefits, completely independant of the technical mumbo-jumbo of the whole "XHTML is supposed to be XML" stuff.
Re:XHTML is a bad solution (Score:2)
Which is more readable?
--
This is a paragraph.<p>
<img src = "foo.jpg" height = 20 width = 30>
This is another paragraph.<p>
--- or ---
<p>This is a paragraph.</p>
<img src = "foo.jpg" height = "20" width = "30"
<p>This is another paragraph.</p>
---end---
This kind of issue is why I have resisted changing to the likes of XHTML. I want my code to be easy to read instead of m
Re:XHTML is a bad solution (Score:4, Insightful)
The thing is, your example is really moot anyway when it comes to HTML vs. XHTML. Your second example is perfectly valid HTML (except for the closing slash on the image tag), and I was closing my paragraph tags for years before I'd even heard of XHTML because of the reasons I've already mentioned.
Re:XHTML is a bad solution (Score:5, Insightful)
The only thing that XHTML forces you to do is stop using the font tag. That's pretty much it. Everything XHTML can do HTML 4 does and does it better (cuz existing UAs grok its mimetype).
The real promise of XHTML is the same as XML: being able to mix and match namespaces into a super-document. However, no user agents (except for some special builds of Mozilla) really accept embedded XML dialects (for an example, see SVG+XHTML on Mozilla's SVG site). This is changing in Firefox 1.1, but it won't have any real effect on the marketplace until the majority of user agents support it.
Short version: XHTML disables the use of the FONT tag and some attributes that should be done in CSS anyway.
Re:XHTML is a bad solution (Score:2)
That's because you've given us an example of a font attribute, not a font tag. Duh.
Re:XHTML is a bad solution (Score:4, Informative)
The only real differences between XHTML and the non-X versions of HTML that came before it are:
1. DTD declarations are mandatory. Or if not mandatory, strongly encouraged. Sort of.
2. Case is no longer insensitive, except usually implementations of it still are.
3. Non-pairing tags have to close themselves with a trailing slash.
4. Attributes have to take the form of name/value pairs.
5. There's a bunch of tags that are deprecated, but you can still use them because no browser authors will ever remove support for them or even refuse to render a page if it doesn't validate against the DTD.
Re:XHTML is a bad solution (Score:2, Informative)
The main is that XHTML really FORCES you (if you want your page to pass W3C validation) to seperate design from content in a way that facilitates the ease of updating pages.
This is not true. XHTML includes things like the <font> element type. Mod parent -1, Clueless.
A recent conversion from HTML to XHTML+CSS for a client of mine brought their homepage size down from 25k to 9k. This to me is reason enough to use XHTML+CSS.
You could have got the exact same saving if you had moved from HTML t
Re:XHTML is a bad solution (Score:3, Insightful)
The proliferation of XML allows everyone to create tag sets to meet their needs - from Scalable Vector Graphics to Chemistry Markup Language.
With this evolution, the browser becomes more of a host for a set of plugins glued together through XHTML.
XHTML, being a dialect of XML, allows you to create compound documents combining elements from multiple XML namespaces into a single document.
Re:XHTML is a bad solution (Score:3, Interesting)
However, XHTML (in it's current form) totally breaks namespaces, since the mimetype of the document is text/html and the user agent only expects (or rather, should only expect) to be receiving text/html content (instead of a mish-mash of XML dialects).
I think namespaces are most useful (and powerful) in more controlled environm
Re:XHTML is a bad solution (Score:3, Insightful)
Since you asked, here's a reason off the top of my head: As an XML application, XHTML requires you to have a well-formed document. That's good for me because later on, i can work with it.
If I need a PDF of a 4 year old document that is written in half-assed, abused, non well-formed HTML It's going to be very difficult for me to parse it into something useful.
Here's another reason: try main
Re:XHTML is a bad solution (Score:2)
Purists always like to trot out this argument, because of course it's true that IE pretty much guarantees you won't be able to send the proper mime type for a long long time to come.
But come on, foregoing XHTML syntax because of this minor issue (which will be easily fixable for all your legacy documents 10 or 15 years from now) is pretty much cutting off your
Re:XHTML is a bad solution (Score:2)
I'm not quite sure I understand your point about better code support in the future though, would you expound on that? Do you mean that this is the area where people are actively developing, so there will be better tools in the
Re:XHTML is a bad solution (Score:2)
Suppose your page had this here mystery tag in it:
<foo>
What should the browser do? Should it do something and leave it at that (like <br>) or do something and enclose all the rest of the page in a <foo> block then try to sort out the rest of the page when it thinks the tags
Re:XHTML is a bad solution (Score:2)
Using
The main advantage I see is not the
Re:XHTML is a bad solution (Score:2)
Re:XHTML is a bad solution (Score:2)
However, I did come across this little beauty [annevankesteren.nl] that gives me a little hope. It seems you can indeed serve xhtml as application/xml in IE and make it work (of course, with a small workaround).
Soon of course, lynx will have to be updated in order to keep up with the times
W3C trying to make me PC *rolls eyes* (Score:2, Interesting)
No
Jakob Nielson and the gang have pushed us to really boring text based browsing that is a chore to read, and not worth a casual flipping. Why should *I* care if my website is Modem/text based browsing compliant? Sure if I had a research website I can see the point, but my website is a video hosting portal http://videos.streetfire.net/ [streetfire.net] [streetfire.net] so I doubt the 40
Re:W3C trying to make me PC *rolls eyes* (Score:2)
Pre-excuse: I'm not entirely sober right now...
HTML 3? [w3.org] - 330 errors. Nearly as bad as /. ;)
Personally I will be glad when dinosaurs like yourself finally become extinct - sure i'm just some young 'whippersnapper' compared to you, i've only been doing website development since 1998 but I have adopted my practices as the nature of the web has changed, both for the benefit of low-bandwidth users, disabled users and such as well as for myself. Doing all styling with a CSS file makes my life an order of mangi
Re:W3C trying to make me PC *rolls eyes* (Score:2)
Replying to myself because I forgot to mention one very important benefit: Being able to target stylesheets to specific devices is wonderful - all of my sites look as good (although differnet) in handheld browsers, when people print out my pages they get a clean copy with few or no colours, no superlous navigation etc etc.
That's great if your site is only visited by geeks (Score:3, Insightful)
If people keep using HTML, browers will continue to support it. Designing for standards compliance is great, but a crappy website that loads on any standards compiant browser is a lot less useful than a beautiful, usable website that loads on the major brosers like Firefox, IE, Opera and Safari.
Ever heard someone complain about an ugly website that's hard to navigate? we've all done it.
Ever heard anyone complain that standard HTML didn't look the same on all broswers? Not too often I bet.
And standards compliance is great, but with 1) IE having a 90% market share, and 2) IE not being standards compliant, doesn't that mean that most internet users aren't using a standards compliant browser?
plain HTML has to go ! (Score:5, Insightful)
I lived by those rules not long ago; tableless design, css driven, no client side javascript events in the html (but put there by an initialization function), classnames never revealing structure information, separating structure classes with lay-out classes in different css, xhtml 1.1, etc.
Where did it get me? Not sure but sticking to all those rules sure costed me much more time then needed. And what for, because browers require that a page validates in a few years? Forget it, not in a decade, not in two.
Advice, stick to clean html that makes sense, think of your customers, think of your bandwith and don't let that w3c run your web development.
Re:plain HTML has to go ! (Score:2, Informative)
1. CSS based designs use less bandwidth, because stylesheets are cashed.
2. Think of yuo customer's customers. Specifically, those using browsers other than ie, those on cell phones, those who are using screen readers etc.
Re:plain HTML has to go ! (Score:4, Insightful)
Example: try vertically aligning elements using CSS. The vertical-align tag is only valid in something rendered as a table cell. Firefox allows display: table-cell;, IE doesn't.
If you want something vertically aligned, don't use CSS. Use a table. I would *love* to stop using tables for anything but tabulated content, but CSS Positioning requires far too many awful hacks when you start talking complicated designs. Tables are simple and well-supported by most mainstream browsers.
This was just one example; there are others. Try creating a footer at the bottom of your page. (bottom: 0px; does not work on all browsers reliably).
I *like* the concept of CSS. But it's just not all together yet.
Re:plain HTML has to go ! (Score:2, Informative)
And the reason is, is because it's the only way that they can make their web sites look good on all browsers.
Re:plain HTML has to go ! (Score:3, Insightful)
Re:plain HTML has to go ! (Score:2)
Another recommendation for beginner's.. (Score:4, Interesting)
Old? (Score:4, Insightful)
XHTML 1.0 became a W3C Recommendation on 26 January 2000, meaning it has been around almost as long now as HTML was when it came out! (Well, at least, almost as long as HTML had been in popular use when XHTML came out).
The only excuse for not using XHTML today is laziness and ineducation on the part of designers and those educating them. The same reasons most web sites don't validate as proper HTML. Sadly, "just good enough" is the rule of the day.
Absurd. (Score:3, Insightful)
Like 90% of the pages out there don't need it.
99.99% of mine don't. All I need is my trusty hammer and screwdriver, and you're trying to insist I use a fully automatic, 50 calibre nailgun and a 3HP power drill with screwdriver attachment.
irony... (Score:2)
Re:irony... (Score:2)
Posting on eBay (Score:3, Insightful)
I did a page layout on eBay [ebay.com] for an older retired friend who makes wooden toys. I used the normal .css file and div tags -- it looked like crap and was unusable. I had to go back to the drawing board and use tables! (Tables, nested in tables to get the same layout)
Most of the internet might be ready for bleeding edge stuff, but don't toss away your plain 'ole vanilla flavored HTML just yet.
Newt-dog
They'll get my bold tag... (Score:5, Insightful)
That said:
Garbage. The amount of code necessary to support basic HTML is so tiny amidst the vast beasts major broswers have become that there's no reason to dispense with it. And why use anything else when straight, primative HTML is still the most effective tool for conveying simple information?Crow T. Trollbot
Websites? (Score:2)
I've looked around a bit for this, for a browser neutral site and not something riddled with stuff related to IE extensions.
Is W3Schools among the most thorough? It's at least one spanning several web technologies, but not so sure about the depth of it...
I find it hard to just search for these things on Google as then you're greeted with d
is anyone moving to xhtml? (Score:3, Funny)
Just curious, after reading the fine article, then doing a little research and reading a couple chapters of the w3c documents I wonder that anyone would change to xhtml for the sake of canonical righteousness.
Seems to me there are reasons to do xhtml... I DO like the idea of well formed objects, especially things like web pages... at least if it's well formed you've eliminated one source of nasty little bugs creeping into sites, especially sites creating pages dynamically.
But, for sites already rolled out and wrung out in public forums this seems prissy. And problematic. Consider:
I've done an informal look-around, and found some popular and quite famous (hmmmm, a particular site [slashdot.org] comes to mind...
So, academically maybe a good direction to consider, but the predictions of html going away to be supplanted by xhtml is premature, and I predict something that in our internet lifetimes will never happen.
HTML or XHTML? (Score:4, Insightful)
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dt
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US" lang="en-US">
<head profile="http://www.w3.org/2000/08/w3c-synd/#">
versus:
<html lang="en-US">
<head>
HTML4 + CSS (Score:3, Interesting)
Re:How to Suck in 21 days! (Score:4, Informative)
You obviously have no experience with CSS. In comparison with more modern markup, coding and styling plain old HTML is like making spaghetti _one_ noodle at a time.
Re:How to Suck in 21 days! (Score:4, Insightful)
Just a comment as someone who is a "content manager" ie the poor person who has to put the words onto the web designers pages.
Using a database to feed a web site makes things so much easier. Global updates, automatic sorting and reusable elements in other parts of the web. Just because something does not make sense to a coder does not meant it is useless to mere mortals.
>>> all the complicated PHP scripts and ASP pages serving as frontends to database of choice, to serve up what's essentially static information.
Re:How to Suck in 21 days! (Score:5, Interesting)
Now people will argue that a server is not scalable either, but you can always have 5000 servers serving up that same static data. You really can't expect 5000 servers to access a single database and expect the database to survive.
Databases are needed for some webpages, but don't throw them in as a simple shortcut.
Re:How to Suck in 21 days! (Score:5, Informative)
Re:How to Suck in 21 days! (Score:4, Insightful)
Of course other people may argue that the solution would be to take those 5000 servers and divide them up: run a database service across a few hundred of them, have a few thousand web servers that do the real request processing and then let the rest of the machines be web-facing machines that cache the results for a few seconds to decrease load on the real webservers.
Re:How to Suck in 21 days! (Score:5, Informative)
It's also unlikely that one could find a database server that can cache the results of identical queries when the data hasn't changed [mysql.com], significantly speeding up access to nearly-static data.
It's downright insane to consider using proper cache-control [linuxdevcenter.com] headers and a caching [apache.org] proxy [squid-cache.org] in front of a web server farm.
It's sure too bad that these solutions can't be solved by merely hiring a competent sysadmin [cloudmaster.com] who's willing to relocate, 'cause that's be far too convenient.
It'd probably be easier to teach everyone in the company good HTML.
Re:How to Suck in 21 days! (Score:5, Interesting)
In my experience (YMMV) it is far, far easier to create an infrastructure capable of doing everything you want and to serve content dynamically within that infrastructure, than it is to edit more than a very few pages by hand. Now there is a good argument for serving static (cached) versions of dynamically created files where this is possible, and a lot of sites do just that.
There is a lot to that. (Score:5, Insightful)
Having said that, using PHP and other dynamic mechanisms to "code around" browser bugs, by implanting "patched" tags or using alternative mechanisms where something is seriously broken, is definitely the most practical solution.
You can use Apache SSI's to detect the browser and then #include the appropriate page, but that is extremely expensive on maintenance. It is much more practical to embed markers wherever you might need to deviate from the "correct" HTML and simply use a script to search & replace.
For those pages that genuinely do have dynamic content, you can have a background engine generate static pages every so often, which you then serve, avoiding a continuous rebuild. However, you run the risk of race conditions, where you try to serve a page that is part-way through a rebuild. The result will be the display of a broken page, which is definitely a Bad Idea.
Really, the "correct" design is to use a mix of approaches. Use static methods for static content, use dynamic methods for dynamic content, use pre-built pages where downloads are more frequent than updates. Hammers are great for nails, but you wouldn't use them in place of a saw or a screwdriver.
Re:There is a lot to that. (Score:3, Informative)
Already solved the race condition... At my last company, we generated about 20-25 webpages that took over 35 seconds a piece to generate. These accessed a heavily taxed DB server and was processing around a million rows. Simply generate the code to a temp file. Once finished move the temp file in place of the old file. The time it takes to move the file is extremely quick and should(under
Re:There is a lot to that. (Score:3, Informative)
And on a UNIX server, replacing a file in this manner is an atomic operation, so no one should ever end up with a broken page due to a race condition.
Re:There is a lot to that. (Score:2)
Yes, and that is why any dynamic website with moire than about 10 visitors per day needs a server-side caching mechanism.
That way, the first person to request a page with dynamic content that never changes gets it pulled fresh from the database. Then for the next hour, the other 99 people get an essentially-flat-HTML version, served from cache.
squid would most likely be the Slash-bot's package of choice, but there are plenty of the
Re:How to Suck in 21 days! (Score:5, Informative)
On local development server:
- Create database to store data
- Create scripts to make the pages
- Create
Then I use wget to save a static version of the website, then upload the static version to my webserver. Some advantages:
- Less resources needed on server
- HTML template easily changed if required
- Extremely fast script development time, since there are no security checks required
- More secure than PHP scripts on a server could ever be
Obviously this method won't work for websites that require user input (like polls), but I think not having to worry about the security of live scripts is awesome.
Re:How to Suck in 21 days! (Score:2)
XHTML+CSS tends to be way easier than a morass of HTML tables and font tags.
what could be easier than:
BEGINNING OF BLOCK
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dt d ">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en
Re:How to Suck in 21 days! (Score:2)
The book is about xhtml and css. It has ABSOLUTELY NOTHING to do with databases or server-side programming.
God, honestly.
Re:How to Suck in 21 days! (Score:5, Insightful)
Are you forgetting the NS4/IE incompatibilities and proprietary tags that plague the web to this day?
The fact is, when W3C came along, the web was seriously broken. Those of us that are so outspoken on standards are generally those that have been on the web long enough to remember how broken it was when non-standard HTML ruled the day.
Re:How to Suck in 21 days! (Score:4, Informative)
You can use a drinking-well as a urinal, but that doesn't make it a good idea. And it certainly doesn't mean you'll get anything worth having out of it later.
The fact that HTML (and browsers) allowed such horrible, buggy, quirky markup has done more to retard content aggregation and the further development of the web than practically any other force in computing.
Sure, in the early days it made sense to keep the barrier to entry low, to get people on-board. It fuelled the growth of the web, and allowed any idiot with five minutes and Frontpage to put up a page announcing to the world what a L33T h4xx0R they were in bright clashing colours on an unreadable patterned background.
This is akin to offering people a blank sheet of paper instead of a form with distinct questions and answer-boxes - useful, because they can write whatever they want and don't have to think about it, but much, much harder to do anything with later.
There's a reason we have paper forms, and a reason all non-trivial data is stored in some form of database[1] - unstructured information is useless. It only becomes useful when it's structured - when it stops being just information and becomes data [google.com]
Why is XML/RSS/ATOM more tightly-structured than HTML? Why can't we straight aggregate HTML instead of having to invent a new file format? Because HTML is now fundamentally broken for automatic syntactic parsing of data.
"Then along comes the W3C to proclaim to those practicing this craft: "HTML is not a format and layout language"."
It isn't. Or, at least, wasn't intended to be - HTML was originally envisioned by Tim Berners-Lee as a semantic markup language - it's only later development and the commercialisation of the web that lead to it being almost exclusively presentational. A new effort (the Semantic Web) is now being made on this front - old, broken, misused HTML is being retired in favour of semantic XHTML, CSS for presentation, javascript/ECMAScript for interactive behaviour and XML for interoperability/data representation. All open languages and standards, you'll note.
"They then proceed to break all the existing code that's out there in the name of that proclamation."
What's broken? Show me a mainstream browser that doesn't passably support all the way back to HTML 1.0. Sure, it entails some extra work for the browser manufacturers, but I find it hard to feel bad for them, since they (with lax enforcement of HTML grammar, proprietary extensions and the like) contributed so hugely to the mess in the first place.
"It may be coincidence that the W3C is filled with representatives of companies who make billions of dollars selling what are essentially formatting and layout platforms for forms and documents... "
Oh please - this is the worst tinfoil hat argument I've ever heard. Oooh, oooh, the companies who benefit from breaking interoperability, introducing proprietary extensions and generally grabbing the fast buck are pushing more interoperability, stricter standardisation and long-term game-plans that drastically improve the entire architecture of the net. Sorry - not following you on that one.
If it was really an industry cartel dictating the future of the web for their own ends, XHTML would have been replaced with an unreadable binary format, with unlimited proprietary vendor- and platform-specific extensions. It would be incredibly difficult to learn, rather than basically identical to HTML but ever-so-slightly stricter. They certainly wouldn't be publishing and pushing the standards for free - they'd be charging for them, attaching licence conditions to them. And they wouldn't be providing on-line validators for free - you'd be expected
what is sufficient? Is html sufficient? (Score:2, Informative)
Personally I think HTML is beautifully simple. My own site uses vanilla grade HTML,a little JavaScript and some basic CSS. That is sufficient. I'm not running an online storefront or something. I have shown extremely computer illiterate people to write their own HTML pages - and one is running 4 busineses from his own website now for 7 years, with no more handholding from me.
All this PHP, ASP, Today's 3-letter buzzword is mostly HYPE, so "web developers" can stay aloof and whine for more $$ every budge
Re:Hehehe (Score:2)
Well, maybe not. But I'll be damned if I'll switch from <B> to <strong>. Why store and transmit all those extra characters? It's just silly.
Re:Hehehe (Score:2)
No, it'll be from <b> to <span style="font-weight: bold;"></span>
Re:Hehehe (Score:2)
In a seperate doc, the browser will cache it, and save you from having to transmit all 3 or 4k each successive page you load.
Think of the children!
Re:Hehehe (Score:2)
lol I know better. Sometimes... When I'm not lazy.
Re:Hehehe (Score:2)
I still see about 1-2% Netscape v2/3 visiting some of the sites I host for my customers. Pretty amazing.
Re:Hehehe (Score:2)
Re:What's the need? (Score:5, Interesting)
Since XHTML is just a reformulation of HTML 4.01 into XML, and XHTML 1.1 is just a modularization of XHTML, technically nothhing is wrong with HTML as it exists today. But what about how it exiists tomorrow?
XHTML allows for the easy expansion of the language. Right now, DOCTYPES are the only way to define what version of HTML you're using, which makes it an all or nothing proposition. What if you want to use HTML + SUPERCOOLHTML-Extended? XHTML 1.1 allows you to basically define your own syntax, and more importantly allow the standards body to do so easily).
This way you only have to use as much of the standard as you want to, and if there are two competing standards you can actually choose which one (or ones) to use in a way that the browsers can understand.
Now, i'll grant you that for the typical "my cat fluffy" site, they don't give a rip. HTML 4.01 is just fine. But did you know that HTML 4.01 strict doesn't have font tags? It doesn't have the target attribute on links. It doesn't have a lot of stuff you're used to that are going away.
It's best to get used to XHTML now, HTML won't be improved, but XHTML will.
Re:HTML Hasn't needed improvment since CSS (Score:2)
In effect, the needs are driven by the software they are using, which means the needs are driven by the browser vendor of the software the site visitors are using.
Thus, if the site visitor's software is following the "advancing standard" then so does the visitors need. Since all the major browsers (hopefully including IE) are moving in that direction then so will end users as they upgrade.
Re:Three words: (Score:2)
Truth is, I think CSS is limited still. Give me better selectors like the CSS3 spec and that'll catch my attention. Until then, XHTML strict I'm not interested in...
Re:Three words: (Score:2)
Selectors like "input[type=password]:hover"? There are lots of wonderful ways we as designers could use the complex CSS selectors specified in the CSS 2.1 spec if only a certain browser made by Microsoft supported them...
Also you can use all the goodness of CSS1, 2.1 and 3 with HTML 4.01 so there's still no need for you to switch to XHTML :)