SitePoint Tech Times February 18th, 2004 
Issue 83 

Newsletter Archives | Advertising | Contact us  
Tips, Tricks, News and Reviews for Web Coders

In This Issue...

Introduction

Kevin
Yank I spent this past weekend performing a major upgrade of my home PC. In addition to a motherboard problem, the primary hard drive had slowed to a crawl, making even the simplest of tasks an excruciating ordeal.

The hard drive issue manifested itself so gradually that I just assumed the machine had run that slowly all along. When a clean install of Windows XP took 15 minutes to boot up, however, I knew there was something seriously wrong. A new processor, motherboard, RAM and hard drive both cured the problems and emptied my bank account very nicely.

Now that my PC isn't dead slow anymore, I can afford to run a few "non-essential" applications, like an RSS reader! In the past two weeks, we've scattered [RSS] buttons all over our site. You can now subscribe to RSS feeds and instantly be notified of new content published on SitePoint -- be it a blog entry, an article, or a forum thread!

Don't know your RSS from your elbow? Don't sweat it! SitePoint wordsmith Nathan Matias has put together a short run-down of what RSS is and how you can use it. Get Off Your RSS and read it!

Kevin Yank
techtimes@sitepoint.com
Editor, The SitePoint Tech Times

Top


Editorial

The State of XForms

Back in the Tech Times #53, I introduced XForms as the latest candidate recommendation to come out of the W3C. I explained the advantages it had over HTML forms, and even showed a simple example of how XForms work.

At the time, the media buzz surrounding XForms came from the fact that Microsoft was building something called XDocs into its upcoming Office 2003 software. Many attributed Microsoft's refusal to endorse XForms to similarities that the recommendation bore to XDocs.

Over a year later, Office 2003 has been released, XDocs is now called InfoPath, XForms has become a full-fledged W3C recommendation, and the fine folks at x-port.net have just released formsPlayer 1.0, a free plug-in for Internet Explorer that fully complies with the XForms standard.

So why aren't we seeing XForms springing up all over the Web? After all, the most popular Web browser in the world now supports them with a free plug-in!

Due to the stagnation of Internet Explorer, all the ultra-keen Web developers who would normally jump on a technology like this have moved to Mozilla (and Firefox) as their development platform of choice. To put it bluntly, no one really cares what Internet Explorer can do now, because there is so much that it can't do (like properly support CSS2).

So, the question is, what are the other browser makers doing about XForms?

Mozilla is tracking requests for XForms support and volunteers interested in working on it in bug 97806. The comments on this bug, which dates back to the days when XForms was a working draft, make interesting reading. There are many opinions on why XForms may or may not be worthy of consideration for inclusion in Mozilla, but the status quo is that it remains a relatively low-priority feature request in need of good developers, despite having nearly 500 votes from community members.

Apple (whose Safari browser has become a serious consideration for developers) and Opera issued a combined statement last September in response to XForms becoming a proposed recommendation. In it, they outlined a list of "substantial issues" in the standard that they felt made XForms inappropriate as a replacement for HTML forms. When pressed, they admitted that XForms was probably worthy as a platform for advanced forms development, as long as HTML forms remained as the mainstream choice in XHTML 2.0.

So why all this negative sentiment towards XForms? Is it really so flawed?

Like any new technology, XForms has a rough spot or two, but the productivity it offers to developers cannot be denied. Yet, while XForms itself isn't all that complex, it relies on a host of technologies that are fairly complex, and are not widely implemented in today's browsers. Quoting from Apple and Opera's statement,

"XForms has too many dependencies. In addition to XForms itself, an XForms implementation needs to support XML with namespaces, XML Schema, XPath, XML Events, DOM Events, DOM Core, CSS, a stylesheet linking technology (e.g. the XML Stylesheet PI), and a host language (e.g. XHTML or SVG). In particular, its dependency on XML Schema is of great concern to us."

The Mozilla bug discussion suggests that XML Schema support is not strictly necessary for a basic implementation of XForms, but XML Events is a definite piece of the puzzle that has yet to be built into Mozilla. Meanwhile, browsers like Opera and Safari are even further behind the curve.

From what I can tell, XForms has the dubious distinction of being one of the first implementations of a number of XML technolgies with mass appeal to Web developers. Though well thought out, none of these technologies has had a compelling reason to be built into a Web browser before, and now, all of a sudden, they would all have to be built at once in order to support XForms.

Even with a free, fully compliant plug-in for Internet Explorer, XForms has some serious hurdles to overcome before developers can consider it as a serious tool for general Web development. If you want to pitch in, I would definitely encourage you to contribute your services to the Mozilla project, but it will take some smart brains and a lot of work to bring XForms into the spotlight.

Top


Unlock the full potential of PHP with
The PHP Anthology

Photo of The PHP Anthology"PHP is a simple language - almost anyone can learn it. The trick," says veteran PHP writer Kevin Yank, "is to get a handle on all its features, so you can take full advantage of the power it places at your fingertips."

