Thoughtful, detailed coverage of the Mac, iPhone, and iPad, plus the best-selling Take Control ebooks.

 

 

Pick an apple! 
 
Copy Before Submitting Web Forms

Filling in Web forms (like the one used to submit this tip) can be a bit of a gamble - you put in your pearls of wisdom, perhaps only to lose them all if the Web page flakes out or the browser crashes. Instead of losing all your text, "save" it by pressing Command-A to select all and then Command-C to copy the selected text to the clipboard. Do this periodically as you type and before you click Submit, and you may "save" yourself from a lot of frustration. It takes just a second to do, and the first time you need to rely on it to paste back in lost text, you'll feel smart.

Submitted by
Larry Leveen

 

 

Related Articles

 

 

Breakfast, Dinner, Launch: A New Design

Send Article to a Friend

Our launch today of the newly designed TidBITS Web site is the result of about 15 months of work in transitioning our old architecture for writing and editing articles, assembling and publishing issues, and feeding out articles and other bits online.

Adam wrote about our back-end transition for assembling issues that are sent out via email back on 11-Sep-06 in "Behind the TidBITS Curtain." That overhaul also meant a new back-end for db.tidbits.com, the site that served as our article archive.

The move today had a few components to it. First, we revamped our Web site to be more modern without being unnecessarily so. There's a little AJAX hidden here and there - the bits of JavaScript that can talk to a server after a page has loaded to update information or provide live interaction.

That was after a silent transition a few months ago when I rewrote the entire server system developed in mid-2006 from the PHP programming language to perl; you probably didn't notice when we switched from one script to another as the results and appearance were virtually identical. While the two languages have a lot in common, I've learned quite a bit about object-oriented programming (OOP) in perl, and between mid- and late-2006 had used OOP perl to build a full-blown content-management system for TidBITS. (It's called the TidBITS Publishing System or TPS; points for getting the reference before clicking here.)

That silent changeover also moved us to a modular template format that you can pull off in PHP, but isn't how most PHP code is written. I used the HTML::Template module in perl to manage this. In this approach, everything that appears on a Web page is externalized in one or more template files, allowing a beautiful separation of programming code from appearance. This will also make it dramatically easier for us to localize TidBITS for other languages.

By splitting the HTML into a separate file, this made it easier for collaborator Jeff Carlson to work on the design without having to worry about code. He had to learn a bit about the template variables and commands, but not much. We could hand files back and forth to add new features and fix bugs.

Adam will write more about the new design and the process, but I'm incredibly tired and incredibly happy. TidBITS has been longing for years to move into the 21st century. We weren't held back by a lack of ideas, but by needing the right platform, which turned out to be one we needed to build from scratch.

 

Automatic turns almost any car into a connected car. By pairing
Automatic’s connected car adapter with iPhone apps on
Automatic’s platform, drivers are able to drive safer and smarter.
TidBITS readers get 20% off all orders at <http://automatic.com/tb>