The PHP Anthology by Harry Fuecks is a complete guide to all that PHP has to offer. From the simplest database queries, to generating images and PDF documents on the fly, each feature is demonstrated with rich, practical examples that are designed for convenient reuse in your own projects.

Grab The PHP Anthology now and save 25% when you buy both volumes! Find out more!

Top


Quick Tip

Overlapping Borders in CSS

Though still problematic, due to limited formatting properties and lagging browser support, multi-column layouts have become the strived-for ideal of CSS page layout on the Web.

So, say you want a vertical line between two columns on your Website. Easy, right? You just apply a simple CSS border to the side of whichever column is tallest.

But what happens if you don't know which column will be tallest? This could vary from day to day if you publish dynamic content; it could even change depending on the width of each user's browser window. Whenever the column without the border becomes the tallest, the vertical line will stop at the bottom of the shorter column!

The solution is to put a border on both columns, then make them overlap, so they look like a single border. Here's how this might look in your CSS code:

#sidebar {
  position: absolute;
  left: 0;
  top: 0;
  width: 150px;
  border-right: 1px solid black;
}

#maincontent {
  margin-top: 0;
  margin-left: 151px;
  border-left: 1px solid black;
}

What's happening here is the sidebar column is assigned a width of 150 pixels, to which it adds a 1-pixel vertical border along its right-hand side. This border will therefore be drawn along the 151st pixel from the left-hand side of the browser window.

The maincontent column, meanwhile, is given a left-hand margin of 151 pixels, placing the left edge of its content area at the 152nd pixel from the left-hand side of the browser window. Thus, the 1-pixel vertical border that we add to its left-hand side will also be drawn along the 151st pixel from the side of the window.

The two borders overlap, and look like just a single 1-pixel border. When sidebar is taller, its border is responsible for drawing the bottom end of the shared border. When maincontent is taller, however, it draws the bottom of this border.

We used this very technique recently to make sure that the borders of the two side columns on sitepoint.com don't end prematurely when the content area is short.

Top


Help Your Friends Out

People you care about can benefit from the wealth of information on new and maturing technologies available on the Internet. Help them learn how to do it by forwarding them this issue of the SitePoint Tech Times!

Send this to a friend

Download a full four free chapters from every SitePoint Book!

The PHP Anthology
by Harry Fuecks


The Web Design Business Kit
by Brendon Sinclair


HTML Utopia: Designing Without Tables Using CSS
by Dan Shafer


Build Your Own Database Driven Website Using PHP and MySQL
by Kevin Yank

!More information about SitePoint Books

 New Technical Articles

Introduction to Coldfusion Data Structures Part IV – Queries

David
Medlock
By David Medlock

Queries are more than just the results you get from a database -- in Coldfusion, they represent a simple way to display and manipulate data. David explains how easy it is to get the most out of your Coldfusion queries in the final part of his series.

Get Off Your RSS!

Nathan
Matias
By Nathan Matias

Be organized, be informed - and stay that way! RSS lets you effectively review all content as it appears on the sites you love, and optimise the time you spend online. Nate's quick tour of RSS aggregators will have you up and running fast. So what are you waiting for? Get off your RSS!

The PHP Anthology Volume 2, Chapter 5 - Caching

Harry Fuecks
By Harry Fuecks

HTML is fastest! So says Harry, as he shows how you can take advantage of caching on both the client and server sides to reduce bandwidth usage and dramatically improve performance in this, the final in his PHP Anthology series.

Interview - James Atkinson , Founder of phpBB

Emir
Musabasic
By Emir Musabasic

phpBB is one of the most popular open source boards available. Ever wondered how the team got started? How they work together? How the product won such a strong following? Emir reveals the details in his interview with founder, James Atkinson.

Synchronize MySQL Data Using SQLyog Job Agent

Karam
Chand
By Karam Chand

What's the best and most efficient way to synchronize data between two MySQL databases? Using SQLyog Job Agent (SJA)! Karam shows us how to use SJA to your advantage in this quick-and-easy tutorial.

LinuxWorld 2004 In Review

Nathan
Matias
By Nathan Matias

Sit back, relax, and enjoy the ride, as Nate takes us on a whirlwind tour of LinuxWorld 2004. Along the way, he sees a few familiar faces, talks turkey, and takes copious notes.

 Hot, Techy Forum Threads

Manage Your Subscription Here.

!You are currently subscribed as to the HTML edition of the Tech Times.


CHANGE your email address here

UNSUBSCRIBE from the Tech Times here.

SUBSCRIBE to the Tech Times here.

SWAP to the 'Text-Only' version of the Tech Times here.


SitePoint is Hosted by
Ventures Online


Thanks for reading!

 © SitePoint 2004. All Rights Reserved.

Back to the archives

Newsletter signup

Design, coding, community or marketing? Select the right newsletters right for your needs...