Skip to content

Instantly share code, notes, and snippets.

@simonw
Last active September 8, 2023 19:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save simonw/6b76f8780bcbb8f6ad7b8c9f0dce5392 to your computer and use it in GitHub Desktop.
Save simonw/6b76f8780bcbb8f6ad7b8c9f0dce5392 to your computer and use it in GitHub Desktop.
We can't make this file beautiful and searchable because it's too large.
new_id,clean_paragraph
1-0,passage: The Web Standards project has launched Phase II.
2-0,"passage: Blogging isn't nearly as easy as it looks. After several days hacking around in PHP (I'm far too proud to use an off the shelf solution) I find myself confronted with a blank slate, and writers block has taken hold. The toughest thing is working out what style to use in blog entries - my previous writing for the web has been primarily on forums (where posts do not have to stand on their own) or news sites where a formal, unopinionated tone is required. A blog should be informal but informative, with each post hopefully adding a new angle to the topic in hand. I'm sure it will get easier as I go along..."
4-0,"passage: Netscape 4 hit 5 years old yesterday. Scott Andrew celebrated this monumental occasion with a poetic tombstone tribute, entitled ""1997 - 2002"". The challenge now is to make this dream a reality - NS4 still has a stronghold in many corporate and institutional IT departments, as Zeldman bemoans in the first ""opinion"" of the new Web Standards project. An opinion that is notable in its absence of a permalink ;)"
5-0,"passage: One useful resource that did come out of the discussion was a link to Matthew Haughey's excellent tutorial on writing effective mailing list emails, which pays particular attention to the best way of quoting other posts."
5-1,"passage: The Webdesign-L mailing list is ablaze with a huge, rambling, flamey thread about the relaunched Web Standards project. As with so many flames it has become quite difficut to work out what is being argued over and why (an issue compounded by the emergence of sub threads on everything from US law to how to upset a Canadian). I would provide links, but the list does not maintain a web accessible archive."
5-2,"passage: I've been running my own campaign for web standards over on the WPWM forums with relatively unimpressive results.
This advocacy thing is harder than it looks."
5-3,passage: Steven Champeon of WaSP has been using the thread to set a few things straight. A major point of confusion that has been resolved is that web standards does NOT mean CSS layouts. To quote Steven:
5-4,"passage: What I'm wondering is this: when did the WaSP ever say anything about
tableless sites? I've been part of the group since the beginning, and
I don't *ever* recall us making any noise about tables. Some /members/
of the group, myself included, have certainly done so, because it's a
Good Idea, but it's never been part of the WaSP's mission."
6-0,"passage: Day 3: Bill - Mark Pilgrim's ""30 days to a more accessible weblog"" series continues with the story of Bill, a retired military officer with a physical disability who surfs the web on an old Linux laptop and runs a mailing list on Veteran's rights. The piece also clarifies that the characters profiled are fictional (call me naive but I wasn't sure if they were based on real people or not). I can't wait to see where Mark is going with this - 3 days in and he has already built up some beautifully observed case studies and it will be fascinating to see what he does with them. I'm also intrigued as to how he can make his blog any more accessible - his current accessibility statement demonstrates a far higher level of understanding than any other site I've yet seen on the web."
7-0,"passage: I think this is an excellent idea, but then like Scott Johnson I like the idea of doing the right thing. I've mailed my note of support to amazon@fuzzygroup.com. If this takes off in a big way it could really demonstrate the power of the humble blog."
7-1,"passage: Spotted over at FuzzyBlog: If I Was Jeff Bezos of Amazon and I wanted to do the Right Thing, Here's What I'd Do. In a nutshell, Scott Johnson suggests that Amazon set up a free (or very low cost) system for charities to gather donations through Amazon's payment system - a charitable version of PayPal. Why Amazon? They have a good reputation, a well implemented payment system and a massive user base. The more convenient the system the more likely people are to donate."
8-0,"passage: The amazing tree generator (via webgraphics, who in turn got it from CSS Discuss). This is just the kind of DHTML I really like. Place a simple nested unordered list in your document and this external javascript can use the DOM to convert the list in to a hierarchical outline style tree, with each node expandable to show the child members. It looks great and works in both IE and Mozilla - I haven't tested it in other browsers but it should degrade gracefully, leaving them with a static nested list."
9-0,"passage: Mozilla 1.1 Alpha was released yesterday, and after reading Scott Andrew's recommendation (especially with respect to the mail client) I decided to give it a go. I found the ability to turn off images in mail eventually - it's hidden away in Edit->Preferences->Privacy & Security->Images as opposed to Mail & News preferences where I looked for it first."
9-1,"passage: The features that made it worthwhile for me was the welcome return of the site navigation bar. Mozilla can once again take advantage of <link> tags in HTML documents, adding an additional toolbar with previous/next buttons and other useful options. The feature was pulled from Mozilla 1.0 for performance reasons, but it's back in 1.1 and useful as ever. I was pleased to see that it picks up on Mark Pilgrim's RSS alternative version link, listing the RSS version under ""Other Versions"". Useful information about getting your site to take advantage of this feature can be found here - looks like I've got some work to do..."
10-0,"passage: Some of his points seem overly picky, in particular the content-type issue. I checked a site Hixie mentions as sending the correct text/xml content-type header in NS4 and, as I suspected, NS4 popped up a ""download"" box and failed to render the page. I also checked out the W3's XHTML home page - XHTML1.0 strict and a content-type header of text/html. His other points seem worth thinking about, but I would not consider any of them to significantly dilute WaSP's message."
10-1,"passage: So respect to Hixie for taking on the mantle of the ultimate standards advocate, but you can take a good thing too far."
10-2,"passage: Hixie has been poking around the new Web Standards Project site, and he is not impressed. His analysis of the site makes interesting reading, with complaints including CSS colour and background not being set at the same time and the content-type of the document being set as ""text/html"" rather than the more correct ""text/xml"" required for XHTML documents."
11-0,passage: The message may not be diluted... I simply think it is very bad form for a group that is claiming to champion the standards to be making any mistakes at all on their site.
11-1,"passage: If by serving content with a text/html header I can create pages in future-proof, easily parsable XHTML and have them accessible to virtually every browser ever release, XHTML it shall be. Then when browser support catches up I'll be ready, and so will my websites."
11-2,"passage: I can't disagree there (and I hope they correct some of the problems with the site). As for the content-type header issue, Hixie's stance is that using XHTML at this time is inappropriate due to a lack of proper browser support. He's probably right on that as well, but that leaves us with the question ""When CAN we start using XHTML?"". The browser upgrade cycle for an average net user is horrific, hence the continuing relevance of the five year old Netscape 4. It could be another five years before browsers that support XHTML properly are dominant enough for it to be worth while."
11-3,passage: Hixie has replied to my previous post (and provided my first ever link in the process).
12-0,passage: I'm not too interested in marketing but the idea of sharing knowledge to improve ideas is the principle reason I started this blog.
12-1,"passage: More FuzzyBlog stuff. Scott runs one of my favourite blogs - constantly updated, plenty of interesting new content and most of it fits the areas I am interested in. Today's items that caught my eye are Why Do I Blog So Much? and Very, Very Practical Tips for the Busy Person : Part 2 (actually posted on Monday, find Part 1 here.). I particularly liked the following quote from ""Why Do I Blog So Much?"":"
12-2,"passage: Blogging is a superb knowledge capture tool [...] I use my blog to capture my marketing ideas because if we are to grow, others need to know this. The interaction I get from sharing them with the world only improves them."
13-0,passage: Thanks for the educational exchange Hixie :)
13-1,"passage: Hixie has answered my question. Judging by how long it took IE to support CSS1, he estimates 6 years until XHTML is ready for main stream use. He's almost certainly right, but I'm going to try to stick with XHTML any way (bandwagon jumping can be fun). He also points out that this site does not validate - I checked the original template but it seems that several of the entries I have added have inadvertantly invalidated the page, mainly through unescaped ampersands and the like. Time to add an automatic ""validation"" system to my administrative tools - it's a shame the W3 validator isn't available as a web service."
14-0,passage: I validate again.
15-0,"passage: I don't know how I missed this, but the PHP group have released an alpha version of PHP with the Zend Engine 2 (tarball / Windows binary). This is exciting stuff - the new scripting engine has vastly improved object support and brand new exception handling, something I've wanted in PHP for a long time. The CHANGELOG lists the new features and provides sample code. Here's a summary:"
15-1,"passage: It's all good, but it comes with a hefty warning against using the alpha on even semi-production web sites. Personally I can't wait for a deployable version."
16-0,passage: Eric Raymond: Sex Tips for Geeks :)
17-0,"passage: Mark Pilgrim's set of case studies is beginning to shape together. I've been following responses to it through his ""Further reading on today's posts"" referral tracking tool - reception has been overwhelmingly positive, with almost universal praise for Mark's decision to use the case study format to drive home his point. kcalder criticised Mark's suggestion that colour blind users wouldn't get much out of images on the web, and Mark has apologised and altered the case study accordingly. SubAverage called Mark ""preachy"" and posted a parody (mentioned in passing by Dave Winer). All this and we're only on day 4."
18-0,passage: Dane Carlson: Blog to be added to the Oxford English Dictionary.
19-0,"passage: I'm itching to get an XML-RPC interface to this blog up and running so I can start playing with blogging tools (or roll my own in PythonCard). It looks like Dave Winer's MetaWeblog API is just what I need. It describes an XML-RPC interface with 3 methods: metaWeblog.newPost, metaWeblog.editPost and metaWeblog.getPost. More importantly, the standard supports complete flexibility in the data that is sent along with the request. My entries consist of a body, an optional permalink (one is generated if none is specified), optional categories and an optional search string for a ""Google It!"" link if one is required. The MetaWeblog API looks ideally suited to handling this, and is fully extensible should I change the format of my entries in the future."
20-0,"passage: While I applaud his aims and greatly look forward to the series, I can't help but feel that limiting the series to just bloggers is an unnecessary move. I expect most of the tips to be applicable to a wide array of sites and the web is crying out for a good resource for improving general site accessibility. I'm sure Mark's series will be fantastic, but I would love to see it aimed at a larger target audience."
20-1,passage: Over at diveintomark Mark Pilgrim has explained the aims of his Accessibility series:
20-2,"passage: This series is entitled ""30 days to a more accessible weblog"", and it will answer two questions. The first question is ""Why should I make my weblog more accessible?"" If you do not have a weblog, this series is not for you. The second question is ""How can I make my weblog more accessible?"" If you are not convinced by the first answer, you will not be interested in the second."
20-3,"passage: He is planning a five week series of tips for creating an accessible weblog, with a new tip each day. The tips will be explained in such a way that even bloggers with no experience of HTML will be able to understand and implement them."
21-0,passage: Owen Briggs: CSS Panic Guide. Owen is the author of several excellent CSS resources (including Box Lessons and 264 font size screenshots) and this is his collection of links to CSS resources from all around the web. It covers every CSS reference worth knowing about and is an essential bookmark for anyone interested in using CSS for layouts.
22-0,"passage: So, if anyone reads this who I know from Uni and haven't personally had a chance to say goodbye to: Have a fantastic summer and I'll see you in September, if not before."
22-1,"passage: Well, I've reached the end of my first year at Bath University (studying a degree in Computer Science) and I can safely say I've never had 9 months go so fast. I've had a fantastic time - I met the girl of my dreams, made a whole bunch of great friends, did loads of cool things and spent far too much money. Today I move out of halls (a terrifying prospect when you live on the ninth floor and the lift is playing up). As an aside, I also lose my lovely fast net connection and return to the trauma of 56K. Thank goodness for Mozilla and tab based browsing."
23-0,"passage: This site has been here for less than four days yet it already shows up as the top result if you search for simon willison on Google - and I never even submitted the URL. In fact, asking Google to list pages that link to me currently turns up zero results. Spooky."
24-0,"passage: Meg Hourihan: What We're Doing When We Blog. It's a curious fact of blogdom that many bloggers blog blogging - why they do it, what it is and why it's so important. I feel Meg has nailed it with this article - blogging is defined by the format, not by the subject matter. She also makes some insightful comments about why the blogging format works so well:"
24-1,"passage: Freed from the constraints of the printed page (or any concept of ""page""), an author can now blog a short thought that previously would have gone unwritten. The weblog's post unit liberates the writer from word count."
25-0,"passage: Via Daily Python-URL (which appears not to provide permalinks): Introduction to Python iterators. This is an extract from Deitel & Deitel's ""Python How To Program"" and includes extensive code samples. Iterators are very cool - as I see it, they allow you to overload an object ready for use with Python's powerful for ... in ... syntax (as well as other looping methods). This blog is implemented as an object in PHP - had I used Python I could display the whole blog using for entry in blog: print entry."
26-0,"passage: But touch my words, use them as jumping points for third-party sponsorships? There'd better be a check in the mail for me."
26-1,"passage: Scott Andrew LePera in a mail to Webdesign-L (sent on the 12th of June, I'm catching up on my mailing list folders):"
26-2,passage: What I learned from the smart tags issue:
26-3,"passage: Etiquette question: What is accepted etiquette for posting quotes from mailing list material? Webdesign-L does not maintain publically accessible archives anywhere, but is a veritable gold mine of information. Should I consider everything on the list as fair game to be blogged whenever it takes my interest (obviously maintaining credit to the original writer) or should I contact authors for permission first? No comments system yet, so see my contact page if you have a reply."
27-0,"passage: The example requires Mozilla 1.0, as do many of the other css/edge demos. The site has some fantastic experiments on it (all with full explanations and freely available source code) and is well worth exploring."
27-1,"passage: New example on Eric Meyer's css/edge: Pure CSS Menus. This is very impressive stuff - it's an implementation of those dropdown menus where you hover over an item and a new menu pops up, but it's done in pure CSS without a line of javascript. Even better, the markup for the menu is a nested unordered list, so browsers that don't support the advanced CSS needed will still display the menu in a meaningful way."
28-0,passage: rudy on thelist pointed me to this handy List of User Agents.
29-0,"passage: Brent Ashley: JSRS2.1 Released (from June 10th - Internet Archive copy). JSRS is Javascript Remote Scripting, an incredibly powerful javascript library that allows DHTML pages to communicate with a web server without having to reload the page. This latest version fixes POST suport for Mozilla. The library opens the way for a whole host of interactive web applications without the normal limitations caused by the request-and-response nature of the web. Best of all, JSRS is cross platform (at least for Mozilla, NS4+ and IE4+)."
29-1,"passage: Brent actually has two implementations available. JSRS uses DHTML elements (such as hidden iframes) to make RPC calls to the server, while RSLite is an ultra lightweight version that uses cookies for communication (and even works on Opera!). Both implementations are free and come with source code, as well as example server side implementations in a variety of languages including ASP and PHP."
30-0,"passage: Meg Hourihan's explanation of blogging (which I linked to and praised earlier) is stirring up something of a storm. Meg's suggestion that the key to blogging is the format has been ripped to pieces by the likes of BurningBird, Jonathan Delacour and Stavros. Jonathan uses photography as an analogy - some photographers are excellent technically and concentrate on taking the perfect photograph while losing sight of the art of the medium. I hope I'm not overquoting, but Jonathan clinched his argument for me with the following:"
30-1,"passage: I notice Jonathan, BurningBird and Stavros are all on the faculty of AKMA's University of Blogaria. I wonder if they are accepting undergraduates."
30-2,"passage: As a new blogger I am still trying to come to terms with the format and how it works. I think this is why I was initialy so impressed with what Meg had to say - she described blogging in technical terms that made sense to the logical part of my mind. My opinion has been reversed thanks to the interlinked nature of the blogging community, which lead me to opposing viewpoints and helped dramatically improve my understanding of what it is to blog."
30-3,"passage: To focus attention on the magic and mystery of blogging. To acknowledge (paraphrasing Burningbird) that the key to weblogging is people, not a format. To admit that -five years on- we're only just starting to realize what might be possible. To stress the communal nature of the activity. To celebrate the amplification of meaning that occurs when smart, creative people collaborate. To invite newcomers to join a grand adventure, a networked version of Hesse's Journey to the East."
30-4,"passage: Which is not to say there's no place for an explanation of the mechanics of weblogging: tools, posts, links, time-stamps, permalinks... But wouldn't it be better to leave those prosaic details for later? And to start by mapping out an imaginative vision of the medium's potential?"
31-0,"passage: Anil Dash provides a copy of Amazon's home page in HTML 4.0 Transitional, and it validates. Solid proof that you can rewrite a complex ecommerce site in valid HTML, and another victory for the web standards movement."
32-0,passage: I wonder if Paul Sowden has finished his exams yet.
33-0,"passage: With launch notices on both glish and Signal vs. Noise I just had to check out MEETUP. I was not dissapointed. MEETUP is a beautifully simple concept that has been superbly executed. It aims to arrange real life get togethers around the world of people with similar interests. You simply find a topic that interests you and see when the next scheduled meetup for that topic in your area is, then enter your email address to have the site update you on the status of the meetup and remind you nearer the time. Meetup participants vote on the venue (from a list of over 11,000 suggested spots) and the rest is up to them. Why MEETUP?"
33-1,passage: Well worth checking out.
34-0,"passage: Meg has replied to Jonathan's criticism of her piece on the nature of blogging via his site's comments system. She defends her original viewpoint, commenting on blogging that we can't define this thing based on the content we're outputting. It looks like this debate still has quite a bit of life left in it."
35-0,passage: The ideal alternative would be for the W3C to create a web service back end for their validator so blogging software can check the validity of new entries automatically.
35-1,"passage: Thinking about it, almost all of the common errors I am experiencing come from the XML parser rather than the rules governing XHTML. I need an XML parser that examines each post as (or before) it is added to the blog and checks for well-formedness. Expat (used in PHP for event based XML parsing) does not validate documents against a DTD but it DOES die with an error if an XML document is malformed. It looks like it could be just what I need."
35-2,passage: The road to validity is frought with peril. I've just fixed another small group of errors that were preventing this page from validating (after spotting the ominous W3C validator in today's user-agent logs). This time is was a couple of forgotten </p> tags and an unescaped ampersand.
35-3,"passage: There has to be a technological way of helping avoid these errors. Originally I wanted to be able to edit my entries in some kind of specialised markup language (such as WikiText or UBBCode) that the blogging sofftware could convert into valid XHTML, but I quickly realised that the most flexible markup language for blog entries is XHTML itself thanks to the built in support for everything from quotes to lists and code samples."
36-0,"passage: I've been looking at PHP's XML handling functions (in particular the xml_parse() function) and I've suddenly realised the advantages of writing entries in valid XHTML. Before I started this blog one of the features I considered adding was something that can pull all of the links out of an entry when it is submitted and index them or add them to a directory somewhere. I was preparing myself for some regular expression hacking, but thanks to XHTML this is now completely unnecessary. All I need to do is define a couple of handlers to deal with <a> tags and Expat will do the hard work for me. In fact, this approach gives me a great deal of flexibility in what I do with my entries. I can extract quotes and blockquotes, pick up on emphasized text and generally allow my blog software to ""understand"" my entries as and when I add them. The true benefits of XHTML have suddenly become clear."
37-0,passage: That the series is aimed at webloggers rather than a more general web audience seems OK. Better to start with a defined target audience and trust that the story will ripple out from there.
37-1,"passage: Jonathan also links to How to Disagree Agreeably, or at least Effectively, an insightful collection of quotes related to the article title."
37-2,passage: Jonathan has meta-blogged (I think that's the term) responses to Mark Pilgrim's accessiblity series. He replies to my query about the wisdom of limiting the series to bloggers rather than expanding it to cover as much as possible:
37-3,"passage: That makes sense, but I stand by my opinion that the web is in desperate need of a good quality resource on general site accessibility. Sounds like something for WaSP's ""learn"" section to think about. I plan to compile a set of links to general accessibility resources once Mark has finished his tutorial series."
38-0,"passage: Apparently the University of Blogaria was founded on the principle that the ideal university would have no students to contaminate the educational process (Jonathan Delacour). The only way in is to earn a position on the faculty, which no doubt requires slightly more than four days of blogging. Thank goodness their courses (or at least the benefits of their wisdom) are freely available to all."
39-0,"passage: New toy: XWT, the XML Windowing Toolkit. This is one impressive piece of open source software. It allows you to create a graphical user interface using relatively simple XML markup (with ECMAScript to define interactivity). Your application can then be executed using a browser plugin, implemented as an ActiveX component on IE and a Java applet everywhere else. The idea is not to write whole applications in XWT, but to create server side applications and provide a client side GUI using the toolkit. Both SOAP and XML-RPC are supported for communicating between client and server."
39-1,"passage: The demos on the site are very impressive (although slow over a modem) and the technology is at a stage in development where it is ready for deployment. For more information, check out the project's FAQ."
40-0,"passage: Elm0 has suggested a solution to my XHTML validation woes in a thread on WMHub. He suggests using libxml to validate new entries against a DTD, via PHP's exec() function. It looks like xmllint is just the command line tool I need - if only I could get it to compile on the University server. I'm getting ""out of space"" errors which is strange as I have over 10MB left on my account, so I'll assume for the moment that it's a problem with the server and try again in a few days."
41-0,"passage: Micah S Sittig on css-discuss has created an alternative version of the new Yahoo site design using CSS for layout instead of tables. The aim of the excercise was to demonstrate how much code can be saved by using CSS, and this has been achieved admirably with a 60% reduction in overall page size. The new version was developed for Mozilla 1.1 and looks great in that browser, but fails to render quite as well in IE. Still, as a demonstration of the file size benefits that come with CSS it works fantastically well. A full overview of the project alogn with file size statistics and implementation details is available here."
42-0,passage: I've also changed the front page to only display entries from the last three days. All older entries can be accessed through the archive.
42-1,"passage: I've just finished rebuilding the main data file for this blog, after it became corrupted last night due to a ""Disk Quota Exceeded"" error. It looks like this was my fault - I inadvertantly filled up my disk space when I was playing around with libxml and PHP choked when it tried to save the latest update to my blog. Luckily no data was permanently lost as the archives are cached as flat files, which allowed me to rebuild the data file from scratch."
43-0,"passage: I currently use <hr> tags on this blog in between every article, but I have used CSS to prevent them from displaying. This is to ensure that browsers which do not interpret my stylesheet (such as Netscape 4) will still display some kind of divider between entries."
43-1,"passage: Interesting thread today on css-discuss about styling <hr> elements. I had tried this before with no luck, but the thread provided some useful tips. Marek Prokop provided this tutorial, and Kevin W responded with these tips on styling <hr> in Opera. Michael Guitton suggested that setting width: 100%; could help fix problems with Netscape 6."
44-0,passage: Mark Pilgrim starts his series of weblog accessibility tips today with tutorial on adding a doctype to a blog.
45-0,"passage: Boston.com, via Slashdot: Online search engine AlltheWeb claims bigger index than Google. I was under the impression that the 2,073,418,204 quoted on Google's home page is no longer accurate (it hasn't changed in months, and I know Google have been adding things to their index). I had a play with AllTheWeb and it turned up some decent results for my test queries, but it seems to load slightly slower than Google. Further discussion on this can be found over at WebmasterWorld, which is also home to the best Google discussion forum I've ever seen."
46-0,"passage: Food for thought: Joel Spolsky on the economics of Open Source software. Joel starts by explaining the economic concept of complements - products that complement your product so that if their price goes down, demand for your product increases. He then goes on to demonstrate how this concept explains the decision of several large companies (including IBM, Sun and HP) to financially support open source software. As is usual for Joel on Software the article makes fascinating reading."
47-0,"passage: More CSS layout fun courtesy of Webdesign-L. This time Steve Clay has taken Anil Dash's standards compliant Amazon and reworked it to use CSS for layout. Unfortunately it is likely to be a while before a major ecommerce site or portal decides to go with a CSS layout simply because of the continuing relevance of Netscape 4 users, but these examples demonstrate how close we are to being able to leave the era of nested table designs behind us."
48-0,"passage: Concentrating on implementation sounds like a great idea - there are several accessibility resources explaining concepts but I haven't seen any that explain how accessibility can be achieved, especially by web content creators who are not HTML experts."
48-1,passage: Mark mailed me in response to my query about limiting his accessibility series to weblogs rather than expanding it to cover general sites:
48-2,"passage:
Because every project needs to start and end somewhere. There are
disabilities I'm not covering at all. There are certainly more than 25 things
that *every* site should implement. And so forth. Focusing on weblogs lets me
delve deeper into specifics about implementation. This is already apparent in
day 6 -- talking about the specific templates in each weblogging system that you
need to check -- and it will become even more important later on. Many of the
standard arguments against accessibility (my client doesn't want it, it's too
expensive, the site needs to look exactly like the brochure) don't apply to
weblogs, so I will use that to my advantage."
49-0,"passage: Minimal XML is a project of SML-DEV, who describe themselves as a group of over 125 XML experts working to create simple XML standards and to simplify existing XML."
49-1,"passage: Minimal XML is a subset of XML 1.0; including features essential for data interchange applications, and excluding non-essential features that are arcane, legacy-related, problematic for data interchange applications, or redundant."
50-0,"passage: New buzzword (at least for me) - Knowledge Management. Apparently this is a theoretical corner stone of content management, an area I'm very interested in. Plenty of information about it in DMOZ as well."
51-0,passage: Peter Van Dijck: Email interface design 101 - a short article examining the possibilities of using email interfaces for web applications. This is an interesting topic and one that deserves further exploration. I am particularly interested in the security problems faced when building this kind of interface (something that is not covered by Peter's article) - how can you effectively secure an email interface? I'm guessing that for true security the only real solution is PGP encrypted mail and some kind of password driven authentication system. Peter's blog carries a discussion on the article.
52-0,"passage: From Google Answers via Elegant Hack: The tale of the suicidal chipmunk. On a related note, I saw chipmunks on sale at a farmer's show (the Bath and West) a few weeks ago for ten pounds each - very cute but I have no idea if they'd make good pets."
53-0,passage: phpDocumentor version 1.1.0rc2 has been released over at www.phpdoc.org. The feature list (from their press release):
53-1,passage: The full Changelog is also available. This looks like a very useful piece of software.
54-0,"passage: Via thelist: Javascript Selectbox Functions. Extremely useful demonstrations of how multi-line selectboxes can be used to create advanced user interface widgets with javascript, including tools to alter the order of items in a list and pass values from one selectbox to another and back again."
55-0,passage: Mark also points out this handy list of ISO639 language codes.
55-1,passage: Mark Pilgrim's accessiblity series continues: Day 7: Identifying your language. Since I'm using XHTML 1.0 I've changed my opening <html> tag to the following:
56-0,"passage: I've signed up for a new mailing list (probably not a good idea, I'm getting over 200 mails a day which isn't much fun on a modem) - XHTML-L, which describes itself as A forum for discussing XHTML issues for both XML and HTML developers. The list is adminned by Simon St. Laurent, who coincidentally is involved with the SIG-XML project I mentioned earlier today."
57-0,passage: Python advocacy doesn't get much better than this.
57-1,passage: Dan Shafer: Space shuttle engineers use Python to streamline mission design.
57-2,"passage: ""We achieve immediate functioning code so much faster in Python than in any other language that it's staggering,"" says Friedrich. ""Java and C++, for example, have much more baggage you have to understand just to get a functioning piece of software."
58-0,"passage: MSNBC: Why software is so bad. First time round I gave up on this article after reading the joke at the start, writing it off as another dumbed down piece of ill informed rubbish. Then I saw Scott raving about it and decided to give it a second go. My initial impressions were completely wrong - it's a well written (and surprisingly unbiased) article that takes a good look at the problems software faces and how industry practises lead to software getting worse rather than better. This year I've been doing a course on Software Engineering at University and a lot of the article made a great deal of sense in the context of the course. Well worth reading."
59-0,passage: Via Boing Boing: NPR - another site that demands you obtain permission before linking to a page on their site. Will these people ever learn? This is compounded by the fact that their link request form is a classic example of asking for way too much information.
60-0,"passage: Interview with Andrei Zmievski on SitePoint. Andrei is the guy behind PHP-GTK, the project that enables developers to write client side GUI applications using PHP. He is also one of the two lead developers on Smarty, the world's greatest PHP templating engine. Oh, and he's contributed various bits to PHP itself, including Perl compatible regular expressions and WDDX support. All that and he still has time for an interest in the history of western culture ;) The interview makes great reading for anyone interested in PHP, and also provides a link to a web server written in PHP."
61-0,"passage: Interesting rant on Advogato (from June 11th): Professional Programmers. The author complains that the industry is infested with programmers who don't really know anything more than how to write Visual Basic macros, and HR departments who hiee them over ""real programmers"" because they have more VB experience. The article makes some good points but the resulting thread is where the truly worth-while content is. My hope is that the abundance of VB programmers will make it easier for serious programmers (which I'm hoping will be me) to get more highly paid jobs. Time will tell."
62-0,"passage: djc (formerly of evolt) has posted his views on the recent Kuro5hin problems. His take on things can be summarised as ""don't quit your day job until you're sure your hobby can pay for itself""."
63-0,"passage: I like free books (who doesn't?), so when a story on Slashdot asked for book recommendations I started a thread asking for links to free technical books available online. Here's a list compiled from the thread:"
63-1,passage: I have omitted several books that only provide partial tasters on their sites - see the Slashdot thread for a list that includes these. Two other useful lists of free books include the O'Reilly Open Books Project and Libros Recomendados On Line (in Spanish but links to English resources).
64-0,"passage: Day 8: Constructing meaningful page titles - the accessibility tips are flying thick and fast now. I've always been conscientious of my page titles (after all, they're all you get when when you use your browser's history feature) but it seems I was not quite conscientious enough. My titles now all carry a reference to the name of the blog in addition to a description of the page."
67-0,"passage: Incidentally, Peter Van Dijck (the guy behind XFML) runs a superb blog covering information architecture and other web related topics - Guide to Ease. I've only been reading it for a few days but I'm hooked already."
67-1,"passage: Say you run a weblog on a certain topic. You put your posts into categories you have invented yourself. A friend of your also runs a weblog on the same topic, and also puts their posts into categories they invented themselves. Many of these categories are really the same thing, but they are called something else. You both publish your metadata in XFML format. XFML allows you to relate these categories, so they still keep their own names, but your system knows they are really the same. So you import your friends XFML file, and manually relate the categories that are the same. You set your weblog software up so it will import your friends file daily to check for changes. Now your software can automatically generate links to stories about the same topics on your friends weblog that show up with your stories."
67-2,"passage: XFML - eXchangable Faceted Metadata Language (via Guide to ease). Now this is interesting. It's an open XML format designed to facilitiate the publication and distribution of metadata - it uses a load of terms that are currently way over my head (hierarchical and faceted taxonomiest, topicmaps?) but the general principle looks fantastic. I wrote a metadata system last year that used a relational database and it was something of a nightmare - XFML looks like it solves some of the problems I faced, although my biggest challenge was how to grab and present usable information from the huge amounts of metadata collected which is a problem that falls outside the scope of XFML. XFML is best summarised by the following quote:"
68-0,"passage: There's an interesting rambling thread on SitePoint at the moment which started off talking about coding standards but has moved on now to discussing OOP and eXtreme Programming. In it, I try to explain inheritance and the difference between -> and :: while Vincent Oostindië explains the principle of refactoring from eXtreme Programming."
69-0,"passage: John C. Dvorak: E-Mac, i-Mac, No Mac. This is so poor I just had to link to it. John claims that the Mac is on it's last legs and deserves to be put down, which is a complete contradiction to almost verything I've read about Macs in the past siz months. I've never had a Mac and I've had few chances to use one, but I would jump at the chance to own one at the moment. Why? Simple, OS X. Apple have taken a truly world class operating system (FreeBSD) and added a truly world class GUI - a combination that I don't think is matched anywhere else in the computing world. They're innovating like never before - AirPort and the i-series of software are great examples. John completely fails to back up his viewpoint at any point in his article - in fact the worst he does is to criticise Apple management of running Apple ""like a tire company""."
69-1,"passage: Related reading: Slashdot discussion on John's column, Apple's 10 reasons to switch to a Mac, Scott Johnson on how impressed he was with his partner's new iBook."
69-2,"passage: I've probably fallen for this deliberate troll hook, line and sinker, but it really annoys me when respected columnists come out with this kind of unsubstantiated claptrap. Especially when they accompany it with such fallacies as I'm not writing this column as a Mac basher to get attention, although plenty of people will accuse me of doing that."
70-0,"passage: Peter-Paul Koch on evolt: One browser, many names - an invaluable guide to the many different version numbers and user-agent strings resulting from the Mozilla project."
71-0,passage: This is clever. The RSS feed for the World Wide Web Consortium uses an XML stylesheet to render visually in both Mozilla and IE. It's a shame the links don't work but it's still a nice idea.
72-0,"passage: Today's accessibility tip: Providing additional navigation aids. Mark explains the concept of ""relative"" links using the <link> tag, which can be used to provide shortcuts to the next and previous page in a sequence as well as links to a site's homepage. He also provides instructions for implementing them in Moveable Type, and asks for suggestions as to how it could be done in Radio. These links are not rendered in the actual body of a page but can be used by many browsers to provide additional navigation aids. My blog has these already but only as shortcuts to my categories and a link back to the home page - I haven't yet implemented them for next/previous buttons while browsing the archives (which is arguably their most useful ability). Time to get hacking..."
73-0,"passage: I've implemented the next/previous additional aids options in the archives. It ended up being quite an ugly hack, but it works."
75-0,passage: Mark's accessibility tips are getting harder. Today we are advised to Present our main content first in our source code. This benefits both text based browsers and search engines such as Google. Mark points out the ingenious table trick which allows table based layouts to present the main content before the left hand menu in the source code and provides tips on implementation. Thanks to the benefits of CSS layout my blog only needed a small alteration - I was presenting the div containing the navigation in the source code before the div containing the main content. A quick switch of the order of the divs and the CSS did the rest for me without any further alteration.
76-0,passage: Dave's back. Thank goodness for that :)
77-0,"passage: More on BoingBoing about NPR's link policy. It seems NPR are reconsidering their policy, but in the mean time they have posted a defence of it which Cory Doctorow criticises at length."
79-0,"passage: Via Slashdot: VillainSupply.com - for all your world domination needs. Product categories include Superweapons, Lairs and Miscellaneous Evil."
80-0,passage: New project in the works - details to follow soon. In developing it I've learnt two new things about Mozilla:
81-0,"passage: I've added a comments feature to this blog, in preparation for tomorrow's big story (hinted at below)."
82-0,"passage: A List Apart: Time Management - The Pickle Jar Theory. I like this concept - it's simple, doesn't involve long words or complex charts and makes good sense. The basic idea is that you should schedule only your high priority tasks for the day and leave the gaps in between for less important activities (email, browsing and so forth). This is supported by the analogy of a pickle jar, where you can fit more in the jar if you add large pebbles first before pouring in smaller pebbles and sand (rather than adding the largest pebbles last when they will be unlikely to fit). Jeremy Wright, the author of the article, is a regular over on the SitePoint forums."
83-0,"passage: Message to Mook: If you absolutely have to use an animated intro give people the option to skip it (I thought the general Flash community got the hang of this idea several years ago). Luckily the Glastonbury site offers non-flash alternative methods of accessing the information in question, which are generally much faster and more intuitive than the interactive map anyway."
83-1,"passage: I'm headed off to Glastonbury on Thursday and I've been checking out the offical festival website. It's pretty good - the information I wanted was all there, it was easy to find and the site has a pleasant enough look to it. Then I tried the interactive flash map (warning: spawns popup). Running on my Dad's brand new Pentium 4 1.8 GHz desktop, the opening intro animation ran like an absolute dog and took over a minute to finish. There was no ""skip intro"" option and no way to turn off the irritating music until the intro had finished. Once it had loaded the map was quite useful - you can overlay paths, information points and other bits and pieces straight on to the map which is a decent enough reason to use flash. Unfortunately the pointless, jerky 3D intro meant I very nearly gave up in disgust before I got to the good stuff."
84-0,"passage: I've been playing around with Mozilla's ""Page Info"" feature, available in the View menu, the right-click context menu and through the Ctrl+I shortcut. I'd never really lookd at it before, but the information it provides is invaluable, especially if you are interested in web development. The info window is divided in to five tabs:"
84-1,passage: All in all this is a very powerful tool - I'm surprised I hadn't noticed it sooner.
85-0,"passage: Day 11's accessibility tip is Skipping over navigation links, which suggests a compromise for people who did not or could not comply with Presenting your content first. I altered my template to present content first on Friday, but before then I was using a skip-navigation link. I now have a skip-content-to-access-navigation link instead, a technique I borrwed from Mark's site but which he does not mention in today's tip."
86-0,"passage: I just engaged in some basic Python advocacy, during which I rolled out my all time favourite Python advocacy link: Why Python? by Eric Raymond."
87-0,passage: More on this feature can be found in the PHP manual.
87-1,"passage: I've lost count of the number of times I've posted this PHP tip on a forum somewhere, so I may as well blog it:"
88-0,"passage: I'm currently reinstalling PHP on my Windows machine, and in doing so I came across this tutorial: Installing XSL and PHP on Windows. The tutorial provides all the necessary files and instructions to get XSL working with minimum hassle. I've been meaning to play with XSL for some time, and this has provided me with just the boost I needed to give it a go."
89-0,"passage: Anders Ramsay: How I work as an Information Architect (via Guide to Ease). An interesting overview of Information Architecture, including what it involves and how it can be aproached. The article also touches on Software Engineering related concepts such as project management and system design."
90-0,"passage: Via Brett Merkey on CSS Discuss: Dot Leaders without Tables. Dot Leaders is a publishing term that describes the rows of dots frequently used in tables of contents to connect a chapter title with its relevant page number on the other side of the page. Brett's CSS solution resizes elegantly to fit the page, and there isn't a table in sight. Brett's site provides an assortment of other useful CSS resources, including a very handy CSS cheat sheet."
91-0,"passage: Via Boing Boing: How to make your own IM Bots. This tutorial explains how to write a bot for both MSN and AIM using Perl running on Windows/DOS. Perl modules are provided to handle the actual protocols, and sample code is available to help you get started."
93-0,"passage: Kuro5hin are running a fascinating story on AudioGalaxy, written by one of the AudioGalaxy developers who wrote a large portion of the web interface code. It covers the history of the system and its recent demise at the hands of the RIAA, with quite a few technology pointers as well (they used PHP to serve over 90 million hits a day)."
94-0,"passage: Mark's latest tip is up: Using color safely. I'm aware of the rule that you should never use only colour as an indicator of something in a user interface, but I had completely forgotten that my own links on this blog were a classic example of that - all that distinguished them from the rest of the page was a difference in colour. I've now turned underlines back on for all links except those in the entry footers (which looked ugly with underlines), based on the principle that the text and position of the footer links should be enough to explain their purposes even without the underline."
95-0,"passage: SitePoint have a good new article on CSS layout, which includes some useful tips on how to use position: float and position: absolute to create columns on a page, as well as some tips on providing Netscape 4 with only basic CSS rules and an example of a PHP browser detection script."
96-0,"passage: Incidentally, this article on Salon explains the sorry state of American commercial radio in detail, and in doing so helped me understand why internet radio is such a big deal in the States."
96-1,"passage: Slashdot: Shocked, Shocked at Payola. This is just tragic. American record companies are all upset about the huge amounts of money they have to spend bribing commercial radio stations to play their music... but at the same time the RIAA are killing off internet radio and p2p file sharing, activities that give bands exposure for free! OK, file sharing allows people to keep the copies they download which is something the RIAA have justification to be cautious about, but killing internet radio and then complaining about the costs of promotion on commercial radio is just farcical."
97-0,"passage: Semant-O-Matic - an experimental blog search engine. This is an impressive technology demonstration. The engine indexes eleven weblogs over the period of four months (March to June 2002) using a technique called ""latent semantic indexing"" or LSI. A full explanation is provided on the site but this basically means that you can type in a term such as ""hobbit"" and recieve a bunch of results about related topics (i.e Lord of the Rings) that don't necessarily have to mention the word itself."
97-1,passage: I've been doing some reading on the semantic web recently and it looks like the way things are headed - Semant-O-Matic provides an easily understood demonstration of why topics like metadata are becoming so important.
98-0,"passage: The 5k is an annual competition in which entrants must create the most impressive web site in 5k or less. This year's competition entries are now online and the quality of the entries is even higher than the previous two years. My initial favourite is Wolfenstein 5K, a texture mapped first person shooter implemented in 5119 bytes of cross browser javascript (I tested it in Mozilla and IE6, and the author claims it runs in Netscape 4)."
99-0,"passage: WebReference: XML in Mozilla 1.0. A quick summary of the XML technologies available with Mozilla 1.0, code samples not included."
100-0,"passage: EuroPython 2002 kicks off today, and the EuroPython site is hosting an interview with Alex Martelli (comp.lang.python regular and author of the soon-to-be-released Python Cookbook). I haven't found anyone who's blogging the conference yet though."
101-0,"passage: Slashdot has a story on XWT (mentioned previously). Adam Megacz, the author of the system, does an excellent job of defending and explaining the concepts of XWT in the discussion thread attached to the article."
102-0,"passage: When developing PHP applications, I usually have a classes directory somewhere in which I keep all of my PHP classes ready for inclusion. I name the class files ClassName.class.php. Normally I have a common.inc.php file that is included in all of the scripts in my application and requires the classes needed by the application, but today I wrote a few lines of code that saves me from having to alter that file every time I write a new class:"
102-1,"passage: It's nothing revolutionary, but it's already saving me development time by allowing me to save a file straight in to the directory and instantly have the new class available to all scripts in the application."
103-0,passage: Day 13: Using Real Links (or why you shouldn't use javascript:). I'm ahead on this one - Scott Andrew convinced me of the dangers of javascript: a month ago and I designed my comments system with this in mind.
104-0,"passage: Useful resource: Cetus Links - 18,244 Links on Objects & Components. I found them via their Python page, which in itself lists over 200 Python resources split in to categories."
105-0,"passage: Enterprise Application Architecture by Martin Fowler: A fantastic book on Object Oriented patterns and how they can be applied to large software projects. The book is available on the web as a work-in-progress and I can safely say I've never found an online resource that has taught me more about software design. Literally 24 hours after finding it my head is swimming with design patterns, domain models and relational database mapping techniques, and I've already started using some of the patterns in my latest project. A big thanks to Captain Proton on the SitePoint forums for pointing it out (and also for helping me understand PHP references a few days ago). I thoroughly recommend this to anyone who is serious about learning Object Oriented design, or indeed any OO-capable language."
106-0,passage: Warchalking now has its own website: Warchalking.org. Warchalking is one of those brilliant ideas that quickly takes the 'net (or at least parts of it) by storm. The basic idea is a set of symbols which can be chalked on walls in areas with a wireless network node to alert other geeks to the availability of bandwidth. I'd go in to it further but the site has as much information as anyone could possibly want on the subject.
107-0,"passage: My girlfriend won tickets to Glastonbury from her local radio station (and backstage passes, which is nice). So off I go for four days of muddy hedonism - and hey, I might even get to see a few bands as well. I'll be back on Monday but I probably won't have recovered until Tuesday so no blog updates until then. Have a great weekend, I know I will ;)"
107-1,passage: Gone to Glastonbury
108-0,"passage: Back from Glastonbury. Blog catchup tonight, Glastonbury writeup tomorrow."
109-0,"passage: Hixie has open sourced his Perl weblog system. It has some nice features but a pretty extensive set of requirements (MySQL, CVS, Expat and a whole bunch of Perl modules). He has also added support for next and previous buttons at the bottom of each entry, but has not yet added <link> element support, as recently described by Mark Pilgrim."
110-0,"passage: I linked to the 5k entry Wolfenstein 5K the other day. Lee Semel, the author of the entry, has written an article describing how the impressive Javascript first person shooter works. The principle method used is the dynamic creation of XBM images using a 3D graphics technique known as raycasting (described in this tutorial). The author incorrectly states that Mozilla does not have the capacity to render XBMs - Wolfenstein 5K runs just fine in my version of Mozilla so I presume support has been added since he last tested it."
111-0,"passage: MovableType have released version 2.21, which finally introduces support for mySQL and also comes with an intriguing new feature called TrackBack. I'm stil trying to figure out exactly what TrackBack is.. so far I've figured out that it invovles embedding RDF information directly in to your blog which can then be combined with a ""ping"" to other blogs to inform them that you have linked to them, and give them additional information about your blog for display on a special TrackBack section for each of their blog entries. Scott Andrew has already implemented it and many other MovableType blogs are setting it up as well. TrackBack has its own blog, which has an interesting entry hinting that TrackBack could soon become part of a system for distributed taxonomies (a problem that XFML is also looking to solve)."
111-1,"passage: I'm not completely convinced by TrackBack. The implementation includes RDF embedded in blog entries which breaks XHTML validation (a problem the trackBack developers are already working on - could comments around the RDF data help here?) and I can't really see any advantages over standard referral tracking as implemented on diveintomark. I plan to implement my own referral tracking system soon and I will almost certainly model it on Mark Pilgrim's, although I hope to provide additional information about the referral source gained by parsing their HTML. That said, I'm still trying to understand exactly how TrackBack works so I will reserve judgement until then."
112-0,passage: The Scourge of Arial (via Zeldman). An interesting short history of modern typefaces and how Arial become widespread despite being merely a poor imitation of Helvetica.
113-0,"passage: I'm suffering from a bizzare PHP bug. For some reason, POSTed form entries over a certain length are being lost when submitted to scripts running on this site. Here is a demo script which demonstrates the problem - try typing in a short chunk of text and it will submit fine, but anything long (seemingly over about 1300 characters) will be mysteriously lost. The server's PHP Info output is available. If you have any idea what could be causing this drop me a line or add a comment to this entry."
114-0,"passage: Time to catch up on Mark Pilgrim's accessibility tips. Four have been added since I last checked, so I'll go through them in turn."
115-0,"passage: Spotted on MeyerWeb: Eric Meyer on CSS has been released. This is one book I'm really looking forward to getting (at least when I can afford it) - Eric is one of the world's leading authorities on CSS and the new book promises 13 full projects, with particular attention paid to CSS positioning. The advance reviews as listed on the book's official site look very promising as well."
116-0,"passage: Phil Ringnalda (now added to my blogroll) has posted his latest thoughts on TrackBack, and he seems to have come on an ideal solution to the problems mentioned earlier. He is now considering keeping the TrackBack RDF data in a seperate file referenced via a <link> tag. This gets around the validation problems and the weirdness of embedding RDF in XHTML in one stroke, but it seems Blogger may have a problem supporting it as it does not have the ability to generate external files."
117-0,passage: I'm listed on the Guardian's weblog list :) The link is quite well hidden (in the Tech weblogs section) but it's still pretty cool. The list details some excellent blogs covering a large range of topics.
118-0,passage: ThinkGeek: The caffeine is absorbed through the skin...
119-0,"passage: It looks like the Glastonbury write-up will have to wait until tomorrow, but in the mean time here's a handy tip (presented evolt style):"
119-1,"passage: <tip type=""Offline Browsing"">"
119-2,"passage: If you ever want to grab a large chunk of a site for offline browsing in Windows, WGET is the ideal tool. First download WGET for Windows. Now drop wget.exe in a directory on your System path (on Windows XP I used C:\WINDOWS\system32). Fire up a command prompt (windows-key + R then cmd and enter works for me) and type wget --help for a list of options. Most of the time the article / section of the site you want will all be contained in a subdirectory of the site, in which case you can use wget -r -l0 --no-parent http://site.com/whatever/ to grab everything in that subdirectory, without WGET following any links to parent directories."
119-3,passage: </tip>
121-0,"passage: Here's something I picked up on the Sigia-l mailing list the other day, courtesy of Patrick Hunt (reproduced with permission):"
121-1,"passage: [A Message Catalog is...] A database of inline error, exception, informational and instructional
messages that can be dynamically called to a page-level message component
based on user ID, role, system/object state or some other parameter. Allows
messages to be re-used as appropriate and dynamically generated rather than
hard-coded. In addition to typical error messaging, such a system can be
tied to personalization, upsell/cross-sell, etc. The IA would conceivably be
involved, at a minimum, in determining message types and identifying pages
that require messages."
122-0,"passage: The latest issue of Digital Web Magazine is out, and it includes an excellent case study on redesigning a table based layout to use CSS: Web Page Reconstruction with CSS. They also have a review of Eric Meyer's new CSS book, mentioned yesterday. Digital Web are currently looking for volunteers to help with the magazine's upcoming redesign - further information and a contact form can be found here."
123-0,"passage: Mathematical Lego Sculptures (via Slashdot). These are really cool - all kinds of bizzare mathematical shapes are on display, including some that are technically impossible (such as the Klein Bottle). The Slashdot discussion lead me to several other impressive lego sites, including a huge lego stegosaurus and a working full size grandfather clock."
124-0,"passage: Using the XML HTTP Request object (via techno weenie) is an excellent tutorial covering remote XML loading capabilities in both IE and Mozilla, along with instructions on how to make SOAP requests using this technology."
125-0,"passage: Redesigned W3C validator icons (via Zeldman). I like these a lot - I've avoided using a validator icon on this site up to now because they're pretty ugly, but I'll add the alternative XHTML 1.0 icon now."
126-0,"passage: Evolt: New DOCTYPE sniffing in upcoming Mozilla releases. If you weren't confused enough by Mozilla's standards and quirks modes, the next release of the browser will include a third rendering mode called ""almost standards"" mode. Thankfully the difference between this and full standards mode is minimal - the only change is a subtle alteration to the way imagfes are handled in tables. This prevents table based layouts from breaking in standards mode (behaviour which has been described by Eric Meyer on Netscape DevEdge). This topic came up on SitePoint recently and will probably be well recieved by most web developers, once the initial confusion has been overcome."
127-0,"passage: Slashdot are carrying an interview with Craig Silverstein, Google's director of technology. The interview is actually quite disapointing - the answers given are relatively short and little new information is given. Topics covered include Google's programming contest, how they monitor their immense server farm and a few questions on Google corporate culture."
128-0,passage: I have restructured my contact page to take these in to account.
128-1,passage: Today saw a useful thread on Webdesign-L about hiding email addresses from spambots. Some of the points raised:
129-0,"passage: Mark also links to Table Manners, a superb guide to creating accessible tables."
129-1,"passage: Mark has been educating us on the accessible way of marking up tables, with particular reference to calendar tables on blogs. My blog doesn't have a calendar (yet, I'm considering adding one) but Mark's articles have brought up some interesting things that I was previously unaware of. Giving your calendar a real caption explains the <caption> tag, which can provide a useful (and easily styled) caption for any table. Using real table headers explains how <th> tags are interpreted by speech browsers and shows how they can be used in conjunction with the abbr attribute to create more accessible table columns."
130-0,"passage: Via Boing Boing: Seth Schoen's notes on Palladium after a meeting with Microsoft. Cory Doctorow points out that Seth is probably the most knowledgeable tech person to have been briefed on Palladium by MSFT without signing an NDA and his post certainly makes interesting reading. Palladium has had a lot of coverage since the Newsweek article announcing it first broke, with Robert Cringely providing some of the best analysis (in my opinion at least). The Register also has a story about Palladium which introduces some more information and guestimates on a shipping schedule."
131-0,"passage: Brent Ashley explains K-Logging. K-Logging is Knowledge Logging, a technique that companies can use to help share knowledge built up over the course of a project. Generally it involves the use of blogging style tools to informally record every part of a project. Brent also points to this article explaining 11 common KM problems and how K-Logging helps overcome them."
132-0,"passage: The one constant feature of blogs I visit is an RSS feed, so it looks like I need a tool which can monitor a set of RSS feeds (daily, hourly or whatever) and watch for updates. Does such a thing exist? I would prefer a tool that runs locally to an external service, in fact I'm very tempted to write one myself."
132-1,"passage: I need a good, reliable way of automatically checking when various weblogs have been updated. I've tried aggregators (both Radio Userland and Amphetadesk) and they don't do it for me - I don't want to read everyone's blog entries on one page, I just want to know when I should visit their site for updates. Weblogs.com appears to act as a centralised resource for recording updates, but requires blogs to ""ping"" it when they are altered - but what if the blog I am interested in doesn't do this? Mine doesn't (for the moment at least)."
133-0,passage: A few useful links spotted on css-discuss:
134-0,"passage: A couple of home improvements. I've added a ""5 latest comments"" box to the front page, and I've implemented a system to ping blo.gs whenever this blog is updated. Next up, Weblogs.com."
135-0,"passage: I've found a solution to my blog tracking problems. blo.gs is an excellent service which tracks when weblogs are updated by waiting for pings - either directly from the blog or indirectly by co-operating with Weblogs.com (and several other services). blo.gs users can then create a list of blogs they are interested in and have the site email them whenever one of their favourites is updated. If you don't want even more email (I certainly don't) the site can be set up to only display your favourite blogs in last-updated order when you visit it, or you can opt for a very handy Mozilla toolbar."
136-0,passage: Funky javascript popup windows (via wdf-list).
137-0,"passage: More Python advocacy: PYTHON: Yes, You SHOULD Be Using it! The article contains some background information on Python and why it is worth knowing, but the bulk of the article consists of a getting started guide for Python on Linux, complete instructions on using the interactive prompt, code samples and a small CGI script. It is worth noting that the CGI script example should not be deployed anywhere accessible to the public as it could allow crackers to execute code of their chosing on your web server."
138-0,"passage: Rasmus Lerdorf (the creator of PHP) has a blog. His latest entry discusses Palladium, and asks if it will actually help build up the alternative market of non wintel users."
139-0,passage: Hixie BSc (Hons) passed his degree. Congrats :)
140-0,"passage: Macromedia to Embed the Opera Browser in Web Authoring Products - it seems Opera could soon be providing the rendering engine for Dreamweaver's preview mode, at least on the Mac. Great news for CSS layout enthusiasts as from what I've heard Dreamweaver MX still does a lousy job of previewing CSS positioning in the editor."
141-0,"passage: More deep linking stupidity (via Scripting News). A judge in Denmark has ruled in favour of a newspaper who took a search engine to court over ""deep linking"", despite the search engine's spider following the robots.txt standard (it seems the newspaper didn't bother to implement a robots.txt file). Dave Winer summed things up perfectly:"
141-1,"passage: BTW, deep linking is an oxymoron. There's only one kind of linking on the Web. Why would you ever point to the home page of a news oriented site."
142-0,"passage: A final table tip from Mark: Providing a summary for tables. Mark explains the summary attribute which should be attached to every <table> tag to summarise the purpose of the table. Tables used for layout should include an empty summary attribute to show they are layout tables (in a similar way to empty alt tags for layout images). The summary attribute is only used by text to speech browsers, so I'm slightly confused as to why it should be included for layout tables - surely if the attribute is empty a speech browser will skip tstraight over it as if it wasn't there?"
143-0,"passage: Caveat Lector: <em>, <strong>, and markup assumptions. Dorothea Salo explains these semantic tags, why they exist and when they should be used, and throws in a bit of HTML history as well."
144-0,"passage: Kevin runs one heck of a blog, which true to the above quote covers a massive range of interests. I'm inspired :)"
144-1,passage: Kevin Burton:
144-2,"passage: I personally believe that being intellectually open, to the point of promiscuity, not only helps further technology and society, but is an ethical issue as well. We have too many barriers to intellectual progress and these need to be eliminated."
144-3,"passage: To that end, I have created this website as a public diary. I publish all my bookmarks and any relevant topics which I feel might benefit the public."
145-0,"passage: Third, the case is very specific and isn't as much about technical details as it is of legal matter. It was concluded that Newsbooster was in violation of Danish law of marketing (""good ethics"", mainly concerning not gaining/harvesting of other companies products and services) and Danish law of intellectual property, since the articles at the Danish newspapers' sites were to be considered as a database, an index. Databases are also covered by the law of intellectual property [...] and since Newsbooster copied what would be considered as a database, the ruling was against Newsbooster. "
145-1,"passage:
[...] Second, the Danish Newspaper Publisher's Association weren't concerned about search engines like Google or just a few deep links. Newsbooster did a systematic index and furthermore sold services for update-information whenever your predefined search words matched any news article."
145-2,passage: It seems there's more to the Danish deep linking story than first meets the eye. This comment on Slashdot clarifies some important details:
146-0,passage: elgooG (via the Google Weblog).
147-0,"passage: Janis Ian: The Internet Debacle - An Alternative View (via Scripting News). This is an excellent, well researched piece on the problems facing the American music industry by an artist with over 20 albums under her belt."
147-1,"passage: As artists, we have the ear of the masses. We have the trust of the masses. By speaking out in our concerts and in the press, we can do a great deal to damp this hysteria, and put the blame for the sad state of our industry right back where it belongs - in the laps of record companies, radio programmers, and our own apparent inability to organize ourselves in order to better our own lives - and those of our fans"
147-2,"passage: She heavily criticises the RIAA's appauling treatment of artists and backwards view of the internet, which could in fact help give thousands of artists free exposure which they would never recieve otherwise."
148-0,"passage: Stuart at kryogenix.org saw my post about blo.gs and re-implemented his blogroll to update from his blo.gs subscriptions, complete with last updated times. It's such a brilliant idea that I've implemented it here as well. blo.gs allow you to syndicate your subscriptons in various formats, but by far the most useful is favorites.xml, which orders them by last time updated and includes information on the time they last notified blo.gs of an update. It took less than 10 minutes to write a short PHP script to parse the XML and a few minutes more to set up a cron job to grab the XML file every hour. This is impressive stuff - thanks to blo.gs, XML and idea-sharing-via-blog myself and Stuart both have an automatically updated list of blogs right there on our sites."
149-0,"passage: More info on blo.gs syndication. Phil Ringnalda has published a PHP script which can be used to syndicate a blogroll from blo.gs. For people without the capability to run server side scripts, blo.gs also syndicate blogrolls in a javascript file which uses document.write commands to display a blogroll on a page."
150-0,"passage: Stuart has added an extra innovation to his blogroll. Clicking on a link there now sets a cookie (via javascript) recording your visit - these are then used to display a 'new' icon if a blog has been updated since your last visit. The only downside is that the system can only track visits made through links on Stuart's site. Stuart says that easily automated stuff like this is why he recommends using a system like Moveable Type rather than rolling your own blog software. He's right, but I treat writing my own as an entertaining learning excercise - I get to play with RSS, web services, XML parsing, the fun never stops ;)"
151-0,"passage: Micah Sittig made an interesting suggestion in a comment attached to an earlier entry. Micah suggested adding an inert ?lastUpdated=time attribute to links in my blog roll, causing browsers to display links to blogs that have been updated since the last visit in a different colour. I've implemented this temporarily, but I'm slightly worried about whether or not this constitutes abuse of the XHTML standard. The additional query string doesn't break any of the blogs on my blogroll but it is still resulting in fundamentally different page request being sent, which could lead to problems. I'll leave it for the moment, but I think this may need reconsidering in the future."
152-0,"passage: Thanks to another excellent suggestion from Micah, this site now has an experimental Mozilla sidebar. Click here to try it out (only Mozilla or NS6 owners need apply)."
152-1,"passage: UPDATE: For some reason visited links in the sidebar aren't showing up in a different colour. This seems to happen with other sidebars as well, which suggests it's a Mozilla issue."
153-0,"passage: Dave Winer: The Two Way Web. The Two-Way-Web is a vision for the Web as an easy writing and publishing environment. This is an old essay from March 2001 (I only found it today) which describes a vision of a web where content can be quickly and easily edited through a variety of tools, which communicate with content management systems using XML-RPC and SOAP. This is all stuff I've been thinking about recently, so it looks like I'm only a year and a half behind Dave ;)"
154-0,"passage: Paper Scissors Stone is more complicated than I thought (via BoingBoing). This article from 1999 describes the second international RoShamBo programming contest, in which entrants had to provide a program that could play other programs at the classic childhood game:"
154-1,"passage: A good predictive algorithm will be able to play RoShamBo very well, without being explicitly programmed to solve that task. A few applications of such algorithms are data compression, grammatical inference, speech recognition, data mining, natural language understanding, syntactic pattern recognition, speech segmentation, machine translation, text generation, spelling correction, author identification, email classification, image recognition, stock market analysis, finding structure in data, analysis of DNA sequences, analysis of music, input methods for disabled users, and playing RoShamBo! "
154-2,passage: The winning program Iocaine Powder is described by the author here.
155-0,passage: Another gem from the Google Weblog - Google not only accepts OR as a search modifier but allows you to use | instead and still get the same results.
156-0,passage: Jodi Bollaert: Using Web widgets wisely. This is first in a two part series explaining the best practise for designing user interfaces using the form elements available in HTML.
157-0,"passage: I've been reading up on Muse.Net, and I like what I see. Muse.Net is a loosely-coupled, XML Web service derived Internet digital media supply chain. What that means in English is a system to let you listen to your private MP3 collection from any internet connected PC in the world, viasome very funky web service based technology. Your MP3s stay hosted on your own PC (so you need an always on internet connection) while the Muse.Net central service keeps track of what you've got and lets you log in from anywhere to listen remotely. Best of all the web service interface lets you do all kinds of fun things - for example techno weenie's OPML directory of his collection. For more detailed info check out the excellent Muse.Net FAQ."
158-0,"passage: Jeffry Zeldman: Many web practitioners still believe that accessiblity is an ugly, no-frills affair. Not true. An excellent piece on accessibility issues."
159-0,"passage: Today's (obvious) XML realisation: Using XML for storage gives you a platform and language independant storage layer. If you later want to rewrite an application in a different language the data is there and ready to be processed, with no conversion necessary. OK so it's something that is shouted from the rooftops by XML advocates at every available opportunity but today I realised it for myself :)"
160-0,"passage: I'm having trouble understanding the importance of workflow in a CMS. As I see it, managing content assets and controlling which assets are ready for publication can be thought of as two very seperate processes. After all, content can and should be deployed in a whole variety of ways. A piece of content that is not yet ready for publication in a brochure may well be ready for publication on a web site (or may be fit a site aimed at one audience but not yet ready for a site targetted elsewhere). Why tie the publication readiness of an item of content directly to the content, when it would make more sense to attach it to the place where the content will be published - so a site editor can decide when content is ready for publication without permanently altering the status of the content. Or have I completely missed the point?"
161-0,"passage: webgraphics have a new bookmarklet which measures the ""weight"" of a page (the combined size of the page and its graphics) and displays it along with an estimate of download times over different connections. Unfortunately it does not measure external JS or CSS files, and does not work in Mozilla. If you're in to bookmarklets (explained here) take a look at webgraphics' excellent favelets collection at the bottom of the right hand column of their front page."
162-0,"passage: CNET: Even though all the major browsers are considered to be up to snuff on standards compliance, some Web authors still find it easier to code directly to IE--and test only with IE--rather than to open standards. Tell us something we didn't know. Steve Champeon replies over at the Web Standards project and highlights some inaccuracies in the article but the basic message remains unfortunately true."
163-0,passage: Via techno weenie: A Python XML-RPC debugging proxy script. This solves the problem of XML-RPC errors from PHP being sent out with the XML-RPC response packet and breaking any XML parser trying to recieve the packet. Instead you can test your script by aiming at the proxy script which will dump any problems to the console for you.
164-0,"passage: Simple when you know how, a right PITA when you don't."
164-1,passage: scp -r blog/ username@www.wherever.com:/home/username/public_html/
164-2,passage: I'm slowly migrating this blog to another server (and rewriting it to use mySQL instead of serialized objects at the same time). After about half an hour of trying to figure out the best way of transferring the whole blog/ directory from this server to the new one without using FTP I figured out a way of doing it with scp (thanks to this tutorial):
165-0,passage: Webdocs.org is an online library of various freely available software documentation. The site uses frames with a tree style navigation menu on the left and loads (externally hosted) documentation on the right. At the moment they only cover Python but more will be added soon - in the meantime the Python collection is quite impressive.
166-0,passage: Mozilla oddity - if you rename a bookmark to the the same name as it's shortcut keyword the shortcut keyword will stop functioning. I couldn't see it in Bugzilla so I've submitted it as bug 156418.
167-0,passage: CherryPy is an interesting open source Python application server. Dynamic sites are constructed in a special templating language which is then compiled by CherryPy to create a stand alone executable Python script complete with a built in web server. This can then be deployed anywhere with a Python interpreter. CherryPy comes with an excellent tutorial and a small but useful set of HOWTOs.
168-0,"passage: PHP XML Classes - A collection of classes and resources to process XML using PHP. Includes PHP implementations of Xquery lite and RDQL along with parsers for RDF, RSS and RDDL."
169-0,passage: An excellent list of open source content management systems (via Webdesign-L).
170-0,passage: Logoed: logo inspiration for graphic designers. A large collection of real word logos to help kickstart the creative process.
171-0,"passage: Today's tip from Mark informs us that ""real"" lists are good for accessibility. They are also fantastic for writing maintainable code. Thanks to CSS, a humble unordered list can be transformed with custom bullet points, funky backgrounds, rollover effects and borders - all hidden away in the stylesheet leaving just basic list markup in the HTML. Adding a new item is as easy as <li>item</li>. W3Schools have a good CSS list reference complete with examples, and this earlier post on my blog lists some resources for dealing with unpredictable list margins."
172-0,"passage: Courtesy of css-discuss: Two examples of expanding boxes in CSS with images in the corners, ideal for that trendy rounded corner effect: One and Two. Mozilla has experimental support for rounded corners that may or may not end up in CSS3, but if it aint in the standards it aint coming in."
173-0,"passage: Mark says that today is the most important day of his whole accessibility series, and who are we to argue? The topic is the alt attribute for images, and the message is simple: Every image should have one, even if the image is there purely as layout decoration (in which case an empty attribute should be used). Surprisingly Mark does not give advice on chosing text for the attribute but he does provide an excellent further reading list, which includes Hixie's superb Mini FAQ About The Alternate Text Of Images."
174-0,"passage: xmlhack's ""Editor's Newswire"" is interesting. It is a small column (explained here) located on the right hand side of the site that displays the latest XML news snippets ""in real time"". The interesting part is how the section is updated - an IRC bot (The Daily Chump Bot, written in Python) monitors a channel for specific commands from authorised users, and produces an XML file of new snippets. Site updates through IRC (or instant messenging services such as MSN or Jabber) is a concept which we could see a lot more of, especially in this age of web services."
175-0,"passage: I just found a nice, clear and above all short explanation of the Semantic Web at The W3C's Technology & Society Domain page:"
175-1,"passage: The Semantic Web seeks to augment the current Web of linked documents with a Web of linked data. Today, Web users follow links from document to document in a largely manual process. Tomorrow, semantically-enabled links will enable both human users, and human users assisted by computers, to navigated these links and find the information they are looking for. [...] To reach its full potential, the Web must becomes a place where data can be shared and processed by automated tools as well as by people."
176-0,"passage: I've been experimenting with using CSS and <ol> tags to format code listings, complete with line numbering. Here's what I've got so far: Numbered Code Listing Experiment."
177-0,passage: The First Church of Pac-Man: Warning! Not a Religion - Do Not Worship.
178-0,"passage: Update: On second thoughts, if you have a blog - blog it. Enough blogger interest leads to mainstream media interest, and the more bad press this gets the better. Sites like this can not be allowed to go without comment, and the more comment the better. Let's humiliate these people in to never, ever creating something this bad again."
178-1,"passage: This site will make you cry: Connected Earth, BT's new million pound (yes that's £1,000,000) online museum devoted to the history of communications. It's so bad it isn't even funny - and don't even think about trying to visit without Flash (I did and was presented with an alternative interface consisting of a single select box that refused to respond to mouse clicks). Load up on IE5+ and Flash and you'll be treated to the single most unintuitive interface I have ever seen - good luck figuring out what the small, identical purple circles do. There are 2,000 pages of extensively researched content in there somewhere - obviously the designers thought it would be more ""sticky"" if you had to work really hard to find them. I could rant more, but quite frankly I just want to go to bed."
179-0,"passage: Connected Earth is getting a fair amount of criticism for its shoddy browser detection. In my opinion, browser detection is only a small part of its problems. Should you get past the front door the interface used to present information is ""mystery meat"" navigation at its very worst - identically coloured dots which reveal only a hint of their purpose when you hover over them, leading to pages that contain two or three paragraphs of information at the most before you have to click on another dot. Pages are slow to load even on broadband so trying to follow content quickly becomes a painful experience. There's a lot more to this dinosaur than just a browser detect page."
180-0,"passage: Mark Pilgrim continues to educate with day 24 of his series. Client side image maps need not pose a barrier to accessibility thanks to the helpful way in which alternative browsers use the alt attribute. They still aren't much use for people using a normal (non-lynx) browser with images turned off though, and server side image maps are a big no."
181-0,"passage: Here's a treat for anyone with a browser that supports alpha transparency in PNGs (Mozilla and IE5/Mac do, IE/Win doesn't). Click on one of the little magnifying glasses under a thumbnail and the skin in question will pop up as a floating PNG, which you can drag around the screen. Admire the drop shadows, translucency and general prettyness and ask yourself why Microsoft haven't implemented this X years after PNG became a standard. Hat tip to Boris Mann on thelist for the link."
182-0,passage: Bad faith is one of the three elements required in order for a domain to be transferred. The domain registrant intended to run a directory of Canadian businesses. Bad faith my arse! More info on ICANNWatch and Slashdot.
182-1,"passage: I find that the registration by the Respondent of record [...] four years subsequent to Complainant’s registration of its Canadian trademark, and almost 50 years subsequent to the Complainant’s first use of the mark constitutes bad faith."
182-2,"passage: This is ludicrous. NAF have ordered the transfer of the domain name canadian.biz to Molson beer, who hold a trademark on the word ""Canadian"" (a brand of beer):"
183-0,"passage: New article on Evolt: DVB-HTML a new standard?. The article describes DVB-HTML, a new standard being developed to allow the next wave of digital televisions to access internet content. The good news is that DVB-HTML complies with the W3C's XHTML modularisation requirement, and supports XHTML, CSS and the DOM. As I understand it, this means that if you author your pages in validated XHTML they will be ready for viewing on digital TVs. Web Standards at work."
184-0,"passage: Quiet blogging day today, but I've been busy behind the scenes. Firstly I've been playing around with TaviWiki (an excellent PHP Wiki engine), using it as a proof of concept for a Wiki-driven small website content management system. I've looked at several PHP Wiki's in the past and TaviWiki is the best by far, with rock solid features and a well organised code base. My only criticism is that the script relies on globals a bit too much, making it quite hard to figure out what is going on at times. I've also been working on IncDirectory, the open source sequel to my aging links directory script ssLinks. Add to that a new CSS experiment and preliminary work on rewriting this blog to use mySQL and today has been my most productive in quite some time."
185-0,"passage: This blog is one month old today :) According to my category statistics page I've posted 185 entries covering 23 different topics. Quite frankly, that statistic scares me..."
186-0,passage: Jordon Cooper on Blogroll Etiquette. I haven't made it on to many blog rolls yet but it's always nice to spot a new site in my referrals. The problem with having a blogroll powered by blo.gs is that you can only blogroll blogs that ping either blo.gs or weblogs.com. I have actually gone as far as emailing several bloggers who's blog I admire but am unable to link to due to their absence from these useful central repositories - the responses I've had have been positive so I'm hoping to add them again shortly.
187-0,"passage: Smarty at OSCON: Andrei Zmievski and Sterling Hughes will be presenting a tutorial titled ""Template Architectures with Smarty"" at the O'Reilly Open Source Convention in San Diego, July 22-26, 2002. Further details are available here. Smarty is a powerful template engine for PHP which combines a highly versatile templating language with excellent performance gained through template compilation."
188-0,"passage: Jonathan has insider knowledge that Mark will not be covering the longdesc attribute in his accessibility series. This it not because longdesc is not a useful accessibility tool, but simply because it does not fit the ""fire and forget"" nature of Mark's series. Jonathan's post discusses longdesc and the difficulties involved in adequately describing an image."
189-0,"passage: This is all about advocating web standards in a language that businesses understand. We have over a hundred members, a site, a Yahoo Group and a Wiki set up by yours truly. More on this as it develops."
189-1,passage: MACCAWS is a group of web professionals dedicated to:
190-0,"passage: Yesterday I set up a Wiki for Smarty as well. I like Wikis. The WikiEngine used for Smarty and MACCAWS is called TaviWiki, and is implemented in PHP with a MySQL back end. I had previously deployed PhikiWiki for a couple of university projects, which is good in that it is the only PHP Wiki I know of that works from the file system, but bad in that it has no support for version tracking (essential if your Wiki is accessible to the public)."
191-0,"passage: Why am I doing this? Because right now the web is such a freakin' mess with all of it's proprietary crap and browsers that don't adhere to standards. I know, my little meager site will not make any difference but that's okay. I'm the type of person that if I can't do something the right way then I'd prefer not to do it at all. Besides, the main reason I even have this site here is for the fun of learning and expanding. If I have to put a bunch of hacks and work around's in this site in order for it to look similar in all browsers in all platforms then it's not fun. Also, hacks, proprietary markup and nested tables is utter nonsense."
191-1,"passage: Lobowalk is a ""somewhat daily"" blog that has just made the transition to using CSS for layout. The decision to go CSS was accompanied by an excellent rant:"
191-2,passage: No permalink because none are available on the site.
192-0,"passage: The Minimalist Web Project is a collection of good looking web sites adhering to the minimalist style, based on the idea that ""less is more"". Some beautiful sites are listed, including 37signals' brand new CSS/XHTML design."
193-0,"passage: The Mozilla Web Author FAQ answers questions on doctypes, broken stylesheets, image table gaps and javascript detection - the most common problems faced by web developers new to developing for Mozilla all on one handy, concise page."
194-0,"passage: I never thought I'd say this, but there is a place on this earth for web site splash screens and time wasting intro animations (now I'm feeling dirty). This comes after an interesting if slightly heated debate about the merits of splash screens over on the SitePoint Forums. I still can't stand splash screens, but I can acknowledge that there are some web users who see the web primarily as an entertainment platform and have their surfing experience enhanced by a bit of glitzy animation along side their information. Thanks Bill Posters for helping me understand this bizzare side of the surfing demographic ;)"
195-0,passage: Oh wow. Which PowerPuff Girl is your blog?. I'm Blossom - yay! Thanks Mark-from-uni for the tip off :)
196-0,"passage: O'Reilly have a new article up entitled Ten MySQL Best Practises. Jeremy Zawodny has a few problems with the article, and Tony Bowden throws in some comments as well. There's plenty of useful information distributed between the three viewpoints."
197-0,"passage: Peter has upgraded his blog to the latest version of Moveable Type. As a result, his blog now pings weblogs.com via XML-RPC whenever he makes an update. blo.gs grabs the weblogs.com changes.xml file once an hour and uses it to generate a smaller file listing only sites on my blogroll. My site then grabs my personal favorites.xml file once an hour and uses it to render my blogroll ordered by the time each blog was updated."
197-1,passage: Isn't XML fun?
198-0,passage: 52 projects is just a project I've been wanting to do.
198-1,"passage: Hopefully these projects will give you a starting off point, or maybe some inspiration, perhaps a reminder of the thing that you've been wanting to do."
198-2,passage: 52 projects (via Peter):
199-0,passage: This is currently only an early proof of concept available as source code but it could turn in to something very cool indeed.
199-1,passage: Python in PHP (via HarryF on the SitePoint Forums):
199-2,"passage: As both a Python and PHP enthusiast, I wanted to bring these two systems together to promote even greater and more interesting development opportunities."
199-3,"passage: To that end, I've written a Python extension for PHP. In short, this extensions allows the Python interpretter to be embedded inside of PHP (think of PHP as the parent language with Python as its child). This allows native Python objects to be instantiated and manipulated from within PHP. There is also initial support for accessing PHP functions and data from within the embedded Python environment."
200-0,passage: Mark has out-done himself today with his long awaited coverage of relative font sizes. This is a notoriously tough topic (thanks to a whole bunch of strange CSS bugs and browser differences) but Mark carefully and comprehensively explains the various work arounds and CSS hacks needed to get the right effect with maximum accessibility.
201-0,"passage: A couple of Mozilla pieces, courtesty of Blogzilla. First up is the news that Dave Hyatt is leaving Netscape to work for Apple (Hixie mentioned this the other day). Blogzilla's jeffp wonders if this could mean the beginning of iBrowser, considering Dave's previous work on the Chimera browser which builds a Mac interface on top of Mozilla."
201-1,"passage: Blogzilla also report on a new proposed Mozilla feature entitled Incremental Find. This feature lets you type straight in to Mozilla and have the cursor jump to links matching what you type, allowing for lightning fast browsing via the keyboard. An XPI to install a preview of the feature can be downloaded from here."
202-0,"passage: I spent a while today over at Brent Ashley's blog chatting away on BlogChat. BlogChat is Brent's impressive DHTML chat system (backend in PHP, front end via JSRS) which allows anyone visiting his blog to talk to him (and other visitors) in real time, provided he is online to host the session. During the afternoon I got to talk to people from all over the world, all with similar interests because they all had the same taste in blogs. I am hoping to install a version of Brent's system on this site in the not-too-distant future."
203-0,passage: Joel on Software:
203-1,"passage: Software organizations tend to reward programmers who (a) write lots of code and (b) fix lots of bugs. The best way to get ahead in an organization like this is to check in lots of buggy code and fix it all, rather than taking the extra time to get it right in the first place."
204-0,"passage: In a discussion on css-discuss recently about underlines a on links, I pointed to kottke.org as an example of clever use of CSS for links where by the link underline is a slightly later colour than the link text. Today, Jason explains the technique and the thinking behind it."
205-0,passage: David Hyatt's neo-cortical implant is holding out just fine.
206-0,"passage: Handy software tip courtesy of Tim (my colleague at Incutio). EyeDropper is a tiny shareware program for Windows which adds a magnifying glass to your mouse pointer, displaying the hex colour code of the pixel under your mouse pointer. The download is a measily 27KB and it saves having to print screen and load up a graphics package just to find a HTML colour code. When not in use it sits in your systray."
207-0,"passage: Things I learnt today part one: Nested lists in XHTML are possible, but you can't just put a list inside another list. You have to nest the nested list in a list item. References: W3Schools XHTML differences and the www-html mailing list."
208-0,passage: An interesting discussion (scroll to the bottom).
209-0,"passage: Things I learnt today part two: The <link> tag is fun. I've been building support for it in to IncDirectory (not long now) - it took a while to find the necessary background information but Mark Pilgrim, www-html, and the W3C gave me everything I needed."
210-0,"passage: Chris Smith has an interesting set of CSS demos, including some attractive CSS buttons and an excellent example of a more complex layout. There's a lot of interesting creative work going on with CSS at the moment as more developers start exploring the possibilities it brings - Eric Meyer's css/edge is just the tip of the iceberg."
211-0,"passage: Mark's latest accessibility tip concerns header tags (<h1> through <h6>). Mark explains that using headers in the right order helps screen readers to interpret the structure of your pages, and shows how to use CSS to effectively style headers. Mark once again demonstrates the comment hack as a way of bringing Netscape 4 in line with other browsers, a technique that has been criticised by the More Like This Weblog as unnecessary encouragement for NS4 users. Incidentally, Johannes Koch has an excellent summary of CSS hiding techniques."
212-0,passage: Dashes and hyphens in HTML.
213-0,"passage: Stuart Langridge discusses the nature of minimalism and CSS design, following a post by Sarabian. Stuart wonders if the current trend for relatively plain site designs is an interim period while we find our feet in the relatively new medium of CSS. I am sure it is - while I personally love the elegance and simplicity being showcase in many pure CSS sites, it's not going to help convert die hard table fanatics. The annoying thing is that CSS is capable of so much - the power it gives us over background images should free designers to do things that were difficult or impossible with tables. I'm a rubbish designer, but I'm considering taking on the challenge of ""interesting"" CSS design in the not too distant future. If I can make things look good, anyone can ;)"
214-0,"passage: Burningbird has hung up her wings. Dorothea thoughtfully blogs her departure, disagreeing with her suggestion that blogged content suffers from a lack of permanence. One of the reasons I blog is that I hope to increase my skill with the written word, so it is interesting to see someone at the opposite end of the spectrum who feels they must stop blogging to keep writing. As for permenance, I have often worried that particularly valuable articles can get lost in archives - to this end I hope to implement a permanent feature archive in my blog redesign, somewhere I can keep larger articles in a more easily surfed format than an archive."
215-0,"passage: Amazon have launched a brand new web service interface to their huge database of products. I've been playing around with it, and I've knocked together a simple search engine example in PHP, with the code available for anyone who wants it. I did a similar thing a few months ago when Google released their Web API so we've set up a new site at Incutio to host these and other open source projects - scripts.incutio.com. The site is only a few hours old and we'd love some feedback - contact us directly or add a comment to this entry."
216-0,"passage: There's plenty of activity surrounding Amazon web services today. My limited demo barely scratches the surface of the possibilities - people are already experimenting with Amazon's similarity search and Mark Pilgrim has released PyAmazon, a Python wrapper for the Amazon API. I've started listing alternative implementations on the PHP Amazon Search page, and I'll be sure to blog the more innovative examples as and when I find them."
217-0,"passage: I've updated PHP Amazon Search to implement a few more search methods, and altered the example script to allow searches for related items."
218-0,"passage: Small Values of Cool - links to things that I find interesting by Simon Brunning. I turns out I find them interesting as well. Lots of Python stuff on there at the moment, including a link to the new Python Wiki."
219-0,"passage: Moment of realisation: I just figured out what it is about Flash that bugs me so much. Flash is rubbish at text. Sure it can render text in pretty ways, but it never feels like real words. Flash takes good old fashioned text and locks it away in a pretty but shallow world, one that is out of reach of search engines, screen readers and my all important right mouse button. What good is text is text if I can't search it, select it, copy it, paste it and generally processs it in whatever way I see fit? Flash is fine for graphics, animation and even some user interfaces (provided they don't involve too much text) but please, please keep it away from anything I want to read."
220-0,"passage: Tip off for Stuart: The new Python Wiki includes an index of available web frameworks, but there's no mention of Castalian yet."
221-0,"passage: If you're still struggling to get to grips with CSS layout techniques (heaven knows I am) Dorothea's latest will teach you more in a single post than many lengthy tutorials do in their entirety. Floats for layout (as seen on this site) are out - they work for small areas but anything larger can cause performance problems and other unpleasantness. Relative positioning is unreliable, which leaves us with absolute positioning and clever use of margins, along with intelligent use of background images for decoration. Dorothea explains these techniques in concise detail, and relates them to AKMA's redesign."
222-0,"passage: No updates until Monday - I'm taking a long, offline weekend with my girlfriend."
223-0,"passage: I had a great weekend, and now it's catch-up time. I've managed to find 15 things from the weekend that I want to blog so I'll try and spread them out over the next day or so."
224-0,"passage: Ogg Vorbis has hit 1.0. Ogg Vorbis is an open, patent-free alternative format to MP3 that boasts some seriously impressive abilities. A sample page is available which includes WAV files to allow quality comparisons between different formats."
225-0,passage: Vulnerability found in PHP 4.2.0 and 4.2.1 involving HTTP POST requests. The PHP group have released PHP 4.2.2 which fixes this problem.
226-0,passage: I've placed an order on Amazon for both Cascading Stylesheets: Seperating Content from Presentation and Eric Meyer on CSS. I'll probably post a side-by-side comparison of the two books in a few weeks time.
227-0,"passage: Mark Pilgrim's accessibility series has come to an end, and he has compiled the whole lot in to a fantastic new resource: Dive Into Accessibility. This is going to be required reading for anyone with a conscience and a weblog (or any other kind of site) for years to come. I've fallen a bit behind on implementing Mark's accessibility tips but I am set on using them on this site soon (probably along with the new design) and applying them to any sites I develop in the future. Thanks Mark."
228-0,"passage: Floats, an alternative perspective. A useful overview of how CSS floats should work based on the specification."
229-0,"passage: Patrick O'Brien: Building GUI Applications with PythonCard and PyCrust. I'm a big fan of PythonCard, an excellent toolkit for creating GUI applications in Python that seperates the GUI layout from the program logic and makes it ridiculously easy to put together a basic GUI in a short space of time. Patrick is the developer of PyCrust, an interactive shell for debugging and interacting with GUI components, and is also a contributor to PythonCard as a whole. Patrick and Kevin Altis, the lead developer of PythonCard, will be presenting a session on PythonCard at OSCON on Thursday."
230-0,"passage: The reason that we use XML instead of a specific application is that XML is not just a pretty face, living in isolation from the rest of the computing world. XML is more than a rulebook for generating custom markup languages. It is part of a family of technologies, which, working together, make your XML-based documents very useful indeed."
230-1,passage: Using XML on A List Apart:
231-0,"passage: Fantastic news for the web standards movement: Lycos Europe goes XHTML and CSS for layout (via Zeldman and the W3C evangelism mailing list). The new layout can be seen here - at the time of writing it had a few validation errors but hopefully they will be fixed before launch. The one thing CSS positioning advocates really need is a ""big"" site to start using CSS for layout, and it looks like Lycos are going to provide just that."
232-0,passage: Craig Saila's Web Building Tips include all kinds of frequently asked but infrequently answered questions relating to various areas (mostly client side) of web design and development. The rest of the site is full of quality content along similar lines and is well worth exploring.
233-0,"passage: IBM's Accessibility Center has a plethora of useful information and resources, including a free 30 day trial of their Home Page Reader text-to-speech browser software."
234-0,passage: Mark Swanborough (a friend from Uni) now has a blog. He's getting hooked already.
234-1,"passage: Since he asked, my results for the first year came through the other day and I scored a respectable 75% average. Roll on year 2 ;)"
235-0,"passage: I've seen a few questions on various forums and mailing lists asking if there is a way of using target=""blank"" on links in XHTML Strict without running in to a validation error. I've put together an example page showing a method of fixing this using the DOM, which also demonstrates Andrew Clover's fun-but-ugly Evil Mangled Comments Hack."
236-0,"passage: Sounds like Google and DMOZ doesn't it? Sure enough, the directory pages carry a standard Open Directory footer. The only indication of what is powering the search engine is a Fast logo, which suggest that Excite UK have gone with AllTheWeb rather than Google for their back end."
236-1,"passage: We are back - and we have created the most complete search channel on the web for you. Take advantage of our collection of 2,100,000,000 web sites and the world's largest man-made directory!"
236-2,passage: The Register: Tiscali to launch Excite across Europe. From Excite.co.uk:
237-0,"passage: Apple's Aqua Human Interface Guidelines (via a link on the Pinstripe Theme for Mozilla page). Interesting reading, and an excuse for a new category. I'm doing a course on HCI next term so I imagine I'll be blogging a fair amount of related information in the future."
238-0,"passage: Thanks to these shortcuts I can hit CTRL+R, type one of those browser names, paste in a URL and hit enter to instantly load that page - fantastic for quickly seeing how a site looks in a different browser."
238-1,"passage: I have Mozilla, Netscape 4, Internet Explorer and Opera installed on my Windows PC. I use Mozilla for browsing and the other three for testing. It turns out that all four browsers can be loaded with a specific URL from the command prompt like this:"
239-0,"passage: Paul Freeman has come up with new use for the Google API - generating random links. The idea is simple but effective - a random theme is selected and searched for (via pygoogle), then another search is run on the title of one of the top ten results to return a random link and description."
240-0,"passage: I'm not sure how this one snuck under the radar, but PHP now supports object overloading (as of version 4.2.0). It can be implemented by creating class methods __set(), __get() and __call() and then applying the new overload() function to the class name. The documentation claims that __call() is not yet supported but is apparently out of date. Standard warnings about the experimental and unfrozen nature of the extension apply."
241-0,passage: XML-RPC Class Server is a really clever piece of code. It consists of a single file which you can drop in a directory full of PHP .class.php files to instantly provide an XML-RPC interface to every class in the directory. Private methods that begin with an underscore are not included in the web service. Unfortunately the system requires PHP's XML-RPC extensions to be enabled.
242-0,passage: Adding SSL support to Python on Windows is as easy as dropping a couple of DLLs and a .pyd file in to your Python DLLs directory. Grab the zip file from this page and off you go. I haven't tried it out yet but it appears to work - the socket.ssl function miraculously appeared when I installed the new files. Why is this useful? Because it opens the way for secure XML-RPC calls from Python applications...
243-0,"passage: I've been trying to get my head around Topic Maps, a powerful but complex standard for building intricate networks of metadata. I couldn't even begin to describe them myself but the following resources have proved very useful:"
244-0,"passage: Update: I was wrong - they do have a webmaster contact form. You click the ""contact us"" image, select ""have a question for our international team? email us"" and select ""webmaster"" from the bottom of the list of topics. It's a shame the contact button is one of the things that's broken in Mozilla, but at least it's there (albeit very well hidden)."
244-1,"passage: Why is it that badly designed high profile sites that completely fall apart in Mozilla never have a ""contact our web team"" or ""send us feedback"" link anywhere? You would expect better from a company that provides web technology and customer management consultancy services (well if you're a cynic like me you wouldn't, but that's beside the point)."
245-0,"passage: From the stuff-I-never-knew department: Bill Posters explains how browsers load images simultaneously on the SitePoint forums, in response to a question about getting images to load in a specific order."
246-0,"passage: php, mysql, bath, web development, information architecture, css, html, xhtml, accessibility, programming, mozilla, python, xml, web services, content management"
246-1,"passage: Blog Hot or Not. I'm surprised no one had thought of this before - it's clever idea, well implemented. When adding my own blog I was asked to come up with some keywords to describe it, so here they are for posterity and my own future reference:"
247-0,"passage: A member of KPMG's web team responded to my query about Mozilla support (sent via their online contact form using IE because the site was unusable in Mozilla) and informed me that a new site is on the way. You never know, they might even embrace web standards ;)"
248-0,"passage: I've been working on a PHP application that can take an XTM formatted Topic Map and convert it in to relational data in MySQL, run queries on it and convert it back to an XTM later. My work on the initial parser has involved some pretty heavy duty processing, and the speed with which PHP and MySQL are handling the data I'm throwing at them is phenomenal. The classic Italian Opera Topic Map example weighs in over a megabyte of XML, but PHP is munching it up and spitting out (and executing) over 13,000 SQL queries in less than seven seconds."
249-0,"passage: Via Kottke: True Porn Clerk Stories, a hilarious, touching and insightful journal of the trials and tribulations of a female Porn video store clerk in Chicago. This is some of the best and most original writing I've seen on the web in a long time. It is also quickly turning in to something of a meme. When you've finished reading the journal, be sure to have a look around the rest of the site it is hosted on - the community there is undergoing something of a trial by fire, with over 180,000 reads of the Porn Clerk journal resulting in massively increased traffic and a flood of new members that threatens the stability of the existing community. They have even had to open a PayPal scheme to help cover the dramatic increases in bandwidth ($15/month is now up to $25/day)."
250-0,"passage: I've long been wondering what kind of research Google are doing with respect to the Semantic Web. August 2009: How Google beat Amazon and Ebay to the Semantic Web (via From the Orient) is a superbly written essay which explains the concepts behind the Semantic Web through a ""history"" of how Google has become the world's largest marketplace by the year 2009. Stuart has written his own essay discussing some of the issues raised by the piece, such as security and classification problems."
251-0,passage: Browser Specifications:
251-1,"passage: This document attempts to explain why forward-compatibility matters, and why we, and our clients, should carefully consider the browser specifications of every project. "
252-0,passage: Stanford Guidelines for Web Credibility:
253-0,"passage: I've had my application for editorship of the DMOZ University of Bath Category accepted. Bath's main site has notoriously bad navigation, so hopefully I'll be able to use DMOZ to build an alternative. I'm also looking in to eventually syndicating the DMOZ category via RDF and replicating it elsewhere. Unfortunately it looks like you have to grab the whole 130MB RDF file to do this, but I've seen tools that syndicate smaller portions of DMOZ so it must be possible to extract only the information you are interested in."
254-0,"passage: Having looked at some of these tools for syndicating content from the ODP, it seems that the standard method is to grab and parse the actual HTML files from the site rather than grabbing the huge RDF files. This would be a lot easier if the pages of the site were valid XHTML, but unfortunately they don't even have a DOCTYPE. Luckily I wrote a page-link parser the other day for something else which seems to do a pretty good job on the ODP, so I should be able to put together a decent script without too much trouble."
255-0,"passage: And suddenly I understand faceted metadata. Sometimes all you need for that final moment of insight is a good example, and Peter Van Djick's Columbia Guide Site Map is just what I needed. A facet is simply a ""flat"", mutually exclusive (at least as far as the XFML specification is concerned) way of categorising a topic - it can be described as a bottom-up method of categorisation rather than the more common hierarchical top-down approach (as seen on the ODP) which seeks to assign all topics as sub-topics of something else. Peter writes in XFML Background and Concepts that Faceted taxonomies are generally more powerful for websites than classic hierarchical taxonomies - this seems to make a great deal of sense, and it will be interesting to see this demonstrated by XFML in the near future."
255-1,"passage: Update: Incidentally, IAWiki have an excellent page describing FacetedClassification."
256-0,"passage: Red Herring: Dinner with the mind behind the mind of God, an informal interview with Sergey Brin, cofounder of Google. The ""mind of God"" reference stems from this quote:"
256-1,"passage: But in the end, the conversation returned to search. What would a perfect search engine look like? we asked. ""It would be the mind of God. Larry [Page] says it would know exactly what you want and give you back exactly what you need."""
257-0,"passage: Yet another interesting take on XML metadata representations: FacetMaps. A facet map (as I understand it) is a way of combining facets with hierarchies, best explained by the excellent interactive three minute concept intro on the site. One of the main contrasts to XFML is that in a Facet Map Facets, rather than Topics, are the principle categorisation element. A resource in a Facet Map is linked directly to one or more facets, rather than going through a topic. The XML format is pretty simple (a lot simpler than XTM and XFML) so I might have a go at a PHP implementation at some point."
258-0,"passage: How to Think Like a Computer Scientist: Learning with Python is a new Python text book covered by the GNU Free Documentation License and available on the web. The thread discussing it on Slashdot gives mixed reviews, with other recommended free alternatives including Mark Pilgrim's Dive Into Python and Thinking in Python by Bruce Eckel."
259-0,"passage: The ODP require you to display an attribution on any page that reuses ODP data. The recommended attribution fails to validate as XHTML, so I created an XHTML compliant alternative which looks visually identical (at least in standards compliant browsers) but uses <div>s with CSS styles. ODP editor in chief rdkeating25 has informally approved my alternative version on the ODP editor forums so I'm ready to go - at least as soon as I finish writing a script to parse data from their pages ;)"
260-0,"passage: Mark Pilgrim has made his first update since finishing his accessibility series a week ago. He has launched a new site design (as previewed on css-discuss) in an attractive shade of blue, and posted a catch up of the many events that took place over the weeks that his blog was devoted to accessibility. My favourite quote:"
260-1,"passage: Netscape 4 turned 5. 5 years ago, my best friend wasn't even dating; now he's married and has two kids. Fucking upgrade already."
261-0,"passage: Tim Luoma on thelist poined out this table, which details the media types that can be used when serving XHTML documents. The table shows that XHTML 1.1 should not be served with a text/html Content-Type header. Unfortunately using any of the allowed headers (application/xhtml+xml, application/xml or text/xml) will cause Netscape 4 to pop up a ""download file"" dialog, and is likely to cause problems in other older browsers as well. Looks like I'll be sticking with XHTML 1.0 Strict for a good while to come. I don't really understand the hurry to move to XHTML 1.1 exhibited by some developers - to my mind, the single biggest advantage of XHTML is the fact that it allows documents to be parsed by any XML parsing tool, and this benefit is available in XHTML 1.0."
262-0,"passage: Peter Van Dijck has unveiled the Secret Metadata Project (here and here), so I hguess it's time for me to come clean as well :) I'm working with him on a proof-of-concept PHP application for XFML, his markup language for exchanging faceted metadata. So far I'm really enjoying the challenge - I get to play with XML and collaborate on an exciting new project with an extremely talented information architect. The application is shaping up at an impressive rate, and we hope to have something live and doing things within a couple of weeks."
263-0,"passage: A thread on SitePoint got me thinking about how PHP's little known parse_ini_file() function could be used to easily manage multiple language versions of web site messages. Sections could be set up for each supported language, with message definitions repeated in each section. You could even have a default message section at the top which is used when a message has not been defined for a particular language. The comments on the parse_ini_file manual page suggest that the function is not particularly suitable for large scale use - PHP exits if the ini file is malformed and it can't handle files larger than 16,382 bytes. That said, rolling a more reliable native PHP version should be a trivial project."
264-0,"passage: Dave observes that Opera have added this dual-behaviour to Opera 6, following on from Mozilla's lead. On a related note, I am currently using a dual head graphics card with two monitors hooked up to my machine. This allows me to have a Mozilla instance (with tabs) running on both monitors at once. Lovely :)"
264-1,"passage: Tabs are not a replacement for window management. They are an enhancement that can be used in conjunction with the window manager of your operating system to group thematically related content in separate windows. Different topics can be kept in different windows, and then within a window you can have any number of pages open that are all topically linked. This is much more powerful than MDI, as it isn't about replacing your window manager or keeping you inside a single browser window."
264-2,passage: Dave Hyatt explains why Mozilla's tabbed browsing is different to (and better than) Opera's MDI model:
265-0,"passage: Stuart has updated aqTree, his excellent unordered-list-to-dynamic-tree script. The script is a clever piece of Javascript that uses the DOM to turn a nested unordered list in to a Windows Explorer style tree, without needing to add any extra HTML code. The new version is rather nice and less crufty now."
266-0,"passage: I've never used MS Access for anything web related, and I certainly don't intend to at any point in the future. however, I do see a lot of questions regarding Access on various forums and mailing lists. Nine Reasons NOT To Use MS Access To Power A DB-Driven Website (published 29th June 2002) is an excellent article explaining exactly why using Access on the web is a really bad idea."
267-0,"passage: Killer CSS link: Position Is Everything, part of the CSS bug ring. Big John on CSS-Discuss is probably the single most helpful individual I have ever encountered on a mailing list - he explains the most complicated (and simple) of solutions quickly, comprehensibly and in easy to understand terms. Position Is Everything is his collection of common but complex CSS browser bugs, complete with full explanations and any effective workarounds. The site links in to the CSS bug ring, a small ring of five sites providing more of the same. Truly an indespensable resource for anyone with an interest in CSS."
268-0,passage: Wow.
269-0,"passage: Point. Click. Think? (via from the orient). This is an interesting, well written piece on the effect that the web is having on student learning and research habits. Looking back at my first year at Uni I am probably a text book example of the symptoms the article describes - I hardly ventured in to the library at all, getting most of my additional course information from the web. Then again a Computer Science degree is probably better suited to web research than many other courses."
270-0,"passage: Since it took me a while to find this page today, here is it for future reference. Westciv's Guide to CSS Selectors is an excellent explanation of selectors, a key element of CSS. A good understanding selectors makes styling any part of a document possible with less code and more flexibility."
271-0,"passage: There's a great discussion going on at the heart of things concerning different styles of blogging and the way the format is evolving. The range of formats evident across the blogosphere fascinates me - there are as many different styles as there are blogs, and each blogger's style is constantly evolving. Personally I want to move towards more of a unique-content-generation model (as opposed to my current link farm) but at the same time my experiments with meta data mean that the more ""shallow"" content I have the more chance I will get to do interesting things with relationships between entries."
272-0,"passage: Today's scary discovery: MySQL TEXT fields have a limit of 65,000 bytes. If you insert anything larger than that in to a normal TEXT field mySQL will silently truncate your data without telling you (meaning software checks are probably a good idea). MEDIUMTEXT will store 16 million characters and LONGTEXT can handle over 4 trillion, but this information does not appear to be readily available in the online mySQL manual (although it is hinted at in this table). Something to bare in mind when designing database applications."
273-0,"passage: I've been messing around with CSS today, trying to convert this page to use standards compliant CSS and XHTML while keeping the overall look and feel. My efforts so far can be seen here - I've knocked the HTML file size down from 27KB to 7KB (although that doesn't take the new external CSS file in to account) and it seems to work in Opera, Mozilla and IE on Windows. There is a slight issue at 800x600 (the breadcrumbs dissapear) and it looks terminally boring in Netscape 4 but on the whole it's come out pretty well."
274-0,passage: placenamehere.com: Chris Casciano's Digital Playground. I love this design - Chris uses beautiful black and white photos for page backgrounds and carefully positions the main navigational element on each page to fit in with the background image. This is a great example of the new design techniques being made possible by a combination of CSS and creative talent. I just wish I had some of the latter :)
275-0,"passage: It's the first day of the month. I don't believe in rabbits, but I do believe in Mailman - I just had my fourth ""monthly reminder"" email of the day. It beats me why the lists I am subscribed to see fit to email me once a month to remind me of my description - you would have thought the dozens of emails I get from them every day would be enough of a hint. In my opinion this is one default option the web could do without."
276-0,"passage: CETIS is the Centre for Education Technology Interoperability Standards. Their site is regularly updated and contains a wealth of information about a whole range of interesting technologies, including metadata standards and plenty of stuff on web services and XML. It also acts as an interesting insight in to technology plans within the UK's academic community."
277-0,"passage: Real World Style: These techniques work. I know, because I use them every day in my real world job. Mark Newhouse provides a whole site dedicated to CSS tips, tricks and full blown public domain layouts specifically designed to work with Netscape 4 (and Unix machines). This is an invaluable resource for web developers who want to start using modern techniques but still have to cater for an audience with troublesome browser preferences."
278-0,passage: My Amazon order has arrived.
279-0,"passage: Harry Fuecks on SitePoint: Harness the Power of CVS for Your Site. I've been wanting to get in to CVS for quite a while but I've been put off by the lack of a good ""getting started"" guide. Harry's tutorial is everything I've been looking for - it explains concepts and terminology, describes when you would want to use CVS and shows exactly how to use it on a Windows machine."
280-0,"passage: Confused about the difference between W3C Notes, Working Drafts, Candidate Recommendations, Public Recommendations and normal Recommendations? So was I, until I found this handy list of definitions on the official site."
281-0,"passage: I hate to be mysterious, but I have two very exciting projects in the pipe line. I don't even know yet if they will make it to production, but if they do they could be very cool indeed."
282-0,"passage: The Register: approximately 25 per cent of readers access our site using non-Microsoft browsers (mentioned in passing in an article on Alexa). Now for some pure speculation. I can't imagine that this percentage was nearly as impressive 6 to 8 months ago, simply because 6 to 8 months ago there weren't really that many serious alternatives to IE - Mozilla was still in beta and most of the other Gecko engine browsers were still pretty shakey. With Mozilla past 1.0 and some great Gecko browsers being built on top of it (Chimera at al) IE is no longer necessarily the best choice. I just wish I had access to some 'real' statistics to further understand the ways in which the browser market is changing."
283-0,passage: Slow blogging day today - I've been hit by a round of Aquarionics Syndrome ;)
284-0,"passage: I'm slowly working my way through both Eric Meyer on CSS and CSS: Separating Content From Presentation. Initial impressions are that they were well worth the money - the two books complement each other very well indeed. Separating Content from Presentation (SCfP from now on) seems to be the more technical of the two - it provides excellent descriptions of the intricacies of the CSS specification and has some superb information on browser differences, with some good advice for web developers who need their sites to look reasonable in Netscape 4. Eric's book is more flamboyant, with full colour pages and a ""project"" formula that introduces CSS techniques through a variety of interesting case studies. Full reviews can wait until I have finished reading the two books."
285-0,passage: Congratulations Stuart on getting slashdotted. How's the server holding out?
286-0,"passage: Take a look at this page in Mozilla, view the source code and ask yourself ""how on earth did he do that?"". It appears to involve very creative use of borders, possibly relating to the fact that a single border in CSS (at least in Mozilla and presumably in IE5/Mac as well) is actually a trapezium, not a line. Tantek Çelik was the project lead for IE 5 for the Mac (and the creator of both the Box Model hack and the High Pass Filter) so general CSS wizardry is to be expected."
287-0,passage: text-decoration: blink spotted in the wild!. Seeing as Hixie so eloquently argued for its inclusion in Mozilla in the first place it's nice to see this most vital of CSS properties being put to some use.
288-0,"passage: The W3C have published a working draught of XHTML 2.0. Since the Changes from XHTML 1.1 pages doesn't appear to have been written yet, here are a few of the most notable differences I've spotted so far:"
288-1,passage: Unfortunately with the amount of time it takes for browser manufacturers to implement even simple specifications it could be years before we can start using these improvements.
289-0,"passage: <xterm> The problem with America is stupidity. I'm not saying there should be a capital punishment for stupidity, but why don't we just take the safety labels off of everything and let the problem solve itself?"
289-1,passage: A fundamental law of the internet is that no IRC quote is ever funny when posted on a web site. The QDB Top 50 Quotes (via Ordinary Life) must by the exception that proves the rule:
290-0,"passage: The new working draft is currently being discussed on www-html, a relatively low traffic mailing list hosted by the W3C."
290-1,"passage: A few more notes on XHTML 2.0. Tom Gilder (who incidentally has written an excellent series of tips on accessible scripting) has pointed out that the <dfn> tag is part of HTML4 and corrected my spelling of draft as well :) Meanwhile, a post by Shane P. McCarron to XHTML-L has highlighted a few more interesting points - <applet> is out (in favour of <object>, XMLEvents are in to replace the current event model and the href attribute can now be used on pretty much anything to turn it in to a link. Strangely XLink is not mentioned in the specification."
291-0,"passage: Two more interesting CSS demonstrations - Bullet proof rounded corners and Breadcrumb nested lists. The rounded corners technique is very impressive - it solves a common CSS problem in a way that is durable, cross browser and, well, bullet proof. However, as Mark Pilgrim points out:"
291-1,"passage: Mark Newhouse's breadcrumb demo takes the opposite aproach, taking a semantically correct nested list approach to marking up breadcrumbs, then using CSS to style them as a single line. Eric Meyer sums up the reason such experiments are important very nicely on cs-discuss:"
291-2,"passage: Every time we play with CSS, we're learning something-- whether it's new ways to use CSS effectively, or the limits of what we're willing to do with CSS, or areas for future expansion of CSS itself, or something else entirely."
291-3,"passage: Apparently we've traded a big stinking pile of table tricks for a big stinking pile of CSS tricks. It's not more semantically pure, it's not more accessible, it's not easier to maintain. Why is this progress?"
292-0,"passage: Sjoerd Visscher has published an XHTML 2.0 page that works in IE6, Mozilla and Opera, complete with support for navigation lists and href attributes on multiple elements. The implementation is very clever - it uses IE behaviors, Mozilla XBL files and Opera's proprietary link CSS properties to get all three browsers to play nicely (be sure to check out the style sheet). A custom DOCTYPE at the top of the page adds DTD descriptions of the new XHTML 2.0 elements used in the document."
293-0,"passage: I think I've kept quiet for long enough, so here are some details of the two projects I have alluded to. The first is a database driven mailing list archive for css-discuss. It has just gone in to private beta, so anyone subscribed to the css-discuss list should have an email with the URL, username and password requried to try it out. It has a pretty usable search engine and does some nice threaded views in messages - more importantly, it now contains all 9,000+ messages sent to css-discuss since it launched back in January 2002 (imported from the static Mailman archives). I've spent many hours surfing through the archives already and they are a wealth of useful CSS information."
293-1,"passage: Project two is again related to css-discuss. I've been setting up a Wiki, which is currently being tweaked and poked and made ready for the general public. More on that when it launches."
294-0,"passage: Smarty 2.3.0 is out, and includes a useful new debugging function and support for assigning template variables by reference. I get a mention in the CHANGELOG for a small bug fix I submitted. Open source at work."
295-0,"passage: PHP Tip: You can access characters within a PHP string using the index of the caracter in curly braces after the variable name. For example, $string{0} returns the first character, $string{3} returns the fourth character and $string{strlen($string)-1} returns the last character. You can assign to individual characters of a string in the same way, so $string{0} = strtoupper($string{0}); will convert the first character of a string to upper case. For more tips on working with strings see the PHP manual and Zend's useful strings tutorial."
296-0,"passage: Edible.com are a small company based in London that aim to bring you an Adventure in Eating from around the World!. Which means scorpion lollipops, milk chocolate covered ants and pickled rattlesnakes in a tin (a bargain at £16.50). I'm actually quite tempted to grab some Toffee Scorpions, if only to terrorise my friends at university..."
297-0,"passage: I spotted Mike Pletch in my referrals this morning. His blog has a clean, readable design and some great content, particularly if you are interested in information architecture and content management. Via Mike I revisited Column Two which is currently documenting an implementation of a full content management system for a client - well worth a read."
299-0,passage: Update: I should have checked the date on his entry before I posted - this is from way back in December 2001
299-1,"passage: While upgrading to XHTML may have few immediate benefits, the ease with which it can be parsed has very real benefits further down the line. Writing content in XHTML now will make it much easier to re-use that content in the future."
299-2,"passage: Phil Ringnalda is questioning the point of XHTML. The single, huge advantage it has over HTML is that XHTML can be parsed by anything (or any language) with an XML parser. As an example, a few weeks ago I was asked to write a script to grab links from a bunch of HTML pages and insert them in to a database. I solved the problem with a combination of PHP's strip_tags() function and XML parsing abilities, by killing off every tag that wasn't an <a> tag and slapping on a start and end element to turn the document in to valid XML - a step that would not have been necessary had the page used XHTML in the first place."
300-0,"passage: Some thoughts on blogging etiquette. With anything like this I have a policy of always linking to the blog entry that pointed me to the site in question (if I found it via someone else's blog). The exception to this rule is when I've seen it on several blogs, as is the case with this item which I've spotted on Caveat Lector, More Like This and BoingBoing. My reasoning is that whenever something gets linked this heavily it's aproaching meme status, so who linked it first becomes something of a moot point."
300-1,passage: This one's for Paul from Uni: Tales of the Plush Cthulhu
301-0,"passage: Glen Murphy has released the source code to his innovative dChat PHP/DHTML chat system. I've been playing around with it this morning and it's a very nice piece of software. dChat uses an interesting take on the remote scripting concept, using the DOM to append <script> elements to the head of the document in order to grab additional information from the server without refreshing the page. Unfortunately this technique does not work in IE on the Mac, but it works fine on Mozilla and IE/Windows."
302-0,"passage: After a successful private beta, the new searchable css-discuss archive is ready for use by the general public. If you spot any bugs or have any suggestions for improving the archive please drop me a line."
302-1,"passage: The archive includes all messages sent to the css-discuss mailing list since the list started back in January, and should be of great interest to anyone with an interest in CSS. The archive software is written in PHP and uses mySQL for storage."
303-0,"passage: Jeffrey Zeldman: ""99 percent of Web sites are obsolete"". An excellent interview covering web standards and the new techniques they encourage."
304-0,passage: A thread on SitePoint lead me to these two excellent tutorials: Javascript Optimisation and Tackling JavaScript strict warnings.
305-0,"passage: Spotted in my referrals: tidak ada, a beautifully designed blog covering web development and other related topics. This is another great example of what you can achieve with some creative CSS."
306-0,"passage: SitePoint are trialling a new design for their front page. For fun, I had a go at recreating the new design using structural XHTML and CSS. The result isn't my normal style (I normally avoid fixed pixel font sizes and go for liquid rather than fixed width layouts) but replicates the existing design nicely and looks good in IE 5/6, Mozilla and Opera 6 on Windows. Netscape 4 doesn't get the stylesheet and I have yet to try it out on a mac."
307-0,"passage: Christina Wodtke: Mind your phraseology!, a tutorial on controlled vocabularies. The concept is very similar to that used by TopicMaps - relationships are defined between terms that take in to account hierarchies, associated terms and even alternative spellings. I'm planning an overhaul of the category / metadata system used on this blog in the near future and Christina's tutorial has given me a whole load of new ideas."
308-0,"passage: My friend Tim recently received a spam from a company called TrafficBBS, who specialise in bulk submissions to 50,000 search engines and 120,000+ BBS (web based bulletin boards). A quick look at their list of targetted forums reveals that they are spidering and spamming a whole bunch of simple web based forum scripts that don't require user authentication, such as WWWBoard. This is a form of spam I wasn't aware of until now. It's scary to think how easily the system could be expanded to automatically register on more advanced widespread forum systems such as vBulletin."
308-1,"passage: Incidentally, their crawler (or one of them) identifies itself as PHP/4.2.1 and uses the IP address 211.101.236.142."
309-0,"passage: AlltheWeb.com introduced an innovative feature called Alchemist a while ago which allows visitors to customise the site by specifying the URL to their own style sheet. They have now announced a CSS design contest for the service, with top prizes of $750 in Amazon vouchers available for three categories (""Simple, Yet Beautiful"", ""To CSS Infinity and Beyond"" and ""So 22nd Century""). This is a great oportunity for advocates of CSS to show just how powerful it really is."
310-0,passage: Mark Pilgrim explains why the <q> tag is bad for accessibility.
311-0,"passage: MP3 Piranha is a clever application which indexes your MP3 collection and uses the Amazon Web Service API to look up the album cover, related albums and provide a link to buy the album from Amazon. Out of curiosity, I ran a search for a PHP library to decode ID3 tags to see if such a thing could be built with PHP, and came up with this script by Leknor. The class is well written and I learnt a lot about ID3 tags looking through it - it seems they take up the last 128 bytes of an MP3 file and can be decoded using PHP's unpack() function."
312-0,passage: Stuart has pointed out that this is the second time Jeffrey Zeldman (who is actually Eric Meyer) has spelt my name wrong :)
313-0,passage: The Free On-Line Dictionary of Computing does exactly what it says on the tin. It is available under the GNU Free Documentation License so I grabbed a copy of the archive (which expands to a 4MB text file) and had a go at dumping it in to a mySQL database. I haven't done anything with it yet (apart from putting together a rudimentary interface) but I have a few ideas for interesting ways of reusing the data.
314-0,"passage: New CSS Experiment: Trickery with Floats and Negative Margins, inspired by this message on css-discuss. By applying both position: relative and a negative margin to a floated element it is possible to pull it out of the flow of text in to the margin of the document. I have used a variant of this technique in the third revision of my SitePoint in CSS demonstration."
315-0,passage: Hacking Las Vegas (via Kryogenix) - the story of how a bunch of wizz kids from MIT devised the perfect card counting technique and took the casinos for the ride of their lives. Edge-of-your-seat stuff.
316-0,passage: Madhu Menon: Avoiding personal conflict on mailing lists.
317-0,passage: I wonder if these muppets have heard of eggdrop (created 1993). Something tells me prior art for this one won't be too hard to find.
318-0,passage: Michael V has written a couple of functions to apply my CSS numbered code listing technique to PHP's built in syntax highlighting.
319-0,passage: 10 Tips on Writing the Living Web is full of invaluable advice for anyone who wants their weblog to be of interest to other people.
320-0,"passage: css-discuss has seen some interesting threads in the past 24 hours and the new archive means I can link straight to them - so here goes. Kentaro Kaji kicked off the topic of techniques for aligning an image with the bottom of a block of text. In the same thread, Benn Nunn advocated avoiding width and height attributes on images and keeping that information in an external style sheet. Other topics included accessible navigation and a tricky absolute positioning problem with Opera. The most informative mailing list I'm currently subscribed to just keeps getting better."
321-0,passage: Eric Meyer has confessed.
322-0,"passage: Mark Pilgrim has written an ultra-liberal RSS locator (in Python, naturally). I guess he had to scratch an itch. The amount of work it puts in to locating an RSS feed for a site is astonishing, especially when you consider how short the actual code is."
323-0,passage: Things that make Baby Jesus cry (stolen from Mark Pilgrim). Google as social commentary?
324-0,"passage: Pink Goblin (otherwise known as HarryF) explains why magic quotes are evil. This is an issue that every PHP developer should be aware of, as it can cause all kinds of problems in your scripts if you ignore it. He suggests using a custom myAddSlashes() function which only calls addslashes() if magic quotes are turned off. I have an alternative solution - chose your preferred setting (quotes on or off) and apply it at run time to all incoming data in one go. My code for doing this is available here. By a bizzare coincidence I wrote the script this morning, then spotted a link to the Pink Goblin article on tidak ada literally five minutes after finishing it."
325-0,passage: I've improved the comment system at the bequest of Adrian Holovaty. URLs posted in a comment (both those beginning with http:// and those beginning just with www.) will now be converted in to links.
326-0,passage: Update: 4 out of 4! :D
326-1,"passage: Hixie has posed a fiendish markup quiz - spot the four markup errors in a document that validates. It's harder than it sounds. I've mailed off my answers, but I'm not expecting to get full marks."
327-0,"passage: Paul Graham: A Plan for Spam. Paul suggests using content based filters that learn from users specifically marking messages as spam or legitimate mail. The system then picks emails apart looking for commmon terms (in both the body and the header of the message) that can then be used later on to identify spam messages. He claims his test have let through only 5 per 1000 spams, with 0 false positives. Impressive stuff, and great reading for the excellent explanations of some advanced alogithmic and statistical techniques."
328-0,passage: Scott: Why I'm Not Reading Your Blog and Why Others May Not Be Also. Scott likes text he can resize and a decent update frequency. Tony Bowden responds that update frequency is no longer an issue for him ever since he switched to using a blog roll that shows him when the blogs listed were last updated. The same is true for me - my blo.gs powered blog roll has slashed the amount of time I spend keeping up with other people's blogs as I only visit them when there's something new to read.
329-0,passage: Another cracking article from Scott: 12 Tips for Working from Home But Keeping it Under Control. I worked from home for a while last year and these tips make a lot of sense (I know because I wasn't doing any of them and I suffered as a result).
330-0,passage: An interesting thread on SitePoint about SQL injection attacks. One of the points brought up is that PHP is by default virtually immune to injection attacks thanks to magic quotes (discussed here yesterday).
331-0,"passage: If I don't post much today it's because I'm hard at work on the new database driven version of this blog. I'm hoping to open souce it so I'm trying to design it to be as easy to customise and modify as possible, which means plugin support, themes and an extensible API. At the moment it will only work with mySQL but I'm trying to keep the data access routines abstracted away so they can be easily replaced with code for other databases or even a flat file or XML storage system."
332-0,"passage: CSS Image Rollovers describes a brilliantly simple technique for creating the effect of an image rollover using only one image and no javascript. The effect works by creating a gif with a transparent background, then using a :hover pseudo class to change the background colour of the the containing area. Pretty straight forward so far, but the clever part is that by making the transparent part of the gif an interesting shape (placing it around the outline of a shape in the image for example) you can give the impression of displaying a different image entirely."
333-0,"passage: Today's pleasant surprise - while surfing around the Wireplay forums I came across a link to alliedassault.co.uk, a community site for Medal of Honour: Allied Assault. Imagine my surprise when I realised the news section was coded by me! It uses a news script I wrote over a year ago and never got around to finishing - I released it to a few people and it seems Reality ended up using it on the site. It's great to see code you've written being used after you've all but forgotten about it - the site also uses my ssLinks link management script, the sequel to which I am working on now."
334-0,"passage: I'm not sure how to climb inside this user's head. It's a very alien experience. But I have to do it. Because for every bit of code I write, every navigation scheme that I dream up, Netscape Google is at the other end, actually trying to use it."
334-1,"passage: Sam Buchanan: The Netscape Google mystery. A user complains of a non functional web appli ation, and when asked what browser they are using replies ""Netscape Google"". Sam suspects that this is because Google is their home page and they type URLs straight in to the Google search box. I wouldn't be surprised if he was right - I have seen several people (including an Aunt of mine) do this in the past. Sam's summary rings particularly true:"
335-0,"passage: I watched Laurence Lessig's OSCON keynote the other day (an 8.4MB Flash file courtesy of Leonard Lin). A transcript of the session is also available. It was an excellent presentation and really opened my eyes to the issues facing intellectual property in the United States. It also appears to have raised some hackles - Dave Winer took offence to the implication that developers had not done anything about the problem, and Doc Searls has responded to Dave's criticism with some interesting background information on Lessig."
336-0,"passage: I'm off down to Exeter to see my girlfriend this afternoon, then we're heading off to the Reading Festival on Wednesday. Updates will be scarce for the next few days."
337-0,"passage: Back from Reading. 3,200 emails (I forgot to unsubscribe from some mailing lists). <sigh>"
338-0,"passage: DevShed have published two useful new articles - MySQL Connectivity With Python and Understanding SQL Joins. They also now provide nice looking printer-friendly PDF versions of articles, which appear to be dynamically generated. Having found this article on Google I suspect they are using HTMLDOC to create the PDFs."
339-0,"passage: I've installed a brand new shiny copy of Mozilla 1.1, and thrown in the new Pie Menus addon for good measure. The new build seems a fair bit speedier than the 1.1 alpha version I was using before, but other than that and some funky new icons I haven't spotted many differences. Pie Menus are interesting (and have already been discussed at length on Mozillazine, Blogzilla and Slashdot) but don't seem as useful as mouse gestures, although they have a much shallower learning curve."
340-0,"passage: News to me: Mozilla supports the <marquee> element (marquee test page)! Support was added a couple of months ago in light of the fact that nearly 30% of top 150 sites in China use the marquee
element. Bug 156979 contains a fascinating discussion of this issue and why the decision was made to implement this controversial extension to the standards. Hogarth has a page detailing a way of disabling the behaviour of the element in your own Mozilla installation."
341-0,"passage: Over one year ago Opera's engineers started working on two separate development branches. One of them later became the successful Opera 6, released in December 2001. The latter was a longer project: optimizing Opera's core with the latest and best in standards support and features, while not compromising speed."
341-1,passage: Coming soon: Opera 7:
342-0,passage: youngpup's DOM-drag is a cross browser library for creating draggable interfaces in DHTML. I had previously been looking at using Glen Murphy's dragdiv for this kind of thing but DOM-Drag looks like a more mature implementation.
343-0,passage: BT lose.
344-0,"passage: Two gems from Jeffrey Zeldman: Show, don’t sell and Table Layouts, Revisited. An extract from the former:"
344-1,"passage: In the latter, Jeffrey sings the praise of transitional layouts which use simplified table structures enhanced with CSS, thus providing a more practical aproach to dealing with commercial requirements and legacy browsers."
344-2,"passage: Take credit for what CSS has done. Don’t say: ""Web standards did this."" Do say: ""We’ve set up a system that will automatically format the page whenever you update it."" Let the client think you’re smart and give you more business."
345-0,"passage: Plenty of action on the TrackBack front. Michel V is adding TrackBack support to b2, Moveable Type have released a standalone Perl implementation of TrackBack under the Artistic license, MetaFilter have added TrackBack support and Matt Kingston has published a full blown Homebrew TrackBack Tutorial for people who want to roll TrackBack support in to their own home grown blogs. Yet another thing to add to the todo list..."
346-0,"passage: Phil Ringnalda has done the decent thing and rid himself of comment popups (the comments attached to his post make interesting reading). I haven't got round to doing this yet, which is especially silly considering I open my own comments links in new tabs to avoid the popups myself. The main problem I have is that I want people to permalink to each entry within the context of the day it was posted - comments without a popup would need each entry to have its own comments page which could lead to people linking to the wrong place. My options so far are either to trust people to link to the permalink rather than the entry comments page or to go with a ""show comments on the page"" feature, possibly using a hidden div or even an external comment loader script as demonstrated by kryogenix a few weeks ago."
347-0,passage: A few other things I read today:
348-0,passage: And some more...
349-0,passage: Peter goes on to say (in the comments attached to the entry) that RDF's biggest obstacle is the fact that it requires write-access - only the content owner can add meta data. External meta data implementations such as XTM and XFML are inherently more flexible.
349-1,passage: Peter provides an interesting perspective:
349-2,"passage: RDF is dead as a popular metadata format. If it was gonna happen, it would have already. Forget about it."
350-0,"passage: Stuart has put together a nice demonstration of how Mozilla's CSS3 selectors can be used to automatically add icons to external links, in response to Mark Pilgrim's guide to achieving the same effect using Moveable Type macros."
351-0,"passage: What's amazing to me is the fact that the hardware is free. For doing things even in the hundreds of terabytes, it costs in the hundreds of thousands of dollars. When you talk to most people in IT departments, they spend a couple hundred thousand dollars just on a CPU, much less a terabyte of disk storage. You buy from EMC a terabyte for maybe $300,000. That's just the storage for 1 TB. We can buy 100 TBs with 250 CPUs to work on it, all on a high-speed switch with redundancy built in."
351-1,passage: How the Wayback Machine Works is a must read for anyone geeky enough to be interested in cheap clustered databases on a huge scale. The interview includes some fascinating details on the cost effectiveness of Linux clusters:
352-0,"passage: IMS/ISC out of the ICANN Running, apparently because their proposal didn't include enough block diagrams. ICANNWatch have some great conspiracy theories as to the real reason."
353-0,"passage: R&OS PDF PHP classes (via tidak ada). This is the most useful PHP library I've seen in a long time. It allows dynamic generation of PDF files without needing any additional modules installed on the server (although GD is required if you want to add images to your PDFs). It is extremely easy to use and has an impressive set of features, including PDF drawing tools, built in page number support and excellent documentation. On the topic of PDFs, Yes You Can advocates their use for presentations and touches on a method of generating them using Python."
354-0,"passage: The Semantic Web: 1-2-3 is an invaluable collection of links to semantic web resources, compiled by Morbus Iff. Morbis is the author of Amphetadesk, an excellent news aggregator which was reviewed favourably by Ben Hammersley in the Gaurdian just the other day."
355-0,passage: Free book: Vi IMproved.
356-0,passage: What Do I Know is hosting an interesting discussion on File Naming and Organization Methods for helping manage web development clients.
357-0,"passage: Tim Luoma: 30 Days to becoming an Opera Lover. Advocacy doesn't get much more serious than this :) The series has reached day 5 and so far Tim has covered reasons you should try Opera, how to install it and touched on customisation. I've been meaning to write a Mozilla advocacy/tutorial piece for some time now and I am sorely tempted to steal Tim's format (which he himself borrowed from Mark Pilgrim)."
358-0,passage: A discussion on Aquarionics nails why TrackBack isn't quite there yet (emphasis mine):
358-1,"passage: In the comments attached to the entry Stuart links to his thoughts on a better way of implementing the same functionality, using an XMLRPC server that can be auto-discovered via a <link> element."
358-2,"passage: Plus, to support Trackback, I must put what amounts to part of an RSS feed in each post so that Movable Type's Bookmarklet thing can magically know what to do. I don't object to the idea as much as... well, there has to be a better way of doing this."
359-0,"passage: Scott Johnson (and others) has been waging war against Font Bitches, aka people who use fixed (pixel) fonts on their sites making the text unresizable in Internet Explorer. Here's a new bookmarklet that can help alleviate the problem:"
359-1,"passage: Make fixed fonts resizable in IE (drag it on to your links bar and use it on any offending pages, then resize text with ctrl+mouse wheel)."
360-0,passage: Joel Spolsky: Platforms. Plenty of food for thought. Dave Winer responds with a pointer to his 1996 article The Perfect Parent which touches on the reasons Groove can't count on making it as a platform.
361-0,passage: Zend have a short tutorial on PHP Templating with Smarty.
362-0,passage: I've been playing with XML-RPC and PHP today. I ended up using Keith Devin's pleasantly straight forward library thanks to PHP's built in (and completely undocumented) XML-RPC support conflicting with the function names used by Useful Inc's partially object oriented library. I've been messing around with Stuart's idea for a trackback alternative and things are looking pretty promising.
363-0,"passage: Web Basics with LWP (via Scott) is an excellent tutorial on Perl's LWP, a powerful set of modules which make it easy to retrieve content from the web. I've been using the excellent Snoopy class for PHP for the same purpose, but I have to admit it isn't half as comprehensive as LWP. I've also written my own simple function safeGet for more light weight tasks - it grabs and returns the contents of a web page but limits both the size of the page and the maximum time it can take to download it."
364-0,passage: Aquarionics has joined the Mozilla <link> element party.
365-0,"passage: I spent most of yesterday messing around with XML-RPC. There are a variety of XMl-RPC libraries available for PHP but none of them felt right for what I needed. So, I've written my own."
365-1,passage: Feedback (bug reports in particular) can be sent via my contact page.
365-2,passage: It's straight forward to use and does a pretty good job of hiding the details of the XML-RPC implementation from the user (by converting PHP types to XML-RPC types and back again transparently). There's very little documentation at the moment but I plan to write some shortly - in the mean time the example code should be enough for adventurous users.
365-3,passage: The Incutio XML-RPC Library for PHP
366-0,passage: Testing pingback. This post is a lot more exciting than it looks ;)
367-0,"passage: I've implemented PingBack on my blog. PingBack is a system for tracking who is linking to your blog in a controlled way, based on a post by Stuart a few months ago. The idea is that when you link to a PingBack enabled blog you (or your blogging tool) should send an XML-RPC ""ping"" to that blog's PingBack server telling it where you have linked to and where you linked from. The PingBack server can then grab your page, check that the link is there and extract a title and short description from the blog. The system is an alternative to (and was inspired by) MoveableType's TrackBack feature. Stuart and I are actively developing the idea and will be releasing code and documentation to help other people experiment with the system in the near future."
368-0,passage: More on PingBack. PingBack can be seen in effect on this blog and in this entry on kryogenix.org. If you wish to ping my blog you can do so using the following XML-RPC details:
368-1,"passage: pageLinkedFrom must be the URL to a permalink archive page on my blog (complete with #fragment) and pageLinkedTo must be the URL of a page that contains a link to pageLinkedFrom. My server is a bit flaky at the moment (hosting problems again) so you may need to repeat the ping a few times before it gets accepted. Stuart's PingBack server can be found at http://www.kryogenix.org/mt/mt-xmlrpc.cgi. Both of our blogs now include a link element pointing to our PingBack servers, with the rel attribute set to ""pingback"" and the href attribute indicating the server URL. The link elements should enable auto-discovery of PingBack servers in the future (an idea based on Mark Pilgrim's RSS auto-discovery)."
369-0,passage: Some useful XML-RPC links (before I forget):
370-0,passage: According to XML-RPC.com's Implementations page there are now 8 PHP implementations of XML-RPC! Looks like I wasn't the only person with an itch to scratch :)
371-0,"passage: Also system.multicall would be good, as an in built mechanism (see here) and a means to build in introspection automatically."
371-1,"passage: The client still needs one or two things, namely SSL connections (using Curl perhaps or with PHP 4.3 fsockopen can access SSL sites if OpenSSL is compiled with PHP) and HTTP Basic Authentication."
371-2,passage: There's a good HTTP client class here.
371-3,passage: ...If I can dare to make one suggestion: would be good to seperate the HTTP client as a seperate object from the XML-RPC client.
371-4,passage: HarryF provided some excellent feedback on my library:
371-5,passage: May be the ISO8601 types can be spotted in the strtotime() function?
371-6,passage: The reason is there's not a single XML-RPC class yet that handles HTTP fully. There's hardly even a complete PHP HTTP client to work with either.
371-7,"passage: Also on the server side, would be great if there was a mechanism build in HTTP Authentication headers (again as a seperate class) - there's an Authentication class here."
372-0,passage: Matt Drudge: The Two Towers is available on the Internet. Dorothea Salo: This is bogus. Aren't rumours fun?
373-0,"passage: Q. Can I use Jellybath in a Jacuzzi or Hot Tub?
A. No, it is not recommended that you use Jellybath in tubs with jets."
373-1,"passage: Incidentally, Aquarion has implemented PingBack using my XML-RPC library. Ping!"
373-2,passage: JellyBath (via Aquarionics). It turns your bath water in to Jelly. From the FAQ:
374-0,"passage: Yet more XML-RPC goodness. The documentation for the suggested introspection methods throws a 404, but Google's cache doesn't:"
374-1,passage: I'll be adding these to my library as soon as I get a chance. Tonight though I'll be working on IncDirectory.
375-0,passage: A comprehensive list of different MIME media types (via Scripting News).
376-0,"passage: The BBC are running a set of beta RSS feeds for their news service, covering the front page, World news, UK news and Technology news. The feeds provide the article title and the short sub-heading as a description. More information courtesy of Matt Jones."
377-0,passage: Yet more XML-RPC specs (thanks HarryF):
377-1,"passage: I've subscribed to the XML-RPC mailing list. Finally, if you're still trying to get your head around XML-RPC you can't go wrong with HarryF's excellent tutorial on SitePoint."
378-0,passage: Rob Tougher: My Guide To Digital Photography. A short but informative article on using Linux and Python to manage a collection of digital photographs.
379-0,passage: Jeffrey Zeldman on fixing A List Apart for IE6:
379-1,passage: MSIE6 has trouble calculating the heights of block level elements. Eddie Traversa discovered the browser was caching the values it calculated on one page of ALA and incorrectly applying those values to other pages of the site.
379-2,"passage: Put simply, if the content area on page A was 200px high, and the same area on page B was 400px high, IE6 might display only the first 200px when it loaded page B. The initial value got stuck in the browser's cache. This is the reason that manually reloading (for instance, by hitting F11) ""fixed"" the bug on a page by page basis."
379-3,"passage: Jeffrey mentions a javascript fix for the problem which is now in use in ALA's global javascript file, and promises an article describing the fix in the near future."
380-0,passage: Via Stuart: Top of the Crops 2002 - the highlights of the UK Crop Circle season. Some of these are just awe inspiring.
381-0,passage: The css-discuss Wiki has gone live - but only to list members. If you are on the list you will have received an email with instructions for accessing it. The Wiki should go live to non list members in a few days time.
382-0,"passage: While I was working with it I came up with an idea for a wyay of transferring objects over XML-RPC, which I've written up and posted to the XML-RPC mailing list. Take a look and tell me what you think :)"
382-1,"passage: I was up most of the night working on a new version of my XML-RPC library (newly named IXR, for Incutio XML-RPC). I should have it ready for release some time today - it implements most of the extensions I've linked to over the past few days and has a much cleaner object structure than the first version, while maintaining the ability to implement a server or client in as little code as possible."
383-0,"passage: With CSS finally at a stage where we can properly start to separate structure from presentation I think WYSIWYG editors are far less relevant today than they were a year ago. XHTML is about semantic markup, with presentational stuff being relegated to the site developer controlled stylesheet (where it rightly belongs). Any page editing tools need to concentrate on helping users mark up content in a meaningful way rather than letting them chose their favourite colours and fonts."
383-1,"passage: Scott wants a rich text editor for Mozilla. What's more, he's willing to put his money where his mouth is and organise a fund drive to give developers a real incentive to do a good job."
383-2,"passage: Incidentally, xopus.org have an interesting partial implementation of contentEditable for Mozilla. They have also just released the open source version of their impressive browser based XML editor. One to watch."
383-3,"passage: That said, I strongly believe that the Mozilla project should invest considerable effort in browser based editing tools. Web based interfaces are here to stay, and a lot of people spend large chunks of their day creating content in a browser. Rather than relying on wizzy and unstable javascript tricks though I think we should go back to basics and reconsider the textarea. Imagine a textarea element that, when double clicked, spawned a brand new editing environment in a new window with all of the tools of a modern text editor. Or how about the option to spawn Composer (Mozilla's built in HTML editor) with the contents of a textarea, then click a button to have your newly created HTML dumped right back there? I haven't looked at Composer properly so I have no idea how standards compliant it is (or isn't) but it's already built in to the Mozilla suite - why not integrate it with the one part of the browser that needs it the most?"
383-4,"passage: At the end of the day, I suppose anything that enables more people to publish to the web has to be a good thing - especially if it enables more people to make the switch from IE :)"
383-5,"passage: At Incutio we have a long history of messing around with rich text editors. I wrote an IE DHTML editor (similar to the one used by Radio Userland) least year which is still in use in our flagship CMS. We are currently looking at replacing it with a Flash editor, which will give us both cross platform compatibility and a better level of control over the HTML. Put simply, MSHTML generated code is absolutely revolting. It's made worse by the fact that people can cut and paste from Word, Excel and even other IE windows, preserving the formatting every time. Great for picky users but a nightmare for us web developers who are trying to keep the visual look of a site constant. And you can forget about standards compliance..."
384-0,"passage: Stuart has published the first draught of the PingBack specification, detailing how PingBack works and how it should be implemented. PingBack is brilliant - it just works. What could be simpler than just quietly telling someone's blog that you've linked to them?"
385-0,"passage: Announcing beta 1.5 of IXR, the Incutio XML-PRC Library for PHP. The library has undergone a complete restructuring and has a much cleaner design as a result. It also has a huge stack of new features, including:"
385-1,passage: Enjoy! Feedback and bug reports to the usual place.
386-0,passage: I have written a guide to accessing the Jargon File web service using Python's xmlrpclib.
386-1,"passage: I've implemented two example web services to demonstrate the Incutio PHP XML-RPC library's capabilities. The services allow you to search and retrieve articles from FOLDOC and the Jargon File, two popular freely available online dictionaries."
386-2,"passage: The Jargon File is ""a comprehensive compendium of hacker slang illuminating
many aspects of hackish tradition, folklore, and humor""."
386-3,"passage: It is currently edited by Eric Raymond, and can be found on
the web at http://www.tuxedo.org/~esr/jargon/"
386-4,passage: The web service interface to the Jargon File allows you to search the dictionary and retrieve entries from it.
386-5,passage: The following methods are available (in addition to the standard system methods):
386-6,"passage: FOLDOC is the Free Online Dictionary of Computing, edited by Denis Howe and made
available under the GNU Free Documentation License. It can be found on the web
at www.foldoc.org."
387-0,passage: Vincent Oostind:
387-1,"passage: In most areas in computer science, Open Source products follow after the commercial ones. Admittedly, first some pioneer thinks of a new technology and often releases it as Open Source, but the released stuff is never quite fit for production use. That makes sense, because it was a prototype; it was being pioneered. If it looks promising, commercial companies take it over, throw lots of money and expertise at it, and end up with a product that does make it into the market. Once a large group of people wants the same thing that commercial software already provides, but they don't want to pay for it, then they try to mimic it."
387-2,passage: Vincent also makes some interesting points about the relative difficulty of library and framework design compared to writing interpreters and compilers. Today's must-read.
388-0,"passage: The Incutio XML-RPC Library for PHP (IXR to its friends) now has a forum. The forum is powered by incForum, Incutio's very own forum software written by my colleague Tim."
389-0,passage: Adrian Holovaty in a blogite thread about features that can be added to blogs:
389-1,"passage: Change the time zone. I've noticed a lot of blogs don't specify which time
zone they're in, which pretty much makes the timestamp meaningless. I put
""EST"" on mine, and my about page explains my time zone further, but I think
it would be convenient for the users to convert the times to their own
zones. I did this in JavaScript on one of my old sites, but I'd rather do it
on the server side for accessibility's sake."
389-2,"passage: This got me thinking about how best to ""guess"" a user's timezone. A search on Google for ""country ip address"" turned up GeoIP, an impressive looking open-source based database for looking up countries by IP address. The database updated yearly is free, while monthly updates can be had for a very reasonable $150 annual subscription."
390-0,"passage: Aquarionics is now PingBack enabled, and he implemented it using IXR. Yay!"
391-0,passage: Leonard Lin has blogged a whole bunch of useful Mozilla links. He also has this to say about mouse gestures:
391-1,"passage: OK, some people like gestures. I don't because I like dragging my mouse around and highlighting stuff randomly."
391-2,"passage: So do I - that's why I've got gestures configured to my right mouse button :) Judging by Leonard's blog he uses OS X on a Mac, which I'm guessing comes with a one button mouse. The gesture package allows you to set a modified key that must be held down to activate gestures but I can't see that this provides any real benefit over using a keyboard shortcut."
392-0,passage: Google cooking (via Kottke). This is going to be very useful when I get back to uni.
393-0,"passage: Judging by the screenshot on this page, Scott really needs Mozilla :) I'm currently running Windows XP on a Pentium II with 128 MB of RAM but thanks to Mozilla's tabbed browsing I have over 20 web pages open and my machine isn't breaking a sweat (and that's in addition to Eudora and mySQLFront). Best of all, my task bar stays nice and tidy as it only shows one instance of Mozilla. I know Scott's itching to switch already so I'll teasingly remind him that Mozilla can have multiple windows each with multiple tabs - so you can have a single window with a collection of sites for each item you are currently researching. More tabbed browsing advocacy from Dave Hyatt right here."
394-0,"passage: There's enough RSS discussion floating about right now to make one's head spin. Thank Goodness then for Mark Pilgrim, who yesterday posted an excellent explanation of RSS 2.0, and today followed it up with both a hugely informative History of the RSS Fork and a concise summary of the cases for deprecating some of the existing RSS 0.94 elements in the upgrade to RSS 2.0, which seems to be one of the biggest talking points in the RSS community at the moment. I can't say I've quite figured RSS out yet but thanks to Mark's tireless commentary I fell a lot more informed than I was yesterday morning."
395-0,passage: Stuart has outdone himself with his latest piece of javascript wizzardry. searchhi will highlight search terms when someone visits your page from a link on Google - all using the DOM and all without you having to do anything more than add a <script> element to the top of your page!
396-0,"passage: Spotted on Python owns us: Fredrik Lundh is building an RSS newsreader in Python, and writing Python tutorials on the project as he goes along. The first tutorial, Fetching RSS Files, is available now and covers (in detail) retrieving RSS files over the web, including an excellent explanation of asynchronous HTTP requests."
397-0,"passage: There's been a lot of talk in the community about how RSS 2.0 is too complicated. I haven't heard any objections, so I'm going to move ahead with the following changes that will result in RSS 3.0."
397-1,"passage: Forget about RSS 0.9x, RSS 1.0 and RSS 2.0, Aaron Schwartz has released a spec for RSS 3.0 :)"
397-2,"passage: Best of all, it can be parsed using a Python one-liner."
397-3,passage: 3. HTML forbidden. No one needs HTML. Email has been just fine for years before Microsoft introduce their stupid rich HTML extensions. HTML is for those loser newbies. Any intelligent Internet user deals in plain text.
397-4,passage: -- snip --
397-5,"passage: 1. Remove XML. XML is just too complicated and is against the spirit of RSS, which is Really Simple Syndication. I don't want people to have to buy one of these 200 page XML books to understand RSS. And XML sucks up bandwidth like nobody's business. Instead, we'll go back to RFC822-style fields. There are lots of available parsers for those."
398-0,"passage: The source code for my PingBack server, including the code I use to grab an extract from the page linking to my site, is now available here."
399-0,"passage: Hixie has a brilliant solution to the time zone problem in the form of a clever piece of XBL by Nicolás Lichtmier. The small script can be bound to an element containing a date in UTC and will quietly replace it with the time in the user's current timezone using Mozilla's built in UTC handling functions. Naturally it only works in Mozilla, but I imagine the script could be emulated using Internet Explorer behaviors."
400-0,"passage: The RSS Tutorial for Content Publishers and Webmasters is a great read if you haven't figured out the difference between RSS 0.9x (Really Simple Syndication), RSS 1.0 (RDF Site Summary) and RDF (a web standard for meta data which is used within RSS)."
401-0,"passage: If you were wondering why this blog went quiet all of a sudden, here's the reason. I've moved to a new host, and in the process completely rewritten the engine that powers this weblog from the ground up. Entries, comments and other bits and pieces are now served from a mySQL database as opposed to the flat files I was using before hand, and all pages are dynamically generated rather than being built as flat HTML files. The design remains pretty much the same, but comments and pingbacks are now displayed on the same page as blog entries rather than having their own popup windows. I am also no longer restricted by the previous hosting's bizzare limit on the size of POSTed form variables, leaving me free to write longer blog entries (and you free to write longer comments)."
402-0,"passage: XHTML documents that are not well-formed XML are useless, and since browsers still display them the web is potentially being polluted with invalid (and useless) XHTML documents. Ian also makes the point that, while the greatest benefit of XHTML is that it can be processed by XML parsers, the only people likely to take advantage of this ability are the content authors themselves who will most likely be using configurable tools to produce the content anyway."
402-1,"passage: Document sent as text/html are handled as tag soup [1] by most UAs.
This means that authors are not checking for validity, and thus
most XHTML documents on the web now are invalid. Therefore the main
advantage of using XHTML, that it has to be valid, is lost of the
document is then sent as text/html."
402-2,passage: Ian Hickson: Sending XHTML as text/html Considered Harmful. Ian makes an excellent case for sticking with HTML 4.01 rather than upgrading to XHTML. Here's the killer point (at least for me):
402-3,"passage: So why haven't I switched this blog back to HTML 4.01 yet? It's a good question, and one which I will attempt to answer in the not too distant future."
403-0,"passage: I've flicked the switch and redirected my old blog to this new site. Unfortunately the Bath University web server appears not to obey .htaccess directives so I am currently having trouble redirecting old archive pages to their new homes on this site. I should have that issue fixed shortly, but in the meantime permalinks to pages on my old site will throw an unsightly 404 error page."
404-0,"passage: Jonathan's right, ""pocket stuff"" is a perfectly valid excuse (at least until society stops discriminating against guys with handbags)."
404-1,"passage: Big Kev is an Australian icon who has taken the cleaning products business by storm—partly because of the quality of his merchandise but mainly because he appears in his own TV commercials wearing one of a large collection of spectacularly vulgar satin shirts and signing off with the slogan: I'm Excited! Thanks to Big Kev, Australia leads the world in stain removal technology."
404-2,passage: Jonathan Delacour:
405-0,"passage: Although simple, Labels.js is an example of my ideal DHTML script, and an example of what I believe the W3C had in mind for the DOM. Some of the design goals that it meets are:"
405-1,passage: The same elegant approach to DHTML can be seen in Stuart's aqTree javascript tree system.
405-2,passage: Spotted on youngpup: Labels.js: A Re-Introduction to DHTML (from December 2001).
406-0,"passage: Imagine a textarea element that, when double clicked, spawned a brand new editing environment in a new window with all of the tools of a modern text editor. Or how about the option to spawn Composer (Mozilla's built in HTML editor) with the contents of a textarea, then click a button to have your newly created HTML dumped right back there?"
406-1,"passage: With the release of Composite, it seems my wish has been fulfilled. Composite is a chrome overlay which enables a streamlined Mozilla Editor for html composition in textareas. Install the plugin, hit Ctrl+E in a textarea and off you go."
406-2,passage: It's still got a long way to go but for a first release it's looking very promising indeed.
406-3,"passage: A few days ago, I blogged the following:"
407-0,passage: I've re-enabled PingBack on my blog. Auto-discovery is now supported via both the standard <link> element and the new X-PingBack HTTP header. I have also implemented a new experimental method on my PingBack server - pingback.extensions.getPingbacks(url). Send it the URL for an entry on this blog (it must be an archive page and must include the fragment identifier so the system knows which entry you mean) and it will return an array of pages that have been registered as linking to that page via PingBack. This new feature is explained in detail in this email sent to the the blogite mailing list.
408-0,"passage: I just realised I haven't linked to the Pingback specification yet, so here it is. The spec has been carefully assembled by Ian Hickson and, although it is still a working draught, should be the first stop for anyone who wishes to create a Pingback implementation."
409-0,"passage: This post exists partly to list the blogs I know of that support PingBack, but mostly to help test my new PingBack client implementation."
409-1,passage: Fingers crossed... here goes!
410-0,"passage: A quick note concerning RSS feeds. I have not yet implemented them on my new blog, but I plan to do so in the next few days. On the advice of Chris Coome and Bill Kearney (both of whom replied to my question on [rss-dev]) I will be providing feeds in both RSS 1.0 and RSS 0.91 formats, and I plan to provide individual feeds for the various categories on the site. I also have an idea for a feature that will allow people to ""build their own"" RSS feed consisting of the categories they are most interested in. As always, watch this space :)"
411-0,passage: A handy bookmarklet courtesy of Rick on the MACCAWS mailing list:
411-1,passage: Disable stylesheets for current page
412-0,"passage: Because of the way frames (and iframes) are handled by IE version 5.5 and above, attackers are able to get to all sorts of mischief with minimal effort, including:"
412-1,passage: The Register: IE 6 SP1 omits fixes for 20 outstanding flaws:
412-2,"passage: Luckily, an upgrade is available which provides immunity to all of the above vulnerabilities (sorry, I just couldn't resist that particular dig ;) )."
413-0,passage: This project has been discontinued.
413-1,passage: This is really strange - a new version was released just the other weekend and now the project seems to have just terminated with no explanation.
413-2,passage: Does anyone know what's up with MySQLFront?
414-0,"passage: Incidentally, the article is hosted on zone.effbot.org, which calls itself Fredrik Lundh's brainstorming subsite and seems to be a Wiki-style repository for miscellaneous articles and pieces of content. It contains a wealth of interesting Python tidbits if you're willing to spend some time browsing around. I'm a big fan of what I call the Wiki model of content management (one namespace, a free form navigation structure) and the zone looks is a great example of this model in action."
414-1,"passage: Fetching and Parsing RSS Data is the second installment of the effnews project, a series of tutorials on creating an RSS news reader in Python. This time topics covered include exception handling and event based XML parsing using xmllib."
415-0,passage: Flash MX and the Bigger Picture: Lightweight Internet Applications:
415-1,"passage:
While I propose what may be a radical notion to some, with additional consideration the value of lightweight Internet applications starts to become apparent. I am not proposing that the browser is dying, but rather that it would be enhanced by an application-centric complement. Flash MX and its underlying SWF format are ready to provide such a solution today, though some have misgivings because SWF is a proprietary format held by one company--Macromedia. However, few viable alternatives currently exist to address this emerging need.
"
415-2,"passage: I've been getting the impression that Macromedia are repositioning Flash as a tool for creating web applications rather than one for creating standard web sites. This seems like a sensible move to me - I seriously doubt Flash will ever be as good a format for serving normal documents as HTML, but as a light-weight web application platform Flash has many obvious advantages. I remain concerned that it is based on what is still a proprietary format - the internet's as it exists today is built on open standards and anything that moves away from that weakens the universal nature of the web. SVG looks promising but could take years to gain proper support, so for the moment it looks like Flash MX remains the most viable solution to this problem."
416-0,"passage: I've set up my first new syndication feed using RSS 1.0. I've checked the feed against this RSS validator and it seems to pass, but throws a warning that item descriptions are meant to be between 0 and 500 characters in length. As I want to provide the full contents of my entries in the feed (for people using aggregators such as AmphetaDesk) I've decided to ignore the warning and leave it as it is."
417-0,"passage: I've had an idea for a new way of hiding email addresses from spam harvesters - shield the address behind a form that must be submitted via POST. Site visitors can now click a button on my Contact page to reveal my email address. Spammers could always circumvent the system by writing a harvester that parses HTML pages for forms and submits every single one, but I'm hoping they won't bother."
418-0,passage: Kevin Burton: My Dinner with Dave Winer. Something tells me this won't be linked from Scripting News.
419-0,"passage: HSBC (you have to look pretty hard for this one, they've hidden it under ""Trade Marks and Copyright""):"
419-1,"passage: In particular no one may use a part of the Site or any Local Site on any other website, or link any other website to the Site or any Local Site, without our prior written permission or the consent of the relevant HSBC Group member."
419-2,"passage: Link courtesy of Don't Link to Us!, a blog that tracks blatently stupid linking policies."
420-0,"passage:
Accessibility means that users of any kind, using any device, should have access to the essential information that is contained on your web site.
"
420-1,"passage: Randal Rust has posted an updated version of his excellent CSS forms demo. While exploring Randal's site I stumbled across ALPHABET SOUP: A web designer's journey to standards and accessibility, an excellent article advocating CSS, web standards and accessibility which includes the following noteworthy quotation:"
421-0,passage: The Guerrilla News Network: S-11 Redux: (Channel) Surfing the Apocalypse.
421-1,"passage:
So, in the face of our media's shameless propaganda campaign, we have taken it upon ourselves to intuit what the intentions and goals of this war truly are. In what is surely a departure from our traditional NewsVideo format, GNN presents S-11 Redux: (Channel) Surfing the Apocalypse. Culled from over 20 hours of television footage recorded over a one month period and across 13 networks, S-11 Redux is a sound-bite blitzkrieg that challenges the messages we have been fed from our mainstream media and the government it serves. Be warned - this video moves quickly and will require at least two viewings to digest its full impact. You may never be able to look at the coverage of S-11 and its post-impact coverage the same way, ever again."
421-2,"passage: Well worth the download. I particularly enjoyed the George Bush section, accompanied by Ukulele."
422-0,"passage: Strange Mozilla bug: In some versions of Mozilla / Netscape 6+ <label> elements that have a float applied to them will vanish. Tom Gilder's test case can be viewed here. I tried it in Mozilla 1.1 beta and the page behaved as expected but Netscape 6.22 suffered from the bug. Apparently Netscape 7 still has the bug, which would suggest it was spun off from the Mozilla code base before that bug was fixed. Rust Randal's CSS form demo gets around this problem with a span inside a label, which seems to be the most effective workaround but is frustrating as it requires additional markup to solve what is a pretty obscure bug."
423-0,passage: DJ Adams: The RDF in RSS: Just a bit of a brain dump of what I've been learning over the past couple of days.
424-0,passage: Is this photo for real?
425-0,"passage:
Well, buddy ol' pal, the pornoWeb already exists. The Semantic Web is all about making computers aroused, not humans. When computers are aroused, they're much happier pleasing the idiot desires of us fleshlings. So, really, the Semantic Web is about survival and prevention - I'd much rather have happy, complacent computers than angry robots plotting to overthrow the human regime.
"
425-1,passage: Dave Winer: Why be Semantic when you can be Romantic?
425-2,passage: Morbus Iff:
425-3,"passage: I'm pretty sure it's bad manners to quote an entire post like that but Morbus's comment just didn't seem to work if I broke it up any smaller :) To make up for it, here's an extra plug for the Disobey Nonsense Network (and a plug for AmphetaDeskas well, a very cool desktop RSS aggregator)."
426-0,"passage: Jeremy Allaire, Chief Technology Officer at Macromedia, now has a blog. Macromedia's attitude towards weblogging has been fantastic - they seem to really understand the medium and the opportunities it provides, both in terms of PR and keeping their development community involved and informed. Jeremy writes:"
426-1,"passage:
While I'll sometimes post Macromedia specific content here, the intention is really to explore the broad technologies, ideas and companies that are working on the converence of media, communications and applications.
"
426-2,"passage: So far it's all been about Flash, but for the first day of a new blog there have been a whole bunch of good links."
427-0,"passage: In my opinion options to change font colour, size and typeface are a drawback rather than a benefit - most applications for rich text editors will be content management systems that try to create a standard look and feel across a site, rather than letting content editors apply their own styles when they create the content. My ideal editor would be more of a structural XHTML editor than anything else - users would be able to add headers, lists and other structural elements and then apply styles from a logical selection controlled by the CMS. The only question is whether or not Flash MX is a suitable platform for this kind of application (as a complete Flash novice I can only guess at its potential in this regard)."
427-1,"passage: Flash Voodoo's Battle of the Flash Text Editor Components (via Jeremy Allaire) is interesting - the editors are all good, but they all suffer from the same problem in that the code they generate is pretty horrible (font tags and presentational markup galore). This is a limitation of Flash rather than a problem with the coders - our Flash Editor (currently under development by my colleague Richard) has the same problem, so we are looking in to ways of cleaning up the resulting code and turning it in to XHTML."
428-0,passage: Hixie has submerged himself in Unicode. Stuart muses that the reason Unicode is so (potentially) huge is a legacy of the Y2K problem. I prefer the explanation given in XML in a Nutshell (my current reading matter of choice for three-and-a-half-hour-train-journeys-from-hell):
428-1,"passage:
Unicode can potentially hold more than a million characters, but no one is willing to say in public where they think most of the remaining million characters will come from. *"
428-2,"passage: * Footnote: Privately, some developers are willing to admit that they're preparing for the day when we're part of a Galactic Federation of thousands of intelligent species"
429-0,"passage: Because I keep on forgetting where it is, View HTTP and HTML Source, a handy tool for debugging HTTP type stuff courtesy of those fine Mozilla folk."
430-0,"passage: XML seems to be a popular choice for defining GUI's these days - Mozilla has XUL, XWT allows developers to write web based GUI applications with XML and now the Java GUI Builder takes this trend a step further. It seems like a logical progression - after all, GUIs are basically collections of nested components and XML fits that kind of situation like a glove."
430-1,"passage: The GUI builder allows you to define your user interface in an XML file, which is then interpreted by Java at run-time. This allows you to make changes to the interface without recompiling the program (or editing any Java code), and also gives users the ability to edit their interface without needing to alter your code. It's a very clever piece of code."
430-2,"passage: One of the things I really like about PythonCard is that it enables (and in fact actively encourages) you to completely separate the GUi of your application from the program logic. In PythonCard you design your GUI by adding and dragging elements around in the resource editor, then create a simple Python class with event handlers to define what should happen when your GUI is interacted with. Now, thanks to the Java GUI Builder (spotted on Small Values of Cool), you can do the same thing in Java."
431-0,"passage: mod_python has been donated to the Apache Software Foundation. This is excellent news - I have always been slightly wary of mod_python as it has a reputation for being unstable, but with the ASF directly supporting it hopefully any stability problems will soon be a thing of the past."
432-0,"passage: Normally I install new releases of Mozilla as soon as they come out, but this time I am holding back - not because of type ahead (I'm looking forward to trying it out, my objections being purely hypothetical seeing as Mozilla has no keyboard shortcuts that will be affected) but because I've just started using Mozilla Calendar which is currently incompatible with 1.2. Calendar is a superb piece of software - it looks gorgeous, has an intuitive interface and seems to be everything I've been looking for in a Calendar application. It also has the ability to export calendars as iCalendar XML, an open format documented here (as an IETF draft)."
432-1,"passage: The first alpha version of Mozilla 1.2 has been released, with the most notable new feature being Type Ahead Find. I've played with this on previous Mozilla builds (it was available as an addon) and it's an interesting feature - you can navigate around a page by typing the names of links on that page (as soon as you type enough of the link for it to be recognisable the browser selects the link for you). The implementation in 1.2 also allows you to search for items on the page by typing a backslash followed by the search terms."
432-2,"passage: While this is a very clever feature I'm not sure I support it's inclusion in the main Mozilla distribution, for one simple reason: It rules out pretty much every key on the keyboard as a keyboard shortcut. I've been playing with Opera a bit more recently (inspired by Tim Luoma's 30 Days to becoming an Opera Lover series) and one of my favourite features is Opera's keyboard shortcut support, in particular the images key. To toggle images, hit 'g' - with images off pages load a great deal faster (especially on a modem) and if you need to see them you can toggle tham back on again with a single key press. Now that Mozilla has Type Ahead shortcuts like this are pretty much out of the question."
433-0,"passage: I'm moving back up to Bath this afternoon, in to a student house with 4 other people. I don't know if we even have a phone line at the moment so I'll probably be offline for the next few days."
434-0,passage: Cameron Barrett is back from Russia and brings photos. Scott Andrew is back from his summer vacation and brings CSS tips. I am back at University and stuck without bandwidth for the next few weeks.
435-0,passage: Great stuff for computer science students - I wish I'd had this 6 months ago when complexity came up in my programming course.
435-1,"passage: Computational complexity theorists try to determine which problem are efficiently solvable on a computer. This sentence already leads to many questions: What is a problem? What is efficiently solvable? Let us first start off with a truly basic question, what is a computer?
"
435-2,"passage:
This is the first of a long series of posts giving an informal introduction to computational complexity."
435-3,passage: The Computational Complexity Web Log (via Kottke):
436-0,"passage: It seems RSS 2.0 has the capability to support modules (I was under the false impression that this ability was restricted to RDF modules in the rival RSS 1.0 specification). Following a post by Mark Pilgrim on B-linking (the blogging equivalent of a B-movie) Dave Winer has released a draft of blogChannel, the first ever RSS 2.0 module."
437-0,"passage: A pair (x, y) satisfying both equations is a solution of the system. Typically, there will be a single solution where the two graphs intersect."
437-1,passage: The third ELO will alter the goemetry of the system (as visualised in xyz space) but it will not change the solution of the system.
437-2,passage: The elementary row operations are things you can do to the augmented matrix that will not change the solution. They are:
437-3,"passage: In general, we will study systems of n linear equations in m unknowns using the following notation:"
437-4,"passage: This one, many or none model works no matter how many equations or unknowns are involved."
437-5,"passage: This typically has a single unique solution, as there are 3 intersecting planes in xyz space. This can be imagined by visualising two intersecting planes (which intersect along a line) and then visualising the third plane intersecting that line at a point. Again we can have one solution, no solutions (for parallel planes) or many solutions. The many solutions case has several possibilities, including:"
437-6,passage: Now try a system of 3 equations in 3 unknowns:
437-7,passage: The solution is a plane in xyz space.
437-8,"passage: a, b, c and d are constants"
437-9,"passage: The solution of one equation, 3 unknowns:"
437-10,"passage: So, for two equations with two unknowns you can not have any result that is not covered by the above scenarios."
437-11,passage: For systems of 2 equations in 2 unknowns there are three possibilities:
437-12,"passage: Consider a system of two equations in x and y, for example:"
437-13,passage: The solution is the collection of pairs of real numbers x and y for which that equation is true. The graph of the solution is a straight line on the xy plane.
437-14,passage: is called a linear equation.
437-15,passage: An equation such as:
437-16,"passage: These notes are for Dr Daniel Richardson's course ""Mathematics for Applications I"" at the University of Bath.The required text book is ""Linear Algebra with Applications"" by G. Williams, published by Jones and Bartlett"
437-17,passage: A matrix us a rectangular array of numbers. The numbers in the array are caled elements.
437-18,passage: We will represent such systems using matrices.
437-19,"passage: A =>* B is reversible, as each of the ELOs can be easily reversed."
437-20,passage: So aij is the coefficient of xj in equation i.
437-21,passage: A =>* B means A can be changed to B by a sequence of ELOs.
437-22,passage: Elementary transformations are used to change a system of equations in to another simpler system with the same solution. These correspond to elementary row operations on matrices.
437-23,"passage: This can be extended to create the augmented matrix for the system, which adds an extra column showing the equation results:"
437-24,passage: A => B means A can be changed to B by one ELO.
437-25,"passage: Square matrix with 1s on the diagonal (top-left to bottom-right) and 0s elsewhere, i.e:"
437-26,passage: We can use matrices to describe systems of equations:
437-27,"passage: A[i, j] = the element in row i, column j e.g A[2, 3] = 6 in the above example."
437-28,passage: A submatrix is a matrix obtained by delting some rows and/or columns from a matrix.
438-0,"passage: So what was all that about? University term started today, and with it comes my grand plan to blog my lecture notes. Don't worry, I will be restructuring this site in the near future to keep lecture notes off the front page so people who come here for web development stuff don't have to wade through the details of my Computer Science degree. Unfortunately I have limited internet access at the moment so it may be a week or two until I can make the necessary changes to my blog."
439-0,passage: The Register: Want to know how RIAA.org was hacked? They had an un-password-protected admin panel listed in their robots.txt file. Muppets.
440-0,"passage: Hixie has published the specification for Pingback 1.0. In general the specification is an excellent document, but I'm not entirely happy with the following statement:"
440-1,"passage: Some Pingback clients (in particular bookmarklets, although to my knowledge none have been written yet) are expected to be unable to parse headers - which is the primary reason for including the link element method of auto discovery. I would therefore suggest that anyone wishing to pingback-enable their HTML or XHTML documents should include a Pingback link element in addition to the HTTP header."
440-2,"passage:
HTML and XHTML documents MAY include a <link> element in addition to an HTTP header, although this is discouraged."
441-0,passage: Since I'm using the University Library computers at the moment I'm having to reinstall Mozilla on a daily basis. Here's how I do it:
441-1,passage: The above usually takes about 5 minutes but is well worth the time spent if I'm planning to use the library computers for more than half an hour. There's probably a way of automating it all (I heard rumours that Hixie has a script to install the whole lot whenever he logs in) but I'm hoping to have a connection at home again within a couple of weeks.
442-0,"passage: The Bath University Web Standards & Publishing Guide makes interesting reading. They have standardised on HTML 4.01 Transitional and CSS level 2, although the actual page that suggests those standards has an XHTML doctype and fails to validate. The University also aims to support the W3C's Web Content Accessibility Guidelines, priority level 1."
443-0,passage: DENG (via WaSP) is a W3C compliant XHTML/CSS/XForms rendering engine written entirely in Flash MX Actionscript.
443-1,passage: Updated 27th July 2006: Link no longer points at a domain squatter.
444-0,"passage: The Pingback 1.0 specification is getting some serious attention. Mark Pilgrim and Dave Winer have linked to it. Ben Trott (co-author of Moveable Type and creator of TrackBack, the system that inspired Pingback) has objected to Hixie's suggestion that Pingback is more transparent than TrackBack, claiming that TrackBack could be made just as transparent by the right blog tools. Ben blogged some further thoughts which lead to the following comment by Phil Ringnalda:"
444-1,"passage: This is an interesting perspective, but I can't agree with it completely. Firstly, Pingbacks are meant to be sent by blogging tools. If you have blogged a link to someone else's entry you are linking to them for a purpose (which is almost certainly some form of comment on their entry) - this is why my Pingback implementation grabs an extract of their page from the text surrounding the link."
444-2,"passage: I've avoided saying anything about PingBack until now, since I like and respect the people who've developed it, but it is *not* TrackBack. When you send a TrackBack ping, you are saying ""I responded to this, and I think that your readers would also like to read what I said."" You are leaving a remote comment. When you send a PingBack ping, you are saying ""I linked to you"", nothing more. It's a ""show referrers"" script that filters out non-weblog referrers, a way to avoid having to click your own links to be sure you send a referrer. It is *not* TrackBack."
444-3,passage: michel v has some further thoughts on the differences between Pingback and TrackBack.
445-0,passage: Tony Bowden comments on Boo Hoo:
445-1,"passage: At the point of Boo's collapse, we'd built BlackStar to a turnover of $1m per month, with a total operating spend (excluding marketing) of less than $2m in the two years we'd been trading. Our product development costs (i.e the website, and all our fulfilment and customer service systems etc) had been less than $200k, whereas Boo had spent $250k solely on the feasibility study for theirs!"
446-0,"passage: RSS 3.0 was a joke. ESF is serious, and is already getting a fair bit of attention from the blogging and syndication communities."
447-0,"passage:
Think fluid. The WWW isn't a fixed medium. It's unpredictable. It will do unexpected things to your site, and the best you can do is go with the flow."
447-1,passage: Peter-Paul Koch explains graceful degradation in Fluid Thinking:
448-0,"passage: A Derivation in the formal system (D, R) is a finite sequence of rules that can be applied to an object in D. Derivations of length 0 are allowed, so X =>*R X is always true."
448-1,passage: X =>R Y must be decdable - it must be easy to determine if the transition is permitted by the rules. R is formal and must not be ambiguous - it must depend only on X and Y and not on any information outside those data structures.
448-2,"passage: These notes cover the first lecture in Dr Dan Richardson's Formal Systems, logic and semantics lecture. I missed the lecture so these notes are being made with the help of the course notes from Dr Richardon's homepage (which can be viewed using DVI Viewer for Windows)."
448-3,"passage: A formal system is terminating if it does not contain any infinite derivations, so no matter what choices are made the derivations will eventually stop. The best way of working out if a formal system is terminating is to check for possible loops in the set of rules."
448-4,"passage: A formal system is confluent if whenever A =>* B and A =>* C there exists D so that B =>* D and C =>* D - the computations, once separated, can always be brought back together again. A system is locally confluent if the above is true but for A => B and A => C (i.e a single level decision can be reverted)."
448-5,"passage: In this course, a Formal System is a set of possible configurations (or arrangements) of a system and a set of rules governing the transitions that can be made between these arrangements. Configurations can be represented by data structures, and will be referred to as set D. Rules will be referred to as set R. An example of a formal system is chess - the configuration is the arrangement of pieces on the board (and the information on who's turn it is) while the rules are the possible moves that can be made following the rules of the game. An alternative discussion of the definition of formal systems can be found here."
448-6,"passage: If X and Y are configurations within the set D, X =>R Y means that there is a rule in the set of rules R that will allow the transition from X to Y to be made in one step."
448-7,"passage: A formal system's specification is a statement defining what a formal system should do, for example ""the system should model the rules of chess"". The following criteria are used to judge how well a formal system meets its specification:"
448-8,"passage: While X =>R Y is simple, X =>*R Y can be very complex, and forms the core problem solving activity when dealing with formal systems."
448-9,"passage: Similarly, X =>*R Y means that X can be transformed in to Y using a finite sequence of transitions defined by the rules in R."
449-0,passage: We define a set of symbols:
449-1,passage: Rotations occur as a single 90 degree clockwise transformation:
449-2,"passage: The first two rules are obvious. The third can be demonstrated by comparing the effect of the two strings. Now let's apply the rules to the string ""RFRFR"" in two different ways:"
449-3,"passage: This example has semantics as it has relevance to the real world. A square has four corners, represented thus:"
449-4,passage: These notes are from the second lecture in Dr Richardson's Formal Systems course.
449-5,passage: Let Σ be a finite set of symbols. Σ* is the set of all finite length strings of symbols from Σ.
449-6,passage: Correctness follows from correctness of each rule in P.
449-7,"passage: We will say that our system (Σ*, P) is complete with respect to this interpretation:"
449-8,"passage: We will end up with ""aaab"", as every application of the first rule moves the bs to the right, while the second rule eliminates them. This is a terminating formal system as it can not be infinitely derived. It is also confluent, as no matter what rule you apply you will eventually end up with the same string. Finally, it is locally confluent as any two paths from the same configuration can be brought back together when the final string is reached."
449-9,"passage: We will say that our system (Σ*, P) is correct with respect to this interpretation:"
449-10,"passage: The above rules reduce any word to a normal form RiFj where i = {0, 1, 2, 3} and j = {0, 1}. If these rules are not complete, two (or more) of these normal forms must represent the same symmetry. We could check if this is the case by writing out the 8 possible combinations and comparing them all (64 comparisons) but a better way to check is to look at the properties of the symmatry of a square:"
449-11,"passage: For X, Y in Σ*:"
449-12,"passage: The string ""babbaba"" has four possible transformations:"
449-13,"passage: F and R are transformations that can be applied to the square - Flip and Rotate. When a square is flipped, the top right corner is swapped with the bottom left corner:"
449-14,passage: There are four possible places for the first corner to end up in after a transformation of a square:
449-15,"passage: We can safely claim that our system is terminating, confluent and locally confulent."
449-16,"passage: After the first corner has been placed, there are only two possibilities for positions for the second corner (depending on whether or not the square has been flipped):"
449-17,"passage: So... every word ω ∈ Σ* has a normal form ω =*> RiFj where i = {0, 1, 2, 3} and j = {0, 1}"
449-18,"passage: Once the second corner has been placed, the rules of symmetry mean that the remaining two corners must be placed in specific places. This gives us 2 * 4 = 8 possible configurations, which demonstrates that our formal system for representing the symmetries of a square is both correct and complete."
449-19,"passage: A string in Σ* is a sequance of operations, applied left-to-right. For example, RFRR means ""rotate, flip, rotate, rotate""."
449-20,"passage: The two divergent branches come together at the end, showing the system to be locally confluent. We can also see that the formal system is terminating - the third rule moves Fs to the right where double flips / quadruple rotations will wipe each other out."
449-21,passage: The set of Σ rewriting rules is as follows:
449-22,"passage: A Σ rewriting rule is an expression of the form α ~> β where α, β ∈ Σ*"
449-23,passage: A Σ rewriting system is a finite set of Σ rewriting rules:
450-0,"passage: As you can see, I've posted some more lecture notes. The second set uses a HTML entities to display greek letters, as listed on this page of the HTML 4.0 recommendation."
450-1,passage: There are still a few things I need to iron out with this approach; some categories seem to fit in more than one parent category (PHP is both a programming language and an open source project for example) and having a single archive for all three topic trees could cause confusion for people following permalinks.
450-2,"passage: I've been thinking about various ways of keeping my lecture notes off the front page and out of the way of people who come here for web development related content. My preferred idea at the moment is to replace the current category system (which is in desperate need of an overhaul anyway) with a system of hierarchical categories instead. Categories will be nested within each other - for example, the PHP category will be nested inside the Server-Side Development category. There will be three top-level categories: Web Development, Computer Science and Student Life. The front page of this site will carry only categories contained within Web Development, while the Computer Science and Student Life hierarchies will have separate index pages. The archive pages will contain content from all categories, so only the index pages (and syndication feeds) will serve different content."
451-0,"passage: Another important Lisp variant is Scheme, which threw away everything non-essential in the many Lisp variants and resulted in a cut-down language with a very mathematical approach. Scheme is a very pure and interesting language (at least for Computer Scientists) but some people object to Scheme being labelled a Lisp and see it as a new language inspired by Lisp."
451-1,passage: A shorthand way of writing the above statement is to use a single apostrophe: '(+ 1 2) which is the exact equivalent of the above statement.
451-2,"passage: There are several special Lisp forms. The most important is quote, which allows a Lisp programmer to specify that a list is meant to be used as data rather than executed as code. The quote function returns its arguments unchanged and unevaluated:"
451-3,"passage: Essentially, the only difference between data and a Lisp program is what you do with it."
451-4,"passage: If a variable has no value and you ask for one you will get an error. In Lisp, even errors are objects (data structures) that can be manipulated."
451-5,"passage: There are a very few cases when you will not write Lisp code in the above form - an atom can be written on its own, as can a number (which will stand for its own value). The only time an atom does not stand for itself is when it is a variable."
451-6,"passage: Generally, a function call looks like this: (function arg arg ....)"
451-7,"passage: To get Lisp to execute a statement, the statement must be entered as a list. The first element in the list is a function (or more commonly a variable containing a function, as in the above example where the + symbol contains the function for addition) while the other elements represent the arguments to that function. The addition function demonstrated above accepts two or more arguments in EuLisp, but in other Lisp variants may only accept exactly two arguments (or even be called something different such as plus)."
451-8,"passage: Lisp can be compiled and executed in the same way as C, but it can also be used as an interactive interpreter which runs in a read->eval->print loop:"
451-9,"passage: Lists can be arbitrarily nested. The empty list, () is usually made available by the interpreter in a variable called nil."
451-10,passage: Numbers are not symbols. The following list consists of 3 integers.
451-11,"passage: The above is an example of list syntax in Lisp. The list consists of 5 elements, 4 of which are symbols and one of which is another list itself containing 2 symbols. Symbols are separated by spaces, and lists are deliminated by normal parentheses."
451-12,"passage: The basic data structure in Lisp is the list, which is a sequence of objects. Objects can be atoms or other lists. An atom is an object in Lisp that is not a list and is generally indivisible."
451-13,passage: Conclusion: Lisp is not a single language - it is a whole family of languages.
451-14,"passage: EuLisp is a version of Lisp sponsored by the European Commission in the 90s, partly for political reasons (the American's had Common Lisp) and partly because Common Lisp was a huge sprawling specification while Scheme was so heavily regulated that adding new functions was an almost impossible process. EuLisp was developed (at least in part) by professors now at the University of Bath. It was originally intended to take the position in the market now held by Java but suffered political set backs and never reached its full potential. There is currently a project to create an ISO standardised Lisp version (strongly backed by the Japanese) which has yet to have any impact on the computer science industry."
451-15,"passage: Lisp has a long and complicated history, dating back to the first released version (1.0) in 1959. There are hundreds of versions of Lisp now with many small but significant incompatabilities between versions. Some versions were designed for speed while others were designed for semantic purity. Several attempts have been made to standardise Lisp, including Standard Lisp and Common Lisp."
451-16,"passage: In Lisp, the data and the programs look exactly the same. This is another similarity with lambda calculus where no distrinction is made between the two. This also means that a Lisp interpreter can be written in Lisp."
451-17,"passage: Lisp has a very simple syntax, and is a very simple language. This was important back in the 50s when super computers were less powerful than a modern singing Christmas card."
451-18,"passage: Lisp is naturally recursive - many problems in Lisp are solved using recursion, which is also an important aspect of lambda calculus (where many things are defined in terms of themselves)."
451-19,"passage: Lisp is designed to deal with dynamic data structures. Unlike languages such as C and Java, a list in Lisp can have items appended to it and deleted from it throughout the life of the program without any need for memory allocation code. Lisp implements garbage collection and memory management. It is a dynamically efficient language, specially designed to handle dynamic data structures."
451-20,"passage: Lisp means ""List Processor"". It was invented in 1956 by John McCarthy with the aim of providing a computerised implementation of Lambda calculus, a formal theory of computation devised in the 1920s. Lambda calculus and Lisp are very heavily related. Lisp was invented as a language for manipulating symbols rather than numbers. A symbol has no meaningful value (unlike numbers which have an inherent meaning)."
451-21,"passage: In functional programming, one of the key concepts is that variables are kept as local as possible. This means that functional code should be easy to quickly understand as sections of the code are self contained."
451-22,passage: There are several styles of programming:
451-23,passage: The three themes of the course are:
451-24,passage: This course is about the gapp between computer science theory and practise. It consists of a written exam (75%) mainly on Lambda calculus and coursework (35%) written in Lisp.
451-25,passage: These notes cover the first two lectures of Dr Bradford's Function Programming course.
452-0,passage: There are four design methodologies that relate to usability:
452-1,"passage: HCI is a multi-disciplinary activity. It involves more than just designing software, and ends up being part management consultancy, part anthropolgy and part code hacking."
452-2,passage: How do we get usability? We build it in from the start. Designing for usability is a key part of the development process. It can not be tacked on at the end.
452-3,passage: The usability trinity is:
452-4,passage: Task-based design activities include collecting information on the tasks that users will be completing using the software.
452-5,passage: Another way of looking at the usability design process is the following:
452-6,"passage: People do not like being told to change their working practises, so usability engineering using the above method can be very difficult."
452-7,"passage: This course covers HCI with a heavy emphasis on implementation. We will be developing the interface/interaction components of software using Java, in particular the AWT and Swing toolkits."
452-8,passage: The course will consist of one piece of group coursework and one exam. The coursework will last from week 3 to week 10 of the course.
452-9,"passage: Swing is huge. No one can be expected to know all of Swing, but we will need to be able to use the library documentation to find the classes we need when we need to use them."
452-10,"passage: Usability is functionality. If a user can not use a feature the feature may as well not exist. Usability can be measured through evaluation, which differs from testing in that testing checks that the sofware does what the developer intended while evaluation checks that the software does what the user wants it to do."
453-0,passage: Peter Van Dijck: Future XFML news will be posted on the XFML.org site. XFML 1.0 will be with us soon.
454-0,"passage: Today's weird blogging observation: Bloggers love Peter Gabriel. Jeremy Zawodny is a big fan, Scott Andrew can't wait for his new album, Jeffrey Zeldman praises his sophistication and daypop returns 44 blogs currently talking about him. Despite being good friends with his nephew I've never really listened to him that much, but with glowing reviews such as these I'm tempted to grab the new album and see what the fuss is about."
455-0,passage: Adrian Holovaty: CSS in the real world. Adrian uses CSS to reduce the markup for a list of news headlines by 75%:
455-1,"passage: Which code would you rather work in when there are four breaking news stories on the wire simultaneously and millions of readers are flooding your site, expecting up-to-the-minute updates?"
456-0,"passage: In CSS Design: Taming Lists, Mark Newhouse explains in detail every CSS list trick in the book, including inline lists, nested breadcrumbs and a variety of other useful techniques. He also links to Eric Meyer's essential DevEdge article Consistent List Indentation which explains how to deal with the differences between list indentation in Internet Explorer and Mozilla."
457-0,passage: KPMG.com still sucks in Mozilla.
458-0,"passage: Scott Andrew: XML Transformations with CSS and DOM. Forget about XSLT, Scott demonstrates how CSS can be used to visually style XML documents while a bit of Javascript can add additional behaviour such as clickable links. Unfortunately the demonstration document doesn't seem to work in my 1.1 version of Mozilla (the styles work fine but the clickable links don't work at all)."
459-0,"passage: Hixie has written a whitepaper comparing Pingback to Trackback, and answering pretty much every question that has been asked about Pingback in the past week."
460-0,passage: has a coefficient matrix like this:
460-1,passage: I didn't quite understand this part of the lecture as we arrived late. These are the notes copied from the board.
460-2,"passage: If S is a system of equations, let Sol(S) be the set of solutions. Suppose S1 => S2 by one elementary transformation and α ∈ Sol(S1). Thanks to the rule of interchange that states that two equations (or rows of the matrix) can be exchanged α ∈ Sol(S2)"
460-3,"passage: Ei := CEi, C != 0 then α ∈ Sol(S2)"
460-4,passage: If S1 => S2 by Ei := Ei + CEj then α ∈ Sol(S2)
460-5,passage: In all cases we have α ∈ Sol(S1) -> α ∈ Sol(S2)
460-6,passage: Thus we get Sol(S1) c Sol(S2)
460-7,passage: It is easy to solve a system of equations if its augmented matrix is in reduced echelon form. Here's how to do it with the labelled examples above:
460-8,passage: These matrices are in reduced echelon form:
460-9,passage: The following matrices are not in reduced echelon form:
460-10,passage: A matrix is in Reduced Echelon Form if:
460-11,passage: The system of equations:
460-12,"passage: Note that this final matrix has the identity matrix on the right. This matrix is in Reduced Echelon Form. The presence of the identity matrix shows us that there is a single unique solution to the system of equations. We can read the results off by looking at the columns and rows (remember that the first column is x1, the second is x2 and the third is x3. From this we can deduce the following results:"
460-13,passage: Now we clean up the third column with another pair of row operations:
460-14,passage: The next step is to change the -5 in to a 1 using row 3 := row 3 / -5
460-15,passage: We have carried out two row operations and eliminated x1 from rows 2 and 3. We will now repeat this process but with the aim of eliminating x2 from all but row 2.
460-16,"passage: First we take twice the first row away from the second, then take the first row away from the third."
460-17,"passage: The basic idea here is to use E1 (equation 1) to eliminate x1 from E2 and E3, then use E2 to eliminate x2 from E1 and E3."
460-18,passage: Systems of linear equations can be solved by creating an augmented matrix to represent the system and manipulating it using elementary row operations. The method described here is called Gauss Jordan Elimination.
460-19,"passage: By part 1, S2 => S1 thus Sol(S1) c Sol(S2)"
461-0,passage: Aquarion explains how his automated backup scripts work.
462-0,"passage: Organisations often try to capture the knowledge of their employees in the form of rules and semantic nets stored in a knowledge base, which is another type of organisational memory."
462-1,"passage: People are an essential part of an organisation's memory. The organisational culture is the collection of beliefs, values and attitudes that affect the behaviour of organisation members. People establish social networks of contacts, remembering who they can go to with specific problems or to access specific information. These networks are rarely documented. Knowledge of how to use organisational memory (who to ask about what, where to look things up) is called metamemory, but is often referred to as learning the ropes. Standard operating procedures are also an important part of organisational memory as they help organisations remember how to perform routine activities."
462-2,"passage: An organisations memory exists in many different places, including inobvious areas such as the organisations roles and culture. Successfully designing and applying a data management solution is therefore a highly complex wicked problem."
462-3,passage: Desirable atributes of data stored by an organisation include:
462-4,"passage: Organisations use all kinds of methods for storing data - filing cabinets, notice boards, computer systems and people are all frequently used. Storage devices are organised for rapid data entry and retrieval. Various types of information systems can be used:"
462-5,"passage: Documents are a commn medium for storing organisational data, and can take many different forms such as memos, manuals and reports. Hypertext allows the creation of non-linear documents which help readers find the information they are looking for more rapidly, but take longer to prepare."
462-6,passage: There are companies that provide access to information as a service to other organisations. This information adds to the external memory of a company.
462-7,"passage: Organisations generate, store and process large amounts of data. Data management is the management of this organisational memory."
462-8,"passage: These notes cover chapter one of ""Data Management"" by Richard T. Watson."
462-9,"passage: One person's information can be another person's data, depending on the level of detail required. We finish with some atrocious ASCII-art."
462-10,"passage: Organisations sometimes build mathematical models to describe their business, which can be placed in the broad category of DSS and used to aid the decision making process."
462-11,"passage: Individuals use data management techniques as well. Todo lists, calendars and address books are all examples of external memories (as opposed to our brain which is internal memory). These thre examples also share some common characteristics - they provide a standard format for storing specific kinds of information and they are organised in a way which accomodates rapid retrieval of information. They also requrie a trade-off between speed and size - a pocket calendar can not contain as much detailed information as a desk calendar but is far more conenient."
463-0,passage: A word ω is terminal in P if there is no word Z so that ω =>P Z
463-1,passage: Some examples:
463-2,passage: LZF (Zermelo Fraenkel Set Theory) is a grammar that can be used to represent almost all of contemporary mathematics in very precise (if lengthy) terms.
463-3,"passage: From the above, we can try ""dee wee wap wee wap paa da wee pam"" and see what happens."
463-4,"passage: We've added some extra terms X, Y and Z to help us construct the grammar as the symbols we already have are terminal. Looking at the alien's speech so far everything starts with ""dee"" and ends with ""paa da wee pam"". We will use X as our intial string. Remember that (0) is the empty string."
463-5,"passage: Σ = { da, dee, paa, wee, pam, wap, X, Y, Z }"
463-6,passage: What do you say? Let's work out the grammar for their language (from what little we've seen of it).
463-7,passage: Alien 3: dee wee wap paa da wee pam
463-8,passage: Alien 2: dee wap paa da wee pam
463-9,passage: Alien 1: dee paa da wee pam
463-10,"passage: You have been abducted by aliens. You regain consciousness on their ship, and they speak to you in the followign manner:"
463-11,passage: We need to be able to do the following:
463-12,"passage: Grammars give a succinct and unambiguous description of a language. Programming languages are described by grammars. For something like C this would seem like an almost impossible task but can be achieved by building grammars for simple things such as allowed variable names and C expressions and then moving up to conditional statements, function declarations and eventually whole programs. This takes advantage of the fact that grammars can be used as building blocks in the same way as C macros."
463-13,"passage: The language described above contains all of the expressions that can be built up using addition and multiplication of X, Y, 0 and 1. For example, (((X * Y) + (Y * X)) * X) can be formed with:"
463-14,"passage: Note that we do not make any assumptions about the meanings of 0, 1, + and * - as far as we are concerned they are just symbols."
463-15,"passage: LG = { anbn: n = 1, 2, 3, 4, ... }"
463-16,"passage: Terminal in P = {a, b}*"
463-17,"passage: In this language, any words that do not contain an X are terminal:"
463-18,passage: So only terminal words are included in the language. A formal language is one generated in this way.
463-19,"passage: LG = { ω: I =>*P ω, ω is terminal }"
463-20,passage: The grammar generates the language:
463-21,"passage: A grammar is a Σ rewriting system P together with an initial string I: G = (P, I). The grammar defines all possible words in the language. To generate the language you start with the initial string and apply the rules of the Σ rewriting system in as many ways as possible."
463-22,passage: Let P be a Σ rewriting system.
463-23,passage: These notes are from a lecture on the 26th September.
464-0,"passage: To load a file full of pre-written Lisp code, use (load ""filename.ext""), which is the equivalent of typing in all of the lines from the file at the interactive prompt. Files can be edited and reloaded simply by re-calling the load function."
464-1,"passage: In theory, you can build lists by repeatedly calling the cons function. In practise, Lisp provides a much more convenient method in the form of the list function:"
464-2,passage: Jargon: A proper list is a list that is not empty.
464-3,"passage: If you try to run car or cdr on something that is not a list you will get an error. (car ()) is the source of much debate in the Lisp world - in euscheme it will raise an error, but in some Lisp implementations it will return an empty list."
464-4,"passage: In Lisp, the only built in data structure is the list. Lists are very flexible and can be used to define a whole variety of more complex structures through nesting lists - for example:"
464-5,"passage: Finally, note the difference between '(a b c) and (list a b c) - while the quote method returns the list exactly as written, the list function will attempt to evaluate each argument before returning."
464-6,passage: The length function returns the length of a list:
464-7,"passage: So, if x is a list, (cons (car x) (cdr x)) == x"
464-8,"passage: car = first, cdr = rest and cons is the constructor."
464-9,"passage: 1 and 2 are accessors. 3 is a constructor. The lisp functions that accomplish these operations are called, respectively, car, cpr and cons. These functions take their names from the registers of the IBM 704 computer, which was used by John McCarmack to write one of the first Lisp implementations."
464-10,passage: When you are typing things in to the euscheme interpreter you are actually interacting with a Lisp function called read-eval-print. The debug loop (described below) is itself a recursive call to this interactive function.
464-11,passage: There are three principle operations that can be performed on a list:
464-12,"passage: The language euscheme is written partly in C and partly in euscheme itself. It has a C kernel which handles basic things such as memory management, garbage collection and low level functions such as addition. The rest of the interpreter is written in Lisp."
464-13,"passage: We will be using Eulisp on the course, which was partially developed by professors at the University of Bath who have also written an implementation of the language (covered by a BSD style language and available from here). The easiest implementation to use for educational purposes is called euscheme, which despite the thoroughly confusing name is a Lisp interpreter and not a Scheme interpreter. It can be run on the University unix machines by typing euscheme, and exited by hitting Ctrl+D (sometimes several times if the interpreter is currently in a debug loop)."
464-14,"passage: In euscheme, errors in interpreted code will plunge you in to a debug loop complete with a debug prompt. The debug loop provides additional functionality - type help: at the debug prompt for a list of debug options. The most important debug command is bt: (backtrace) which lists all of the functions that have been called to get to the current state of the interpreter. This can be invaluable for debugging large programs. Another useful command is top: which will instantly snap you out of the debug loops and take you back to the standard prompt."
464-15,"passage: Reminder: In Lisp, all functions are called using (func arg1 arg2 ...) syntax. Language such as C and Java provide two ways of calling functions - function(arg, arg, ...) and infix notation such as arg + arg (the plus sign is really a call to an addition function). Infix notation is quicker to understand initially as it duplicates the way maths is taught at school but it is far more limited than argument notation as it can only ever deal with two arguments. Lisp only has the more powerful multiple arguments method of calling functions."
464-16,"passage: The single quote is important, as without it Lisp would attempt to interpret the symbol 1 as a function which would cause an error."
464-17,passage: Note: Entering length '(1 2 3) without the outer brackets will result in the interpreter evaluating the command as two separate expressions.
464-18,"passage: Typically, Lisp is run as an interactive interpreter. People write a whole load of Lisp in a test file and then load it in to the interpreter and try it out to see if it works. Lisp is a very dynamic language - functions can be redefined on the fly and it is perfectly possible to shoot yourself in the foot (by redefining Lisp internals for example) if you really want to."
465-0,passage: This is the intersection of two planes through the origin in 3D space.
465-1,passage: The steps of the Gauss-Jordan elimination process are as follows:
465-2,passage: Two matrices A and B are row equivalent if A =>* B by elementary row operations. During the process of Gauss-Jordan elimination all matrices are row equivalent to the original and each other.
465-3,"passage: In general, any columns without a leading one of them correspond to a variable that can be any value."
465-4,passage: The difficult part of Gauss-Jordan elimination is the bit in the middle - deciding which columns to manipulate and how to convert them in to leading 1s. Consider a matrix An x m in the middle of the computation. Some number il of rows have leading 1s in them and some number j of columns have been processed. j ≥ il
465-5,"passage: Next step: Increment j. Look in column j for aoj ≠ 0, with i > il - now interchange row i and row il + 1 (if nothing found, move on to next columns. Create a leading 1, then reduce column j."
465-6,"passage: Suppose A is n x m. We can measure complexity by the number of +, -, *, / operations that are carried out. To do this we look at the pseudo code. If we run the main loop m times:"
465-7,passage: So the complexity of the operation is O(mnm) or O(nm2)
465-8,passage: A system of linera equations is homogeneous if all of the constant terms are 0. For example:
465-9,"passage: A homogeneous system in n variables always has the trivial solution x1 = x2 = ... = 0 - so there is no chance that the system will have no solutions, reducing the possible outcomes from three to two."
465-10,passage: A homogeneous system with more unknowns than equations always has many solutions
465-11,"passage: Suppose the system has n equations with m unknowns, and m > n."
465-12,passage: Let A = the augmented matrix
465-13,passage: Find R = reduced echelon form of A using Gauss-Jordan elimination.
465-14,"passage: R has ≤ n leading 1s, so at least m-n of the variables can take any value. This shows that there are many solutions."
466-0,"passage: Given n pairs of numbers [x1, y1], ... , [xn, yn] find the polynomial of degree n-1 that passes exactly through those points. This is useful for plotting graphs."
466-1,"passage: The above (badly drawn) ASCII diagram shows a traffic system. Traffic flows from A to B to C to D and back to A again, with new items flowing in to A, B and D at 10, 20 and 40 items per timeunit respectively. Items flow out of the system at point C at the rate of 70 items per timeunit. We assume that the flow in to each of the nodes on the system is equal to the flow out of that node."
466-2,"passage: This gives rise to the following equations, which can then be rearranged to form a matrix:"
466-3,passage: We can now use Gauss-Jordan elimination to reduce the above matrix to reduced echelon form and read off the results:
466-4,"passage: Note that while x4 can be anything, if we take the one way system in the original diagram in to account we must add an additional constraint stating x4 ≥ 40"
466-5,passage: This will be part of our first piece of Maple coursework.
466-6,passage: A polynomial in x of degree n is an expression of the form:
466-7,passage: a0 ... an are coefficients. There are n+1 coefficients for a polynomial of degree n.
466-8,passage: Regard the coefficients as unknowns. We have n equations:
466-9,"passage: 3 equations and 3 unknowns, so we can now solve it using Gauss-Jordan elimination."
466-10,"passage: Let ƒ be some field (as defined here). Assume that our matrices have elements in ƒ, meaning we know how to do simple arithmetic on the elements within the matrices."
466-11,passage: Let A and B be two n x m matricies (i.e they have identical dimensions). The notation we will use is:
466-12,"passage: So aij means the element at (i, j) in matrix A, and bij means the same but for matrix B."
466-13,"passage: Addition is not defined for matrices of different sizes. Subtraction is identical to addition, but with the - operator instead of the +."
466-14,passage: We will refer to elements of ƒ as scalars. Let c be a scalar and A = (aij)n x m be a matrix. Scalar multiplication is defined thus:
466-15,passage: The number of columns in matrix A is equal to the number of rows in matrix B - this is required in order to perform matrix multiplication. AB (the product of the two matrices) will be an nxm matrix where:
466-16,passage: For example:
466-17,passage: Note that AB ≠ BA but both can be calculated.
466-18,passage: The following matrix demonstrates how 2 x 2 matrix multiplication works:
467-0,"passage: Jeremy Zawodny: FreeBSD or Linux for your MySQL Server? Jeremy explains the differences in threading implementation between Linux and FreeBSD, and explains why Linux is a better option for MySQL databases running under a high load. Link via Scott who got it from Keith. I wonder if anyone has played with the idea of syndicating link-found-on information in an RSS feed? Tracking link trails could be quite interesting."
468-0,"passage: It seems Google have tweaked their algorithm a bit, resulting in several high profile webloggers losing their top ranking positions for a search on their name. Scott Andrew summarises the situation nicely:"
468-1,"passage: So now a number of people are screaming about how Google screwed them. To which I say: whatever. Google is supposed to return relevant results to your search, not just the most popular or linked-to. I mean, why on Earth should I be ranked above McCloud, Orson Scott Card and Coretta Scott King? Because I write about bees on my website?"
469-0,passage: Adrian Holovaty advocates the usage of next/previous link elements on newspaper sites to add optional linear navigation. His comments include some interesting discussions on whether or not this feature would really be of use on that kind of site.
470-0,"passage: A year ago, Mark Pilgrim's manager told him to stop blogging. He refused, and was fired a week later. Today Mark celebrates."
471-0,passage: Mental note: Read Burning Bird's RDF Query tutorial and have a play with the Query-o-matic.
472-0,passage: Mark Pilgrim explains why Google's latest update tweaks (mentioned yesterday) are a lot less harmless than they first appeared.
473-0,"passage: There are several types of function in EuLisp. - and + are both procedures, cons is a subroutine and there are generic functions as well. The differences between these types are minimal. The type of a function can be found by entering it at the interactive prompt:"
473-1,"passage: Modules are a way of structuring programs as independant chunks. These stand alone parts can then be used to construct much larger programs, which is a key principle of software engineering. The default module used within the interactive interpreter is ""user"" - hence the following error message:"
473-2,"passage: Lists and symbols need to be quoted in order to be processed as data. Number, strings, floating point numbers etc all evaluate as themselves. Note that '3 evaluates as the number 3 and not as a symbol - som Lisp versions do allow symbols like this but most do not."
473-3,"passage: You can force symbols with pipes: |3|, |a symbol with a space| but doing so is generally considered bad practise and should be aboided."
473-4,passage: Characters in EuLisp look like this: #\h (for the character 'h'). #\newline is a newline. The string-ref function returns a single character from a string:
473-5,"passage: A vector is essentially a fixed-length list. While normal lists in Lisp are dynamic and can be spread about throughout system memory, vectors stay in a fixed section of memory and are stored together. This makes vectors far more efficient when it comes to indexing operations, which have to be performed recursively on lists. A vector looks like this: #(1 2 3). The vector-ref function can be used to retrieve an element from a vector:"
473-6,"passage: The vector-length function returns the length of a vector, while the string-length function does the same for a string:"
473-7,"passage: Vectors can be created in several different ways. The make-vector function creates a vector of a specified length, and can optionally be provided with a value to pre-populate the vector fields with."
473-8,passage: We can add items to a vector in a specific position using (setter vector-ref). This is our first example of a function that returns a function:
473-9,"passage: The statement returns a because it is the last value evaluated in the expression. The vector has been changed, but we can not see the effect as the vector itself is not returned."
473-10,"passage: EuLisp also has a data structure called table, which is a very useful hash table implementation. Any object can be used as a key for any other object stored in a table."
473-11,"passage: The if expression evaluates the first argument as a boolean and returns the corresponding argument (arg2 if the result is true, arg3 if it is false). There is a slight exception to normal Lisp in that the statement will only evaluate the argument it is going to return. This is an example of a special form. If this were not the case the following code would display both ""hello"" and ""bye"":"
473-12,"passage: In Lisp, every expression returns a value. For example, if is used in the following way:"
473-13,"passage: Hello is displayed twice. The first hello is the result of the print statement; the second ""hello"" is the value returned by the overall expression. This is an interesting demonstration of how the print function acts somewhat like the identity function - it returns its arguments unchanged."
473-14,passage: Note that map returns a newly created list - it does not modify the original list.
473-15,passage: map takes a function and applies it to every element in a list:
473-16,passage: The member function returns the rest of a list after the first occurrence of the specified value:
473-17,"passage: The above code is an example of a nested if statement, and also demonstrates two constants used in Lisp (although constants begin with a # they should not be confused with vectors). #t means true and #f means false. #f is actually a variable containing (), the empty list (also known as 'nil'). In Lisp the only thing that evaluates as false is the empty list - even 0 evaluates as true, which can be a gotcha to new programmers."
473-18,passage: EuLisp gives programmers the ability to define their own error handlers. The default error handler used by the interactive interpreter displays a description of the error and starts the debug loop.
474-0,passage: Statements within the body of the let statement can use local variables assigned in the list at the start of the let segment. Once we exit the let statement the symbols used as local variables return to the state they were in before the let statement was executed.
474-1,passage: Special forms are generally exceptions to normal Lisp syntax that make coding easier and more convenient for the programmer. They are expressions that do not follow the normal rules of evaluation. Examples we have met so far include quote and if.
474-2,"passage: setq is used to set variables in Lisp. (setq x 7) is the Lisp equivalent of x = 7; in other languages. Variables are used far less in Lisp than they are in C and Java, and a program that uses setq a lot is likely to have structural problems. The reason for this is that in Lisp every expression returns something, so variables are far less important. Don't try to write C in Lisp - think about things in a different way."
474-3,"passage: Some older versions of Lisp include a function called set, where (set x 7) first evaluates x, then assigns 7 to whatever was returned by x. This can be highly confusing which is why setq (which automatically quotes the variable for you) is preferred."
474-4,"passage: Variables in Lisp do not have types - you can assign anything to a variable be it a number, string or list without having to worry about the type of the variable. In Lisp the data has the type; in FC the variable has the type and the data is just a bunch of bits which are interpreted in different ways depending on the type of the variable they are stored in."
474-5,passage: defun is the special form used to define a function:
474-6,"passage: In the above example, f is the function name and (n) is the list of arguments taken by the function. The main body of the defun statement contains the statements that should be executed. The function returns the value of the last executed statement in the function body."
474-7,passage: The second example above has the same effect as the first example but works in a different way - instead of applying the function selectivelyan if statement is used to return the required function before it is applied to x. This is a neat demonstration of Lisp's powerful ability to return functions from statements and apply them to data.
474-8,"passage: Just as variables are untyped, so are functions. A function can return any value."
474-9,"passage: While defun is very useful, it is not the most powerful way of creating a function. lambda is a special form which can be used to return an anonymous function - a function with no name."
474-10,passage: The existence of lambda makes defun theoretically redundant. The following expressions are semantically equivalent:
474-11,"passage: In practise however, defun has several benefits due to performance enhancement in the way defun is implemented."
474-12,passage: A good practical use of lambda is as a way of creating functions on demand. Consider the following code:
474-13,"passage: Here function f is acting as a kind of function factory - it is used to create function g, which adds 3 to its arguments. Function f could be called repeatedly to create functions for adding different values. Note that once the above code has been executed g will always add on 3, no matter now often the f function is used to create new functions. This is called closure, and will be discussed in more depth further on in the course."
474-14,passage: when and unless are two more special forms which are both essentially variants of if. Both take any number of expressions as arguments and will evaluate ALL of the expressions (or not) depending on the outcome of the first expression:
474-15,"passage: So unless is equivalent to ""when not"". Both of these special forms are syntactic sugar - they are there purely for the convenience of the programmer."
474-16,"passage: progn is a special form that stands for ""program with no arguments"". It takes a number of expressions and groups them all together in to a single expression that returns the value of the last expression in the group. This is useful for writing if statements that execute more than one expression at a time."
474-17,"passage: progn takes its name from prog, which is a feature that existed in older Lisp versions. prog was a program with variables. This takes us neatly on to our next topic - let and local variables."
474-18,"passage: let is a special form used to introduce local variables. A local variable exists only for the duration of its scope, which in Lisp is the length of the let statement."
474-19,passage: There is an important exception:
474-20,"passage: In the above code the order of evaluation must be taken in to account. The variables on the right of the local variable setting pairs are evaluated first, before the assignments are made. Here, 1 will be assigned to x but the previous value of x (before the let statement began) will be assigned to y. This behaviour can be avoided using let* which is less efficient than let but does not suffer from the feature described above."
474-21,passage: Note that let can be emulated using lambda - the above statement is equivalent to the following:
474-22,passage: This also demonstrates that lambda itself uses local variables - the values of x and y before the lambda statement are left unchanged afterwards.
474-23,passage: Lisp functions in real code tend to look something like this:
474-24,"passage: So functions tend to create their own local variables and use those, rather than risk modifying global variables in unexpected ways."
474-25,"passage: EuLisp (and many other modern Lisp implementations) includes an extensive class structure. The class-of function can be used to find the class of any value or expression. Classes are objects in their own right, so classes can themselves have classes. A function called make can be used to create instances of classes, in conjunction with class keywords which are symbols of the form something:. For example, another way of creating a vector is to use (make <simple-vector> size: 9)."
475-0,"passage: Note that S is underlined to avoid confusion with the variable S. We do not assume that +, -, *, 0 and 1 have their usual meanings. (0 + 0) is not the same as 0, and X is not the same as (X + 0)."
475-1,passage: The above example always ends in cats.
475-2,passage: Final note: Substitutions do not commute.
475-3,passage: These notes are from a Computation III lecture on 2nd October 2002.
475-4,"passage: If ƒ is a function symbol, the number of arguments taken by ƒ is caled its arity. For example, +, - and * have an arity of 2. sin(x) and √ both have arity 1. We can regard a constant as a function with arity 0."
475-5,"passage: A term language consists of all terms which can be formed with a given set of variables, function symbols and constants. The list of function symbols and constants σ:"
475-6,passage: Is called the signature of the language.
475-7,"passage: In the following, a variable is an upper case letter followed by a string of letters and digits. It is assumed that we know the arity and formatting conventions for each function symbol in a signature."
475-8,passage: A grammar for this term language:
475-9,passage: A typical derivation:
475-10,passage: Suppose Tσ is a term language with signature:
475-11,"passage: An interpretation of a term language gives a specific meaning in some function space to each function symbol in the signature. For Tσ the interpretation is a structure (D, ƒ1...ƒj, c1...ck):"
475-12,passage: An interpretation for example 2 could be defined:
475-13,"passage: I1 = (Z, usual +, usual =, usual *, usual 0, usual 1)"
475-14,"passage: In which case ((X + Y) * Z) evaluated for X = 2, Y = 3, Z = 2 would equal (2 + 3) * 2) = 10. However, an alternative interpretation could use the following rules:"
475-15,"passage: This interpretation is perfectly valid as the functions all have the required arity. The expression ((X + Y) * Z) evaluated with X = B, Y = R, Z = B is ((B + R) * B) = R * B = B so the answer would be Blue."
475-16,passage: We may display a term as a tree with function names on the interior nodes and constants and variables on the frontier.
475-17,passage: Derivations may also be written as growing trees starting at the root:
475-18,"passage: We have been talking about grammars generating languages, so grammars can be thought of as growing parse trees from the root down. Evaluations on the other hand seem to go the other way, starting from the frontier and working up. The idea is that all languages work like this - even spoken languages such as English."
475-19,"passage: Speaker - uses a grammar to grow a parsetree top down, then passes the resulting sentence to a listener."
475-20,passage: Listener - evaluates the sentence starting at the frontier and working back up the parse tree.
475-21,passage: This is how parsers and compilers in computer science work.
475-22,"passage: The outermost operator of a term is the function name that appears at the top of the tree. This is first in derivation, last in evaluation."
475-23,"passage: Suppose N is a term in a term language, X1...Xn are variables and M1...Mn are terms. If we wish to simultaneously replace X1 with M1...Xn with Mn in N we can use the following notation:"
475-24,passage: The above operator (the bit in the square braces) is called substitution.
475-25,"passage: Note that if we apply the substitution sequentially rather than all at once we get this: ((X + (X + Z)) + (X + Z)) which is different from the above. In general, M[X1 := M1, Xn := Mn] is not the same as M[X1 := M1][X2 := M2]...[Xn := Mn]."
475-26,passage: An example:
476-0,passage: Leonard Lin has a new HipTop - a hand-held wireless device for browsing the internet. His description of how well different sites work in the device makes for depressing reading. Blogs constructed with CSS and web standards in mind frequently fair worse than less well structured sites - it seems that rather than ignoring the CSS as it should do the device's browser attempts to render it and mangles sites in the process. Anil Dash has an excellent summary of why this is a Bad Thing(TM) for all involved.
477-0,passage: Sam Ruby has pingback. Ping!
478-0,passage: .NET Saves Boy Down Well (via Sam Ruby):
478-1,"passage:
""Once the thing was installed, well, hell, it pretty-much ran itself. I guess that's why they call it 'no-touch' deployment. We just fired that baby up and wizz-bang-a-doodle, it had that boy out of the well in a matter of minutes. Plus, it balanced the department's books, got us some apple fritters and impregnated our receptionist, Mary-Lou. This .NET Framework the cat's meow. Course, we're still not exactly sure what it is. Nobody at Microsoft could tell us, either.""
"
479-0,passage: The following PHP code (or a variation of it) is then used to break the requested URL up in to an array which can then be processed to decide what content to serve the user:
479-1,passage: I am a big fan of logical URLs (as can be seen on this site) - the combination of PHP and Apache makes it easy to have all requests to a specific sub-directory of a site handled by a single script. Here's the .htaccess file for the root directory of my blog:
479-2,passage: Brent Simmon's Law of CMS URLs:
479-3,"passage:
The more expensive the CMS, the crappier the URLs.
"
479-4,passage: The article includes an interesting comments thread discussing human readable URLs and why so many high end content management systems just don't bother with them. There are a couple of interesting links as well: User-Centered URL Design and a useful description of how Vignette StoryServer URLs are structured.
480-0,"passage: I'd also like to reiterate for those of you planning to dig into the source of the fix that it's not an example of completely standards compliant design. It's merely an example of how one person, with a modicum of effort, was able to take an outdated design method and hack in some semblance of standards support in order to take a broken site and make it work in multiple browsers. It isn't perfect, but maybe it's a start."
480-1,passage: Eric Meyer now has permalinks! Now if he would only start pinging weblogs.com when he updated I (and many others) could add him to their blo.gs-powered blogroll.
480-2,"passage: The other day I complained about KPMG.com falling apart in Mozilla. KPMG's web team could do well by listening to Eric, who took two and a half hours to hack together a fixed version of their site. While it doesn't completely adhere to standards it does work cross browser (and the DHTML even works in Opera!). Bare in mind Eric's disclaimer when looking at the code:"
481-0,"passage: On Wednesday, Laurence Lessig will take on the Supreme Court in Eldred v. Ashcroft. He will probably lose, but I sure hope he doesn't. Last night I watched Lessig's <free culture> keynote presentation from OSCon (made available in Flash format by Leonard Lin) with my girlfriend, and I've been catching up on the case with this Wired article and MSNBC's Glitterati vs Geeks. Lessig's blog has some interesting links as well."
482-0,"passage:
Added TrackBack auto-discovery, which can automatically find TrackBack ping URLs based on permalinks in entry bodies. These entries can then be pinged without any extra effort. Inspired in part by the pingback specification.
"
482-1,passage: Moveable Type 2.5 is out. From the changelog:
483-0,"passage: Google News to RSS is brilliant. Simply type in some search terms (or append them to a query string) and the script queries Google News and returns the results formatted as RSS, allowing you to add a customised feed to your aggregator to follow interesting news stories."
484-0,"passage: Lots of news on Eldred vs Ashcroft today. The best account I've seen so far of proceedings in the courtroom is this one by Kwindla Hultman Kramer, who has a press pass and was thus allowed to take notes in the court room. I tried to explain to a house mater yesterday why extending the copyright term is bad for creativity, but today I found this article which does a much better job than I did. Slashdot has some excellent links and a lengthy discussion as well."
485-0,"passage: Virtual Interview: Vince Oostindie (via techno weenie). Vincent is the author of the excellent Eclipse Library for PHP and a regular on the SitePoint forums, where he frequently educates people in programming PHP using OOP methods. The interview is well worth a read if you are interested in either of these topics."
486-0,passage: The css-discuss wiki has finally gone live to the public. Here's my message to the mailing list announcing the launch.
487-0,"passage: Wired have redesigned, and now boast one of the snazziest CSS layouts on the web. The redesign is explained in A Site for Your Eyes, and has already drawn commentary from Jeffrey Zeldman and Mark Pilgrim (with plenty more certain to come). I think the title of Mark's entry pretty much sums it up - this could well be the high profile redesign the web standards movement has been waiting for."
488-0,passage: The author has now resigned / been fired from from the pool of Google Answers researchers (via CamWorld).
488-1,"passage:
The most money still goes to the researcher who answers the most high-paying questions, and this often breaks down into the researcher who is either quickest on the mouse or less principled about the weak points in the site mechanics.
"
488-2,passage: Information for Sale: My Experience With Google Answers is a fascinating insight in to the world of Google Answers:
489-0,"passage: They've already lost the argument. The Web is tag soup. People use blockquotes to indent. Even though the REST folk argue that it's anti-Web to do RPC, people do RPC anyway. There's a never-ending list of complaints, but they can be resolved. That's why I'm writing this little essaylet."
489-1,"passage: Sometimes you invent something thinking you know how it's going to be used, and the world surprises you and uses it for something else. It's happened to me. I designed my first outliners to be ""idea processors."" To make a long story short, more people used outliners to create presentations. Eventually I tired of being right and wanted to make money, so we developed the idea, people loved it and we made our shareholders rich, and everyone lived happily ever after."
489-2,"passage: I think Dave's missed some important details on this one. Firstly, just because something can be used for a particular purpose does not make it the right tool for the job - in the case of HTML blockquotes CSS provides a far superior method of achieving indentation without having to add meaningless code to the site's markup. Dave is right in saying things often end up serving a different purpose to that for which they were intended but that doesn't necessarily make it a good idea. It sounds like Dave's outliners were a great tool for presentations without meaning to be - blockquote is not a great tool for indenting; it gives you no control over how large the indent will be and doesn't even guarantee an indent in non-mainstream browsers."
489-3,passage: Dave Winer: What is Tag Soup?
490-0,"passage: Paul Freeman has a clever new feature on his blog: List o Links, a list of links that he wants to record without writing up a full blog entry. I'm tempted to borrow the idea (which originated with Anil Dash) but I'm slightly put off by the problem of integrating it with my existing blog archives. For the moment I think I'll borrow Mark Pilgrim's technique of occasionally posting ""catch up"" entries with a bunch of blog-worthy links."
491-0,passage: Catch up time...
492-0,"passage: Here's a fun new way to waste time on the internet: Scamming Nigerian spammers. This guy has a whole bunch of entertaining email exchanges with Nigerian scam artists, but the best has to be the Cthulu themed scam. Watch the Nigerian scam artists get slowly sucked in to a world of cults, demons and unspeakable horror."
493-0,"passage: Python 2.2.2 is out. It's mostly bug fixes, but they have also included the latest version of the Python email package. I've been playing with Python's email features recently as part of an experimental idea to import all of my mail (from various accounts) in to a mySQL database and build my own web mail / mail application program. Working with email in Python is beautfully simple, thanks to the aforementioned email package and the powerful pop3 and IMAP classes in the standard library."
494-0,"passage: While this looks like being an excellent feature, I'm slightly concerned by a couple of aspects of the implementation. Firstly, I don't understand the necessity for following rel=""next"" links as well as rel=""prefetch"" ones. A ""next"" page does not necessarily mean the user will go there - in fact, thanks to the big accessibility drive at the moment many sites are adding rel=""next"" elements that follow the logical order of the site without making it any more likely that a user will follow them. A key example of this is weblog archives - many blogs have next/prev link elements to indicate the next and previous archive pages. Few readers will ever folow them but they are there because they reflect the logical structure of the site."
494-1,"passage: In addition to this restriction, URLs with a query string are not prefetched. This is done because such URLs often result in documents that cannot be reused out of the browser's cache, so prefetching them often has little benefit. We found that some existing sites utilize the <link rel=""next""> tag with URLs containing query strings to reference the next document in a series of documents. Bugzilla is an example of such a site that does this, and it turns out that the Bugzilla bug reports are not cachable, so prefetching these URLs would nearly double the load on poor Bugzilla! It's easy to imagine other sites being designed like Bugzilla, so we explicitly do not prefetch URLs with query strings."
494-2,"passage: The Mozilla Link Prefetching FAQ (via Blogzilla). Prefetching is a browser mechanism, which utilizes browser idle time to download or prefetch documents that the user might visit in the near future. Web page authors can turn on prefetching for their pages using a <link rel=""prefetch""> or <link rel=""next""> element (or the corresponding Link: headers). "
494-3,"passage: In these days of URL rewriting and dynamically generated sites this just doesn't make sense - what would happen if the next version of Bugzilla used URL rewriting to have ""proper"" links to each bug description rather than query strings? In my opinion, a better solution would be to forget about rel=""next"" links entirely and instead rely only on rel=""prefetch"" elements. That way authors of dynamic sites can enable prefetch if they know it will not be broken by their dynamic pages, while sites like Bugzilla that use a rel=""next"" element will not be adversely affected."
494-4,passage: My second complaint is with this part of the FAQ:
495-0,"passage: Dynamic HTML, 2nd edition is out (via Joel on Software). I want it."
496-0,passage: Dorothea Salo skillfully explains her theory of where soulless PR flacks come from.
497-0,"passage: ContentEditable for Mozilla is a hot topic at the moment. The main focus of the debate is this bug on Bugzilla, which gets pretty heated. Blogzilla has a good explanation of the principles behind the disagreement, while Scott Andrew makes an excellent case for copying IE's implementation:"
497-1,"passage:
To my knowledge, no W3 working group is discussing how to implement editable content directly in a Web page, so the question remains: do we follow IE's de facto standard, or wait for a standards body to hammer out one?
"
498-0,"passage: 50 XSLT Tips. I particularly like Tip 13, whish shows how you can use a recursive template call to print things out multiple times (for example, 5 asterisks for something with a 5 star rating)."
499-0,"passage: Eric Meyer on CSS: Tricking Browsers and Hiding Styles. This bonus chapter which was not included in the book explains the various techniques that can be used to hide CSS rules from browsers, including the high pass filter and the infamous voice-model hack. Eric has also published Picking a Rendering Mode, a comprehensive guide to DOCTYPE switching and the effect it has on modern browsers."
500-0,passage: Richard also wrote this article for Salon describing the Bookmobile and how it relates to the Eldred case.
500-1,"passage: I first read about the Internet Bookmobile last week on Aaron Swartz' Weblog. Lessons from the Internet Bookmobile is a new article on the O'Reilly Network by Richard Koman, who spent the week preceeding the opening of the Supreme Court Eldred vs Ashcroft case travelling with the bookmobile as it made it's way up from San Francisco to Washington, stopping off at schools and libraries along the way to demonstrate the importance of the public domain. The article discusses the potential effect cheap book printing technology combined with the internet and the public domain could have on schools, libraries and even commercial publishers:"
500-2,"passage:
In fact, the Bookmobile's message, in essence, is that these are books we can put in the hands of children, through schools, and we can do it at a very low cost. (The material cost for a black and white book with color cover is $1.) We can create large-print versions of these books and put them in the hands of senior citizens, and we can deliver them to their homes or to retirement centers. We can transform libraries into public-domain printing plants. And we can enable commercial publishers to create new products that attract new customers, both young and old.
"
501-0,passage: One for the bookmarks: O'Reilly's Alphabetical Directory of Linux Commands. 379 commands complete with a description and list of command line options. Found via an advert on the Internet Bookmobile story (and I usually never click on ads).
502-0,passage: I spent the last few days setting up a home network. I'm living in a student house with 4 other people and we recently shelled out for a 1 Mbit cable connection fron BlueYonder. I had never built a network before but neither had anyone else so the task of putting it all together fell on my shoulders.
502-1,"passage: I'll get straight to the point. Dachstein (an offshoot of the Linux Router Project) is sheer magic. Having wired up the whole house through our 8 port switch I realised that BlueYonder only allow you to connect one PC at a time to the cable modem; we needed a router. Dachstein is a linux-router-on-a-disk - all you need is an old PC with a floppy disk drive and a couple of network cards (no hard drive required). You download a windows executable and run it, insert a floppy disk and the software creates a router disk for you. A few configuration steps later (mainly to do with selecting the correct drivers for your network card) and you have a fully functional, ultra secure linux router. Simple - at least, it would have been simple if BlueYonder's system for adding a new Ethernet MAC address to the list of addresses supported by the cable modem actually worked. As it was I ended up having to transplant the network card from my already configured desktop in to the router, but once that was done everything worked a treat."
502-2,passage: My next project is to add an SSH daemon to the router so I can log in and play with it without plugging in a monitor and keyboard. Luckily the LRP has an excellent documentation site which includes a step by step guide to getting SSH running.
503-0,"passage: CD Zapping: Take one CD, Microwave at full power for 5 seconds, and place on top of tesla coil. Enjoy!"
504-0,passage: Generating XML and HTML using XQuery (via More Like This). I had been confusing XQuery with XPath - it turns out XQuery is a fully featured scripting language which can be used to do all kinds of things with data from XML documents. The article explains how XQuery can be used to build a web photo gallery application and compares XSLT and XQuery using a Docbook transformation example.
505-0,passage: Joel Spolsky explains why Microsoft's Terminal Services performs far better than the open source WinVNC. Stuart points out that simple economics can make VNC a far more viable option in many situations.
506-0,passage: Some useful Linux Router Project links:
507-0,"passage: HarryF on the SitePoint forums has compiled a fantastic list of Advanced PHP Resources, with links to sites covering object orientation, general application design, n-tier layering and using PHP with XML."
508-0,"passage: I'm not sure when it happened, but Opera.com has been redesigned (since the last time I checked the site). The new layout is done with valid XHTML and CSS but is decidedly tabular in appearance, demonstrating that using CSS does not (as some people have claimed) make it impossible to achieve the same kinds of layouts as table coders have been creating for years. It also degrades quite nicely in Netscape 4 (losing most of the layout but maintaining a crisp look and feel). In related news, Jeffrey Zeldman is currently redesigning The Daily Report with CSS (replacing his old transitional tables/CSS layout). No menu yet, but it displays in Netscape 4 almost exactly the same as Mozilla and IE."
509-0,passage: See also this C-Net article.
509-1,"passage:
Content reformatting - Instead of presenting table content in columns and rows, tables are reformatted into a one-dimensional structure that better fits smaller screens. Opera can selectively scale down large images or remove those that are superfluous, as well as some other tricks that make the pages fit small screens. And as a result, the user has no need for a horizontal scrollbar.
"
509-2,passage: Opera Small-Screen Rendering (via Leonard):
510-0,"passage: Qube looks pretty cool - it's an open source first person shooter engine (and simple deathmatch game) designed specifically for mod developers. The client runs on both Windows and Linux, but the game server is Linux/BSD only. Spotted via this article on the O'Reilly network."
511-0,"passage: Douglas Bowman's weblog is making very interesting reading at the moment. Douglas is responsible for Wired's exciting new design and since the launch has been updating with observations and lessons learnt from the new look. On Friday he described how changing a problem with a design element took less than 60 seconds (thanks to global CSS files), but the post that caught my attention was this one:"
511-1,passage: I had the exact same problem with this blog. My solution was to throw every entry through PHP's XML parser when it is added - if the XML parser throws an error a warning message is displayed to encourage me to validate the page and re-check the entry. I imagine Wired's content management system requires a slightly more elaborate solution than that but for my small scale needs it has been working a treat.
511-2,"passage: Somehow, we have to avoid the constant manual check of pages and retroactive fixes of existing errors. This method is unreliable and time consuming. I'm sure the engineers will be making modifications to our content insertion tool, so that validation errors like naked ampersands can be automatically detected and corrected as they're entered.
"
511-3,passage: [snip]
511-4,"passage:
However, daily editorial additions continue to allow XHTML validation errors to sneak into the Wired News markup. The most frequent culprits are the ampersands (&) which separate name/value pairs in URL query strings, or which commonly appear in our English language in company names like AT&T or slang acronyms like R&D."
512-0,"passage: Via Adrian Holovaty I discover Craig Saila has an excellent weblog, and is now pinging blo.gs whenever he updates. A welcome addition to my blogroll."
513-0,"passage:
What is Microsoft going to do with this money? They can't spend it fast enough internally, and the top shareholders, who control the company, refuse to issue dividends (this saves Bill Gates et al billions in taxes). Prediction: Once Microsoft is out from under what's left of the antitrust case, it'll go on a strategic investment and acquisition spree the likes of which you cannot even imagine.
"
513-1,passage: Scary.
513-2,passage: Dan Gillmor: Microsoft Piggy Bank Tops $40 Billion:
514-0,passage: The RSS Validator. My RSS feed validates - does yours?
515-0,"passage:
Well, there is one difference between what Opera does and what Mozilla could do. We could do it much better.
"
515-1,"passage: Yesterday I blogged Opera's impressive looking small screen rendering technology. Now take a look at this (via Blogzilla). Daniel Glazman has created a Mozilla bookmarklet that does everything Opera's implementation claims to achieve using a combination of a custom style sheet and the DOM, and the results are impressively similar to Opera's demonstration. The difference?"
516-0,"passage: I'm writing a simple events calendar system at the moment, and since I always seem to end up making things more complicated than they should actually be I've been investigating using the iCal standard as the file format for storing events (I need a flat-file format due to hosting requirements). I'm particularly interested in the XML flavour of iCal, although it seems to be a lot less popular than the semicolon deliminated original standard. Mainly for my own reference, here are the sites I've trawled through this afternoon:"
517-0,"passage: Introduction to CSS shorthand properties (via webgraphics, via Glish)."
518-0,"passage: Spotted in Ordinary Life's new bookmarks, the Web Style Guide is a full online book covering all kinds of different aspects of web design. I've only glanced through it so far but it appears to have some excellent material on the design process, typography and editorial style. There is a good focus on usability and accessibility but web standards don't really get much coverage, and CSS for layout is discouraged in favour of tables for reasons of browser support."
519-0,"passage: I've got my own theory. I don't use Word very often, but when I do I use Word '97 - the same version of Word I've been using on and off for the past 5 years. My girlfriend uses '97, the PCs in the Library at University use '97 and I'm guessing it has a pretty large penetration. Why? Because as far as I can tell Word really hasn't improved that much since then. Word '97 has all the features most people could possibly want from a word processor, leaving very little incentive to upgrade."
519-1,"passage: Enter XML. With the XMLisation of the Word format Microsoft has suddenly provided people with a real incentive to move away from older versions of Word - XML is (still) the ultimate buzzword and IT departments and those who make the buying decisions for big companies are likely to instantly spot the benefits of the new format: Better (potential) interoperability and less lock-in to MS products. Meanwhile, Microsoft can concentrate on locking up the filesystem instead."
519-2,"passage: Co-Inventor of XML Says Office 11 is ""A Huge Step Forward for Microsoft"" (via Slashdot). The comments are full of speculation over why Microsoft would open up their file format in this way having gained so much from having an obfuscated format."
520-0,"passage: Uzilla costs a fair whack ($2350 for a 3 test commercial license, discounts for non-profits and academic use) but looks more than worth it for large companies. The software was developed (at least in part) by Andy Edmonds, the guy behind Mozilla's excellent Mouse Gestures add-on."
520-1,passage: Uzilla (via SurfMind) is a commercial product built on top of Mozilla:
520-2,"passage: I've been learning about usability testing as part of a User Interface course at Uni. One of the principle methods of usability evaluation is to observe users as they work through a set of tasks. Uzilla consists of a web application for designing the usability test (survey questions, task lists), a modified version of Mozilla which displays tasks to the user and tracks everything they do within the browser and a set of tools to help analyse the user's behaviour. Details on the visualisation part of things are sketchy at the moment but it looks like SVG is used to visualise the user's individual mouse movements (lots of pretty lines and coloured dots at any rate)."
520-3,"passage:
The Uzilla suite is a set of tools for web based usability testing. It decreases the time and effort required set up and do usability testing while increasing the accuracy and power of the data collected during testing. Uzilla makes the job easier for both usability practioners and webmasters.
"
521-0,"passage: Jeffrey Zeldman's new design continues to develop, but remains virtually unreadable on my monitor (without extensive tweaking of the settings). I'm not griping though as this was an ideal opportunity to play with Mozilla's DOM inspector. This handy tool allows you to load up a page and browser through the DOM of the page, tweaking as you go. More importantly, it lets you modify the CSS rules for each individual element. It took a matter of seconds to fire up the inspector, browse down to the CSS rules for the body element and change the colour setting to rgb(255, 255, 255) - not particularly pretty but a lot more readable on this monitor than the default black. Of course, a bookmarklet to do the same thing would be much more convenient..."
522-0,passage: Craig Saila:
522-1,"passage: I've been saying (offline) for a long time that what the web really needs is a micropayment system backed by a huge (and trustworthy) financial company. This could be just the break the micropayment movement needs. I'm still slightly worried by the implementation details; for micropayments to work there needs to be a single-sign-in mechanism of some kind and anything like that is likely to have all kinds of security and privacy concerns. Then again, the Amazon tip-jar / honor box model has been working pretty well since its introduction. It'll be interesting to see where this goes."
522-2,"passage: In the ""Wouldn't it Be Great"" category: Vin Crosbie, in a posting to online-news, says he’s been hearing rumours that next month MasterCard and Visa will start handling small (micro?) transactions online."
523-0,"passage: Here is a scene that happens at some point in almost every young company. The founder/CEO/technical visionary meets with his board and finds him or herself out of a job. How could this happen? Well, the company has grown to the point where the board feels that ""professional management"" is required, so they are bringing in a new management team. The new team is composed of old friends and classmates of the board, and the new team costs five to 10 times as much, but that's okay because the company is ""hiring for growth."" This new team cuts staff, cuts costs and outsources everything that can be outsourced, with the result that earnings are improved and the stock goes up or the company makes itself look better for an Initial Public Offering. The professional managers get big bonuses, they exercise mountains of stock options, sell those option shares, then go on to some other, even bigger, job having ""saved"" the company, which then stagnates, goes into a slow decline, and is eventually acquired by a competitor."
523-1,passage: Bob Cringely: The Case Against Professionalism:
523-2,"passage: This is a scary article - it demonstrates how short sighted modern management techniques are, and how they benefit those involved at the expense of the long term future of the company. It doesn't help my geeky distrust of management much either."
524-0,"passage: Spotted on Jeremy Zawodny's blog. As a side note, the site uses the wrong form method - it uses POST when it should be using GET. GET would allow people to bookmark their queries."
524-1,passage: Googlism knows too much:
525-0,"passage: Kevin calls these scripts ""scriptlets"" and has posted an example scriptlet that can insert the current date and time straight in to any text file opened with the PythonCard codeEditor."
525-1,"passage:
The entire object model of a PythonCard application is exposed, so if an app doesn't have the feature you want, you can probably extend it with a short ""macro"" in Python. All scripts are run in the shell, so they share the shell namespace and thus scripts can share variables since the namespace doesn't go away until the application is closed.
"
525-2,passage: Kevin Altis on scripting applications written in PythonCard:
525-3,"passage: This is an interesting train of thought. Scripting languages such as Python undeniably lead to faster development times (no compile cycle, less book keeping syntax to worry about) and as computers continue to get faster and cheaper the overhead associated with these languages becomes less and less important. Kevin's concept of an application with an exposed object model that can be tweaked by the user is a powerful idea, and one that could bring real benefits; Python is not a difficult language to program in, and applications which can be scripted easily can become very popular (just look at the mIRC community for an example of that). Unfortunately the ability to script an application also leads to inherent security flaws, as have been seen with VBScript and Microsoft Office - although in the case of Office most of the problems stem from the ability to add macros to individual documents (there are surprisingly few mIRC security alerts despite the in built scripting engine)."
525-4,"passage:
While Java and C# battle over who is the rightful successor to C++, it is quite possible that a language like Python (or, dare I say it, Ruby) will ultimately be the one that wins out.
"
525-5,passage: Sam Ruby was recently quoted as stating the following over on Jon Udell's blog:
526-0,passage: It's probably a good idea to keep axes and Jack Daniels away from Jason Kottke for the next few days...
527-0,"passage: tidakada has redesigned, with a funky new 4 column CSS layout and a brand new blog o' links."
528-0,"passage: I really hope this doesn't lead to bloggers insisting on registration before people can post comments. Phil's suggestion of built in flooding detection looks like the best solution for the moment, and I'm sure Moveable Type will be quick to implement it (as always)."
528-1,"passage: I suppose it was only a matter of time. Phil Ringnalda reports on a spam attack on his blog in which a spammer used a script to systematically spam the comments section of every entry, using a piece of code targetted at Moveable Type. Phil cut the spammer off after only 120 spams (and used mySQL to wipe out the spam in a few seconds) but this is still a very worrying precedent. Back in August I blogged a spamming company that targetted simple web based bulletin boards like WWWBoard - it looks like they (or someone like them) have discovered blogs."
529-0,passage: Scott Andrew calls for an XML-RPC or SOAP interface to the new W3C HTML Validator (currently in beta). I've been hoping for something for this like ages - if the W3C don't do it it would be great if someone else set this up (the validator is open source but the bandwidth required for such an undertaking would probably be pretty high).
530-0,"passage: I haven't been checking my referrer logs recently, so it was a nice surprise to see that Richard from Incutio has finished redesigning his blog and is now back to updating it frequently. He also has Pingback (implemented using IXR) and is pinging blo.gs when he updates."
531-0,"passage: Apple have an excellent site called Internet Developer, with articles covering a wide range of web development topics from HTML and CSS right through to Using SOAP with PHP."
532-0,"passage: I had a play around and the XML interface works pretty well, although it still has a few quirks (hardly surprising for a beta product) - the information on whether or not the page is valid is passed back in an HTTP header (X-W3X-Validator-Status) and if the page is unreachable or forbiden the interface returns an XHTML document. Still, it's enough to play with, and as a demonstration of the flexibility of this new tool I've put together an XML-RPC proxy for the service:"
532-1,"passage: I've also coded in a 100 queries / IP / hour limit, in the unlikely event that the service gets a large amount of traffic. I should stress that this is a beta web service built on top of a beta validator - it may stop working at any time, so it should not be considered suitable for production use. If you want to use it heavily feel free to download the source and set it up on your server, but remember that the W3C beta validator may well change it's XML output rendering the web service useless."
532-2,passage: The source code for the web service is available in the following files:
532-3,"passage: The web service accepts a URL and returns an XML-RPC struct containing the results of validation. The most important field of the struct is status, which will be set to Valid, Invalid or Failed depending on whether or not the page passed the test (Failed means the validator threw back an XHTML page rather than XML, and can generally be assumed to mean the page has failed validation for some reason). The other fields of the struct contain information returned by the validator, including an array of warnings and an array of error messages if any were returned. The structure of the struct can be best understood by comparing it to the XML returned by the standard XML interface."
532-4,passage: http://validator.w3.org:8001/check?uri=http://simon.incutio.com/&output=xml
532-5,passage: Earlier today I mentioned how useful a web service interface to the new W3C validator would be. Tom Gilder pointed out in the comments that the validator now has an XML interface:
533-0,"passage: Making the Case for PHP at Yahoo! (via Jeremy Zawodny) looks like it was a great presentation. The slides include the reasons PHP was chosen over ASP, ColdFusion, JSP and Perl and has some interesting details on the history of Yahoo's server side technologies. Jeremy has extensive coverage of PHPcon so be sure to flick through some of his recent entries while you are there."
534-0,passage: Scott Johnson's presentation on Software Engineering Practices for Large Scale PHP Projects is fantastic - lots of excellent practical advice for professional development with PHP. It's a shame the presentation slides require Internet Explorer (due to being exported from Power Point) but it was more than worth firing up IE to view them.
535-0,"passage: Roll on the micropayment revolution! Cashets are designed specifically for the small purchases - $1 (or less) - that you ordinarily can't make on the Internet because sellers have a minimum. The smallest amount you can charge using the system is 2 cents, of which 1 cent will go to Cashets and 1 cent will go to you, the seller. The 1 cent is a flat rate for sales up the a dollar, then it's 2 cents for sales up to 2 dollars and so on up the maxiumum charge of 5 dollars. The company is owned by MasterCard founder Michael Phillips and two unnamed partners who are ""computer professionals"". The site is atrocious (the text on the front page is a big gif with no alt text ffs) but the business model looks like it could just be the thing small-to-medium web sites have been waiting for."
536-0,"passage: Hehe, this reminded me why I don't use IE any more :)"
537-0,"passage: As I said in my post announcing the web service interface, it may stop working at any time. Treat it as an experiment / proof-of-concept and you won't get burnt if/when it breaks."
537-1,"passage:
This interface is highly experimental and the output *will* change -- probably even several times -- before finished. Do *not* rely on it!
"
537-2,"passage: As Scott Andrew has noted, the W3C's beta validator is now returning the following warning as part of it's XML output:"
538-0,"passage: Mark Pilgrim has posted another of his signature in depth explanations, this time concerning the recent worries over blog comment spam. He points out that all of the proposed solutions are Club solutions, not Lojack solutions, meaning they directly help those who implement them, possibly at the expense of others who do not. He then ties this in to game theory and the classic Prioner's Dilemma problem."
539-0,"passage: Dorothea has posted two more excellent rants on the subject of ebooks, archiving and the importance of a single standard for master files (as opposed to a single standard for end user files which is a lot less important)."
540-0,"passage: Slashdot have a story up linking to the Yahoo PHP presentation (mentioned earlier). The comments are pretty much an all out lanuage holy war, but the following comment explaining why Perl's ""There's more than one way to do it"" is a disadvantage when trying to write maintainable code caught my eye:"
540-1,"passage:
As they pointed out ""there's more than one way to do things"". For maintenance programming, this means that you have to know every way of doing things, or you aren't going to be able to read all the code.
"
541-0,"passage: Craig Saila has launched his latest project, Trade by Numbers, which uses valid code and (Netscape 4 friendly) CSS for layout. The CSS code is worth looking over for the intelligent use of browser hacks, all commented. Writing Netscape 4 compatible CSS is still something of a mysterious art form, but documentation is steadily increasing with useful resources such as Craig's list of NS4 CSS layouts and Mark Newhouse's Real World Style. The tips on NS4 compatibility in Cascading Style Sheets: Separating Content from Presentation are also invaluable for anyone who is serious about CSS but still has to support legacy browsers. I have yet to produce a NS4 compatible CSS layout but I'm beginning to realise that it's not quite as impossible as many people make out."
542-0,"passage: Jeffrey Zeldman has resolved his niggling CSS bugs, and posted the workarounds for all to see. What's amazing and unprecedented about CSS layout is that it's completely abstracted from the data it presents. he muses. Dorothea Salo points out that the publishing industry has been doing this for hundreds of years. Meanwhile, Todd Dominey has overhauled his CSS to get rid of the javascript browser detection and Mark Pilgrim and Scott Andrew have both posted funky Halloween CSS makeovers."
543-0,passage: I just noticed that the RSS validator is using my numbered code listing CSS experiment :)
544-0,"passage: Adrian Holovaty has followed up his discussion of page titles on news article pages with a look at the oft-abused pull-quote. Adrian points out how pull quotes can lead to poor accessibility for text browsers and screen readers, and suggests that providing a ""skip quote"" link could help improve things. Adrian's comments section attracts a number of professional web deverlopers working on all kinds of news sites so the discussion is likely to be well worth watching over the next few days."
545-0,"passage: Linux Gazette has a couple of interesting Python articles at the moment. Dealing with User Input in Python is a beginners guide to validating user input, while Pl/Python and Cursors in Pl/Pgsql for PostgreSQL explains how Python can be used to write stored procedures in PostgreSQL."
546-0,"passage: Phoenix 0.4 is out, and it's so good it has replaced Mozilla as my default browser. Type Ahead Find makes browsing links and searching pages a dream (I've really come round to it after my initial whinge) but my favourite feature is the Google ""I'm Feeling Lucky"" integration built right in to the address bar. Type in a single word and Phoenix will try word.com (and possible word.org/word.net) before passing it on to Google and redirecting to the first search result. Type in multiple words and I'm Feeling Lucky is invoked straight away. Normal Google searches can be run from the smaller Google field to the right of the address bar. It all adds up to a virtually seamless browsing experience, especially now that I've memorised the Google URLs of most of my favourite sites."
547-0,"passage: I think this is the classic business case for open source software - pay software engineers to buld custom solutions from freely available (open source) components. The engineers make a good living, the company gets good software and hopefully some more open source material is fed back to the community as a result. Is the market really heading that way? A lot of very smart people seem to think so. The next few years could be very interesting indeed."
547-1,"passage:
That's over, and it's not because a pile of overfunded dot-com fantasies crashed to the ground. It's over because the market doesn't want it any more. The market wants something more like professional services--architects, designers and builders. Good businesses all, but not the kind that are ""venture scale"", as they say.
"
547-2,"passage: Doc Searls is back from the Linux Lunacy cruise, and has been talking about the future of the software industry in What I learned on Linux Lunacy:"
548-0,"passage: I've been reading up on the Jakarta Struts MVC framework, courtesy of Simon Brunning. Struts, an open-source MVC implementation is a great starting point, and the ONJava JSP/JSTL series (also found via Simon) were very informative as well."
549-0,passage: Javascript form button games (via CamWorld). These have to be seen to be believed.
550-0,"passage: Rescuing XSLT from Niche Status is A Gentle Introduction to XSLT through HTML Templates. It is something of a hybrid article, consisting of a discussion of the problems involved with both teaching and learning XSLT followed by an excellent (if somewhat brief) tutorial covering the most important XSLT tags and concepts and how they can be used to convert a simple XML document in to XHTML."
551-0,passage: More examples of this new-wave style of DHTML can be found in youngpup's Labels.js: A Re-Introduction to DHTML and Stuart's excellent aqTree2.
551-1,"passage: The trend for DHTML using structural markup and the DOM continues with Using Lists for DHTML Menus. Dave Lindquist uses identical XHTML markup combined with two different sets of JavaScript and CSS to implement both a set of dropdown menus and an expandable, tree style menu. The code is standards compliant and remarkably lightweight (menuExpandable.js weighs in at less than 20 lines) and fully accessible thanks to intelligent use of the accesskey attribute."
552-0,"passage: Joe is a graphic designer with more than 20 years of experience and the fresh perspective he brings to CSS is inspiring to say the least. Unfortunately, as you might expect from a designer who has always worked in terms of ""gnat's whiskers"" (netdiver interview), he is also a Font Bitch. I've recently found myself resizing text on web sites several times a day (not because they are unreadable but because it makes them more comfortable to read) so Mozilla's ability to resize even absolutely sized fonts is something of a God-send."
552-1,passage: Joe Gillespie has been introducing CSS to the readers of Web Page Design for Designers.
553-0,passage: What the frell is the Semantic Web? (via tidakada):
553-1,"passage: Imagine a document containing exactly all of the same info your weblog page presents - only the data is completely, easily accessible to a robot in a universal, easily handled format."
553-2,"passage: Furthermore, imagine that the schema describing the data to be found on your page is in that same format. And then, imagine that the document describing the construction of schema is in that same format. And then imagine that the decomposition continues, all of the way down to base data types and relationships. Eventually, the whole thing rests on the back of a turtle - er I mean a sort of universal client."
553-3,"passage: This is the best introduction to the semantic web I've seen. I thought I'd ""got it"" after reading August 2009: How Google beat Amazon and Ebay to the Semantic Web but the idea of decomposing the relationships down to something universally understandable only just clicked (also thanks to a course on Logic and Semantics I am taking at University at the moment). I think I get RDF tuples now as well (there's a good introduction in this document)."
554-0,"passage: Inline XML explains how different XML languages can be embedded in XHTML documents using namespaces, and how they can then by styled using CSS."
555-0,passage: Further information on OperaShow can be found here:
555-1,passage: I wonder if Rasmus Lerdorf has considered building OperaShow support in to his PHP Presentation System.
555-2,passage: While playing around with the technology I found the following OperaShow enabled presentations:
555-3,"passage: It's been a while since I last looked at 30 Days to becoming an Opera Lover so it was a nice surprise to see that not only is the series now complete but Tim has started up blog to continue the momentum. Flicking through the days I hadn't read before the single feature that impressed me most was OperaShow, described on Day 17. OperaShow is a variant of the full screen mode present in IE and Mozilla, but with the added ability to run PowerPoint style presentations. This is implemented using CSS and the projection media type, in conjunction with the page-break-before : always; CSS property. Opera defaults to rendering the page normally (with whatever screen/all stylesheet the page author has provided) but as soon as you press F11 the projection style sheet comes in to effect. PgDown / PgUp can be used to cycle through the ""slides"" and the whole thing works just like a PowerPoint presentation."
556-0,"passage: The positives? Well, it works in Netscape 4. Wake up and smell the coffee guys, 1996 was a long time ago."
556-1,passage: Zend (the commercial company behind the PHP scripting language) have launched a redesign of Zend.com. My verdict on the new design ... terrible.
557-0,"passage: Spotted in my referrals today: ReadingEd.com. A promising new blog, well worth checking out for the innovative ""Outside Reading"" panel which uses the DOM and some very funky javascript to pull in the RSS feed (via a PHP proxy) of the selected blog and load it in to a panel which appears on the left hand side. Browsers lacking in DOM support are served up standard links to the blog in question. The feature is explained in a bit more depth here."
558-0,"passage: I've been helping my girlfriend recreate her site using CSS and structural markup. She's new to web design and has been taking to CSS like a duck to water - as a veteran of Microsoft Word globally defined styles come to her naturally and she took very little time to cotton on to the importance of seperating presentation from content. I've shown her tables as well but she isn't really interested as she sees CSS as a much better solution for general presentation. I'm hoping to help run an HTML/XHTML/CSS training course at the University early next year with a heavy emphasis on structural markup, standards compliance and accessibility so it's great to have a guinea pig to play with :)"
558-1,"passage: I also got her started with PHP, which she is relishing as a far more pleasant alternative to coding things in Java (the language used on our course at Uni). Her site already features a simple shoutbox system and random quotes engine (both written by her) and she has plans for a whole load of other features. Pretty good going for someone with less than 5 hours of overall PHP experience."
559-0,"passage: The Asilomar Institute for Information Architecture - very promising organisation, great site but I have to admit I'm not too keen on the name (though I'm sure it will grow on me). The highlight of the site for me has to be the 25 Theses, which provide an excellent condensed description of what IA is and why it is necessary. The site lead me to make my first impulse buy in quite a while, so with a bit of luck from Amazon Christina Wodtke's Information Architecture: Blueprints for the Web should be with me in the morning."
560-0,"passage: Jeffrey Zeldman points to the newly redesigned v-2 Organisation site, which features a clever technique whereby a large background image is displayed ""widescreen"" style with different amounts of the photo visible depending on the resolution / width of your browser. Try doing that with standard tables ;) The (unaltered) colours in the photograph cleverly match the colours of the site itself."
561-0,passage: Michel: How to hide Flash banner ads in Mozilla using a few lines of CSS added to the userContent.css file. A great example of CSS2 selectors at work.
562-0,"passage: It seems CMS news is like buses - nothing for weeks, then three items come along at once. Jeremy Zawodny has been very impressed by Bricolage, an Open Source CMS built on mod_perl, the HTML::Mason template system and PostgreSQL. Meanwhile, Scott Andrew has been praising liveSTORYBOARD on the WaSP site. liveSTORYBOARD is a hosted solution which promises ease of use through a web based interface and fully standards compliant output (hence the plug on WaSP). Finally, Think Secret have broken the news that Macromedia are soon to announce Contribute, a new CMS built on top of their popular Dreamweaver WYSIWYG editor (via webgraphics)."
563-0,"passage: What's led me to the conclusion IA has arrived? Articles on IA are seen in every
publication that addresses the web, from engineering to design. A recent search
turned up 188,000 results on ""Information Architecture"". Information
Architecture for the World Wide Web has gone to second edition, Information
Architecture: Blueprints for the Web hit the best seller list on Amazon in its
second week on the stands, and three more books on IA are scheduled to come out
next year. Jobs for Information Architects are found on most job sites, but
more importantly, information architecture is listed as a skill for designers
and programmers alike. And finally, the Asilomar Institute for Information
Architecture launched Monday-the first organization dedicated to promoting and
advancing Information Architecture. These are heady times for information
professionals."
563-1,"passage: I'm nearly half way through ""Blueprints for the Web"" now - I'll post a review of it once I've had time to read and digest it all but impressions so far are very favourable."
563-2,passage: Christina Wodtke: Information Architecture has arrived:
564-0,"passage: Stuart has released aqTree3, an upgrade to previous aqTree versions which takes in to account some of the best ideas from both Eric Meyer's pure CSS menus and Dave Lindquist's recently released drop-down / expandable trees. aqTree's great strength is that it requires no additional markup at all on top of the nested lists, other than a class definition which the script will pick up via the DOM. All presentation and positioning is now controlled with CSS applied to the list structure (previous versions of aqTree used the DOM to transform the list in to DIVs) and Stuart has included an extra script, aqdd, to handle drop down menus as well. The article includes a mini-essay on how elegant DHTML should be implemented, which is well worth reading."
565-0,"passage: webgraphics have an interesting discussion running about the need for a weblog entry XHTML validator. Dave Lindquist suggests using his JavaScript XML Parser to perform validation on the client side, which seems like an excellent solution. I already use PHP's XML parsing functions on this blog to check my entries are valid XML when I post them (and extract links for use with my pingback client) but additional client side validation would save the round trip to the server. The discussion also covers the idea of using the W3C's validator to check entries - as soon as they finalise their XML interface (as used by my validator web service) I can see a lot of interest forming in this kind of automated validation."
566-0,"passage: I've added Dave Lindquist's Javascript XML parser to my blog entry form using the code he posted in the discussion on webgraphics. It works an absolute treat - it even pops up an alert message telling me what is wrong with the post (usually 'End tag does not match opening tag') and won't let me submit the form until I have fixed the error. The actual XML parsing library is a truly impressive piece of work, despite the lack of documentation. Dave suggests that it is pretty much obsolete now that most modern browsers have a built in XML parser accessible through scripting, but his parser is easily fast enough for my purposes."
567-0,"passage: All Consuming is another one of those information-about-weblogs sites, but with a heavy emphasis on books:"
567-1,"passage: The site is a great example of web services in action - it pulls what's related information from Google, book information from Amazon and even uses Alexa to snag a screenshot of the blog in question. Most impressive of all is the ""edit friends list"" feature (which you can only play with if you log in to the site - account creation is utterly painless though) which identifies possible friends of your blog based on blo.gs friends, Google related sites and blogs who have read the same books as you. Check the ones you want on your friends list and optionally used to send you book recommendations. Practically everything is syndicated (have a root around in the site's XML directory to see quite how much information is available) and the site even offers javascript based syndication for those without the ability to use XML feeds."
567-2,"passage:
This page is the result of several different processes. Inspired by Book Watch, I created a script that visits newly updated weblogs hourly via Weblogs.com [...] The script then looks for links to Amazon.com items and saves them. I then aggregate all that information together to find the most frequently mentioned books. My scoring mechanism is weighted to favor recently mentioned books, so that the list remains fresh, and offers new insight into what the weblog community is reading at the moment.
"
568-0,"passage: Jeremy Zawodny talks about URLs, and describes a recent internal Yahoo discussion over how the URLs for their stock tickers should work. His points in favour of short, simple URLs are particularly worth noting:"
568-1,"passage: With benefits like that, I just don't understand why so many sites (especially those running a CMS costing hundreds of thousands of pounds) continue to use hideously long and illogical URLs."
569-0,"passage: Adrian Holovaty has been investigating the content-to-code ratio of various news sites compared to various blogs. Unsurprisingly the blogs win hands down due to the tendancy to use CSS to separate structure from presentation. Adrian has put together a PHP script to calculate the ratio which can be accessed online or downloaded for personal use. Incidentally, from the comments in the code I learnt that PHP's strip_tags() function neglects to strip the --> at the end of an HTML comment."
570-0,"passage: Simon Brunning talks about persistence, and how much more complicated it is now that objects are involved. The best explanation I've seen of how objects and relational databases can be used together was in Martin Fowler's Patterns of Enterprise Application Architecture, but now that the book has been published he has removed the online version. IBM's DeveloperWorks has a new article up describing persistence management in Python, which talks in details about Python's native serialization method (pickling) but only mentions ZODB in passing. I agree with Simon - object databases just don't seem as elegant a solution as RDBMSs. Object databases may provide persistence but they don't seem nearly as powerful as relational databases when it comes to flexibility of accessing data."
571-0,"passage: Handy bookmark for bloggers who wish to validate: cleanURL. It gives you the URL of the current page with all &s replaced with &, ready to be posted in to a blog entry. Unescaped ampersands are one of the most common causes of invalidity on my blog so this is going to come in very handy."
572-0,"passage:
The next issue of A List Apart will publish a technique allowing designers to embed Flash movies while adhering to W3C specs and eliminating code bloat. No, really. Watch this space.
"
572-1,passage: Jeffrey Zeldman:
573-0,"passage: Dspace (via Swannie) is an open source platform that helps institutions archive, manage and distribute ""digital works"" over the long term. It appears to be a variant on the idea of a content management system, but with a heavy emphasis on academic works and multiple formats. The system is implemented in Java (with a JSP front end) and uses a PostgreSQL for the metadata (based on Dublin Core) and relataional information. The assets can be stored in a variety of ways (filesystems, WebDAV, database BLOBS are all mentioned) via an abstraction layer known as a ""bitstream"". The system was developed by MIT and HP and has gone live for use by MIT's academic departments. Interesting stuff."
574-0,passage: And here it is: Flash Satay - Embedding Flash while Supporting Standards. It involves jumping througg a few hoops but the end result is a nice chunk of standards compliant code that can be used to embed flash movies without invalidating the markup of a page. The article also includes a nice example of how to use the object tag to serve up alternative content - by nesting an image (or other HTML) inside the tag browsers that do not support content with a mime-type of application/x-shockwave-flash will have something to display in place of the Flash file.
575-0,passage: What's So Bad About Microsoft? - a nice reference point for all us dissidents :)
576-0,"passage: I'm now running PHP 4.3.0pre2 and Apache 2 on my Win98 machine, thanks mainly to this excellent tutorial on installing PHP and Apache 2 on Windows. The PHP manual's Servers-Apache page also has a bunch of useful installation advice for Apache 2 in the user comments."
577-0,"passage: Rasmus Lerdorf has published a PHP Tips and Tricks PDF based on a presentation given at the recent PHPCon2002. The file is a veritable goldmine of useful information, covering topics including optimisation, sessions, security, dynamic image/flash/PDF generation and using Squid and MySQL replication to increase the performance of a high traffic site. Spotted on PHPDeveloper.org."
578-0,"passage: A £5 Amazon gift voucher combined with Amazon.co.uk offering free shipping on orders over £39 has lead me to order 3 more books: Information Architecture for the World Wide Web, Don't Make Me Think! and The Elements of Style. They should arrive on Monday. I wonder if All Consuming can pick up on links to isbn.nu?"
579-0,"passage: Macromedia Contribute is a cut-down version of DreamWeaver designed for end content providers to add and edit content on a static website without fear of breaking the design. Coverage by Jeffrey Zeldman, Ordinary Life, web-graphics and Aaron Swartz, who asks if this is a return to Tim Berners-Lee's original vision of a web where contributing is as easy as browsing."
580-0,"passage: Code generation tools which pretend to abstract out something, like all abstractions, leak, and the only way to deal with the leaks competently is to learn about how the abstractions work and what they are abstracting. So the abstractions save us time working, but they don't save us time learning."
580-1,"passage: And all this means that paradoxically, even as we have higher and higher level programming tools with better and better abstractions, becoming a proficient programmer is getting harder and harder."
580-2,passage: Joel Spolsky: The Law of Leaky Abstractions
581-0,"passage: An Introduction to the DOM Inspector (via Scott Andrew). The DOM inspector is a powerful but little-known tool that comes packaged with Mozilla and can be used to interactively browse through the DOM of both Mozilla interface components and any web page. The article mainly discusses using the inspector to investigate Mozilla internals, but as a web developer I frequently use it to analyse pages and see how they work. It is also great for tweaking other people's sites in my browser (see my post covering Jeffrey Zeldman's redesign for an example of this)."
582-0,passage: Patterns for Personal Web Sites (via Peter) - a fun and (as far as I know) original concept.
583-0,"passage: Opera have released the first public beta of their new browser, Opera 7. The new version promises to be smaller, faster and have better DOM support than Opera 6. My observations so far:"
583-1,passage: Verdict: Needs work - but then it's a beta so that's pretty much to be expected.
584-0,passage: Some more Opera 7 links:
585-0,passage: Rick Klau: A K-Log Pilot Recap:
585-1,passage: Rick's conclusion is a cautious thumbs up. Thomas N. Burg has posted some thoughts on Rick's experiment.
585-2,"passage: Given the flexible nature of weblogs (unlike structured applications, weblogs really can be what you want them to be), it wasn't entirely surprising to see users shape their own expectations in testing out the software:"
586-0,passage: Phil Wolff: We need a census of blogspace.
587-0,"passage: Then it hit me. The open source community already has the beginnings of a desktop WYSIWYG content editing application in Mozilla's Composer. Composer is often overlooked, but the few times I have tried it it has proved to be a remarkably powerful piece of software. Imagine an open source project inspired by Contribute, based on Composer but with support for XML-RPC and SOAP in addition to FTP (the Mozilla code base has libraries for all 3). CMS vendors could use it to build powerful, cross-platform editing applications for their existing systems, bloggers could use it to update their blogs (through support for something like the MetaWeblog API, schools and colleges could use the FTP version to encourage non technical users to update sites simply (as Contribute does now)."
587-1,passage: Now if only I knew XUL...
587-2,"passage: Update: Whaddya know, there's even a document on embedding the editor right there on the Composer site."
587-3,passage: While reading the thread discussing Macromedia's Contribute over on 37signals I realised something: the web could really do with an open source Contribute style application. Editing full documents is best done in an application - there's only so much you can do with browser based editing tools (even if you take advantage of IE's contendEditable or use Flash to build an editor applet). When people are using Word they hit Ctrl+S to instantly save what they working on - show me a browser based editor with the same functionality.
588-0,"passage: Licenses Down, Services Up is a fascinating article discussing the commoditising effect of open source software which uses the high-end Content Management market (such as Interwoven, BroadVision and Vignette) to demonstrate how open source is causing real problems for companies that rely on ludicrously high license fees as their main revenue stream. The conclusion?"
588-1,passage: The article also looks at Oracle and the inroads being made by popular open source database packages such as PostgreSQL and mySQL.
588-2,"passage:
I like to speak in absolutes when I can, it's easier that way, so if you ask me, I'd say these companies are already dead."
589-0,"passage: It seems I was mistaken. Phil Ringnalda has explained the concept in more detail, and it's actually a very clever angle on the caching problem. Rather than building content in advanced (the ""baked"" method, used by Moveable Type) or generating the page dynamically each time (the ""fried"" method, used by my weblog) you set up a custom 404 script which decides whether or not the requested content should exist when it is called. If the content is meant to be there, it creates the content, serves it up and saves it to the file system (so future requests will get the file rather than a 404). To regenerate content you just delete the static file and wait for someone to request it, at which point it will be rebuilt by the 404 script. Clever stuff."
589-1,"passage: I didn't take much notice of ""funky caching"" while reading through Rasmus Lerdorf's PHP tips and tricks presentation - I saw that it was talking about using custom 404 pages to serve up dynamic content depending on the URL and wrote it off as a hack that, while useful, was fundamentally flawed in that it would add an error log entry whenever a page was served."
590-0,"passage: Usability Views (via Zeldman) lists articles from a number of Usability related sites in a variety of different ways, including order-by-most-popular. Popularity appears to be judged by the number of links to that article around the web - I doubt the site is indexing the whole web so could this be another (very clever) application of the Google Web API? Grabbing the number of results for a Google link: query should be easy enough, and would be a great way of judging the popularity of external content. Here's hoping Usability Views adds a ""how this works"" page in the near future to satisfy my inner geek."
591-0,"passage: Douglas Bowman has left Wired, and is striking out on his own with Stop Design, his one man consultancy business. With the Wired redesign Douglas gave a massive and long-awaited boost to the web standards movement by demonstrating once and for all that a large, high traffic site could make the transition to structural markup and standards compliant code. I wish him the best of luck in his new venture, and I look forward to keeping up with further developments via his excellent weblog."
592-0,"passage: Thanks to Morbus, I have finally found a time management system that looks like it could work for me: Structured Procrastination."
592-1,"passage:
[...] the procrastinator can be motivated to do difficult, timely and important tasks, as long as these tasks are a way of not doing something more important. Structured procrastination means shaping the structure of the tasks one has to do in a way that exploits this fact. The list of tasks one has in mind will be ordered by importance. Tasks that seem most urgent and important are on top. But there are also worthwhile tasks to perform lower down on the list. Doing these tasks becomes a way of not doing the things higher up on the list. With this sort of appropriate task structure, the procrastinator becomes a useful citizen. Indeed, the procrastinator can even acquire, as I have, a reputation for getting a lot done. "
593-0,passage: This story on the BBC describing how Microsoft lost £112 million on the Xbox has been getting a lot of attention later. Here's a depressing thought: With 40 billion dollars in the bank they could sustain that rate of loss for 85 years without running out of cash. Scary.
594-0,passage: Stuart points out that the W3C are seeking public approval for their recently published last-call draft of their patent policy. The email address is www-patentpolicy-comment@w3.org. Show them your support for a royalty-free web.
595-0,passage: The hack we've all been waiting for: How to hide CSS from OmniWeb. OmniWeb is a Mac browser which understands the @import rule but horribly mangles CSS layouts beyond all repair. Thanks to this hack CSS sites with a noticeable percentage of OmniWeb users (and anyone else who cares) can give OmniWeb the same treatment normally reserved for Netscape 4.
596-0,"passage: Thanks to CafeShops, pretty much anyone can set up a store to flog their own branded merchandise. Long time a favourite obscure site of mine, the Condiment Packet Museum now has their own line of goods. Dig those boxer shorts :)"
597-0,"passage: Peter Van Dijck: We need some sense in the naming of XML feed buttons.. I couldn't agree more - in this day of syndication formats left, right and center the orange XML button could mean just about anything. Speaking of which, I've finally got around to adding a pretty blue RSS button to this site."
598-0,"passage: Peter has been blogging the progress of a 3828 page content inventory he is working on. Day Two describes his method of working with Excel, Day Three provides three useful inventory tips. Christina Wodtke's Information Architecture: Blueprints for the Web has a nice overview of the content inventory process which recommends a dual monitor setup and links (well, footnotes) to these tips by Noel Franus. Peter has also commented on my decision to go with the blue RSS button in favour of the standard orange XML button - I've posted my reasons in a comment attached to his post."
599-0,"passage: I frequently find myself reading something on someone elses blog and thinking ""that's interesting, and it fits in well with XXX that I read the other day"". I often end up blogging a link to both just to satisfy my need for completeness. Wouldn't it be interesting if there was some standard for formalising this kind of further reading recommendation? I'm not sure exactly how it would work (it would almost certainly be XML based but I don't know if it would require a new format or integrate with an existing one) but it could be an interesting avenue to explore. I think it's a significantly different problem to the ones solved by XFML (external shared metadata) and Pingback for it to be worth committing some thought cycles to. Any ideas?"
600-0,"passage: Hixie has put together a fascinating article describing how the Mozilla, Opera 7 beta and IE6 DOMs deal with incorrectly nested HTML tags. Internet Explorer goes as far as creating a malformed tree just to represent badly formed HTML!"
601-0,"passage: I've suspected this for ages, but finally it can be categorically announced that search engines just don't care about the meta keywords attribute. The only major engine that still notices it is Inktomi, and even they treat it as a very low priority. Finally something concrete to refer people who still demand meta tags to. The description tag is still occasionally worth adding though."
602-0,"passage: Via Adrian Holovaty, Matt Jones points out an innovative new feature of the BBC's new home page - background colours that adapt to your browsing preferences. Interesting stuff."
603-0,"passage: Mark's back, and he's been tinkering. In addition to a whole bunch of changes made yesterday in response to Hixie's markup critique, Mark now boasts php.net style shortcut URLs, an RDF powered about page and an automatically generated list of acronyms (in a semantically correct definition list). I use a similar technique (extracting structural markup tags using regular expressions) in my personal course notes - there's something very rewarding about being able to extract information from a properly marked up document."
604-0,"passage: Via Stuart, Tantek has an intriguing new (valid) hack for adding HTML documentation to an external javascript file. The hack uses some clever multi-language comments to hide the HTML in the file from the script interpreter, while ensuring that the documentation remains readable when the file is interpreted as HTML. Unfortunately the trick does not work in Mozilla, as that browser respects the Content-Type served with the document (whereas IE ""guesses"" the content is HTML from clues in the document)."
605-0,"passage: Aquarionics is Gone (well, not entirely - the old site can still be found here). Aquarion has committed to building his new blogging system, Epistula 2, and vowed not to add any more entries until the new system is capable of taking them. Development of the new system will continue in the open at playground.aquarionics.com, which is currently throwing an HTTP 500 error but is likely to be an interesting place to watch in the next few days."
606-0,"passage: Joe Gregorio's RESTLog is a fascinating piece of technology and a great example of the RESTian model of web service in action. Everything is built on XML and HTTP - new blog entries are POSTed to the index page as RSS 2.0 item elements, edits are done with the little-used HTTP PUT method and the DELETE method can be used to delete items. Content negotiation is in effect, so browsers recieve HTML while aggregators theoretically get RSS (though in practise existing aggregators fail to send a content negotiation header so an alternative URL scheme must be used). It's very clever stuff. Further techie details are being posted on a regular basis, but a good overview can be had by reading RESTLog Overview and RESTLog Interface. The system was inspired by the RESTWiki's RestidyingBlogger."
607-0,"passage:
The concept is simple enough. You download and install some software that registers a new printer driver on your system. Whenever you print a document using that driver, your document is rendered - securely I might add - to Mimeo's server. Once it's uploaded, your browser takes you to Mimeo's site. There you are presented with the most intuitive web application I have ever seen which walks you through the process of creating a professional document, including paper choices, binding styles, covers, tab dividers, etc. You are even shown a rendered proof of your document online so you can make sure it's exactly what you want. When you are satisfied, you enter your payment and delivery information and the document is sent to you via FedEx. It is so easy.
"
607-1,"passage: Brian Graf has some very positive things to say about Mimeo, an innovative new web services based company in the States:"
608-0,"passage:
The reasons for all this, of course, are that - for good or ill - at the moment copyrighted material and intellectual property are endangered and cornered beasts anyway. As yet no-one really knows the effects of this development, but I think it is clear to all concerned that (whether or not it is really happening at the moment) the gradual increase in technology, bandwidth and storage capacity provides an enormous potential for simply routing around traditional media-distribution outlets.
"
608-1,"passage: In Apple and the Pirate Everyman, Tom Coates discusses Apple's attitude to copy protection and open standards. Choice quote:"
609-0,passage: Adam Polselli is a talented young designer who posts regularly on the SitePoint Forums. Get The Look is his new site (based on an article he wrote for SitePoint) which provides five excellent site templates and explains the design principles that were used to create them. I'm personally not interested in free site templates (though with my terrible design skills I probably should be) but the site is well worth visiting for the excellent advice provided with each design.
610-0,"passage: Hixie and Aaron Swartz are debating Hixie's infamous Sending XHTML as text/html Considered Harmful on a W3C mailing list. While I am just as guilty of sending XHTML as text/html as anyone else (I've been meaning to fix this for a while but just haven't found time yet) I'll stick in an argument that Hixie hasn't used yet. Sending XHTML as text/html basically amounts to pollution of the web. As far as the XML user agents of the future are concerned (which are supposedly one of the main reasons we use XHTML) an invalid XHTML document is unparseable and thus unreadable. Anyone who has tried to keep an XHTML blog valid will know how difficult it is to keep it that way, and without a browser refusing to display the document (as happened with Mozilla and diveintomark the other day thanks to an XML content type and a missing end tag) it can be all to easy to contribute to the pollution. As it stands, a massive proportion of the supposedly XHTML web may as well be just so many random floating bytes."
611-0,"passage: phpPatterns is a brand new site which advocates and documents the use of object oriented design patterns with PHP. It's a great concept and the site already has some impressive content (although it could really do with a PHP references tutorial). The site is a project of Harry Fuecks, a regular contributor to SitePoint's PHP forums."
612-0,"passage: The Open Web Application Security Project (OWASP) have a free guide to building secure web applications, which covers a large range of common problems such as cross site scripting and SQL injection vulnerabilities. The report is a 60 page PDF and although I haven't had time to go through it yet it looks like an excellent read."
613-0,"passage: XFMLManager, Peter Van Dijck's XFML construction and navigation tool to which I have contributed various chunks of XML related code, has been renamed Taxomita and given a brand new site. Peter hopes to have a public beta out within the next few weeks. It also has a mailing list. Meanwhile, XFML has been cropping up all over the place even despite the current lack of software, with the most recent sighting occurring over at Bill Kearney's Syndication News."
614-0,passage: Anil Dash suggests using structured XHTML as a blog syndication format. Scott Andrew points out that this has semantic problems in that it would mean using the class attribute to add additional meaning to a document. I was going to say that this would be an ideal opportunity to mix different namespaces in one XML document (as described by Lachlan Cannon) but techno-weenie beat me to it.
615-0,"passage: Spotted on the Web Manager's Weblog, centricle : css filters is a list of all of the current CSS browser hiding techniques (all 17 of them!) along with a table showing which hack will hide things from which browser. Best of all, the name of each workaround is a link which will pop open a new window testing the hack in your browser."
616-0,"passage: It seems the W3C have made some changes to their beta validator's XML output option. The bad news is that this has (temporarily) broken my web service interface, but the good news is that the feature is now documented on the W3C's site. Hopefully I'll get a chance to fix the web service interface in the near future, but it will remain a toy rather than a tool for as long as the validator's interface has not been frozen."
617-0,"passage: No time to update tonight. I'm frantically putting together a 2 hour training course on HTML, PHP and mySQL which I shall be presenting tomorrow as my first ever experience of teaching a large(ish) group. Should be interesting."
617-1,"passage: In the meantime though, a bellated happy birthday to Mark Pilgrim. If you haven't read his tragi-comical account of the big day yet you're missing out on a blogging treat."
618-0,"passage: No, I'm not dead - I'm just weighed under with coursework. Two large group projects and a whole bunch of personal pieces are conspiring to make me feel gulity whenever I load up a browser window. It'll all be over by December the 17th thank Goodness. For the moment though I'm taking a well earned break to catch up on the goings on in the blogosphere over the past few days."
619-0,"passage: The aforementioned PHP training system was a mixed success. On the one hand, I discovered that trying to teach a room full of people is a lot tougher than I had expected (to cut a long story short, I stumbled through about five minutes of reiterating the same few points before all present agreed that the session would be best run using the ask-questions-when-you-get-stuck format). Luckily I had prepared some pretty comprehensive support material the night before. I'm chalking that one down to experience."
620-0,"passage: OpenEnterpriseTrends.com: Python Power: Growing Respect for an Open Source Integration Tool. Another excellent piece of Python advocacy, this time highlighting Python's power and flexibility as a middleware tool to glue together varous large enterprise systems."
621-0,passage: Mark Pilgrim pretty much single handedly killed the discussion thread on syndicating weblog content with XHTML started a few days ago by Anil Dash. Stuart's reply to Mark's post is definitely worth a read though.
622-0,passage: Spotted on Guide to ease: Bill Kearney has written an XFML tool for Radio Userland. This sounds great - I'd love to see an example of a Radio blog that is using this.
623-0,"passage: If you weren't already exited about the OSAF, maybe it's time you were. I just spotted on Mitch Kapor's blog that they've hired Robin Dunn (of wxPython fame, and winner of the ActiveState 2002 Python award) on a 6 month contract to work on improvements to wxWindows and wxPython. They've also hired Mitchell Baker, Mozilla.org's ""Chief Lizard Wrangler"" on a part time contract that helps fund her work on Mozilla while letting OSAF take advantage of her extensive experience of co-ordinating community open source efforts. Hiring Robin Dunn makes very good sense, seeing as the bulk of Chandler's code will be written in Python with wxPython used for the front end. Any worries that Chandler might turn out to be vapourware have vanished from my mind - I can't wait to see what they come up with."
624-0,"passage: A conversation with Martin Fowler, parts I, II, III and IV."
625-0,"passage: Mental note: add the rel=""bookmark"" attribute to my permalinks, as recommended by Tantek. I'd never realised the rel attribute could be applied to normal hyperlinks."
626-0,"passage: Uh oh, looks like Blogdex has been spammed. At the time of writing a whole bunch of the links positioned at ""12"" were ""PremiumDomains - www.somedomainhere.com - DOMAINS FOR SALE"". This is a worrying precedent - many of the services we bloggers thrive upon such as weblogs.com, blogdex and others are easy targets for spammers thanks to the open nature of the service they provide."
627-0,passage: PostgreSQL Global Development Group Announces Version 7.3. I still haven't had a play with PostgreSQL yet but everything I've heard has been positive. I'm sure PostgreSQL's popularity would skyrocket if they made a Windows binary available - the ability to test scripts written in PHP and MySQL on a Windows desktop PC is the main reason I have stuck with MySQL rather than exploring PostgreSQL.
628-0,"passage:
Finally, the Zend Engine 2 also adds exception handling to PHP. To date, the sad reality is that most developers write code that does not handle error situations gracefully. It's not uncommon to see sites that spit out cryptic database errors to your browser, rather than displaying a more user-friendly ""An error has occurred"" message. A key reason for this is that handling error situations with the versions of PHP was a daunting task - you actually had to check the return value of each and every function. Adding a set_error_handler() function made managing errors slightly easier, - but still left a lot to be desired. Adding exception handling to PHP lets developers achieve fine-grained error recovery, but more importantly, it facilitates graceful application-wide error recovery.
"
628-1,"passage: Via ReadingEd, an interesting article on the Object Oriented Evolution of PHP by Zeev Suraski (the Ze in Zend). As well as a history of PHP's OO support, the article provides some tasty snippets of information as to improvement to look forward to in PHP 5. Personally I can't wait for the objects to default to passing by reference, but the exception handling is going to be very nice as well:"
629-0,"passage: Why Computer Books Suck. The principle argument seems to be that most authors get burned by their first experience and avoid writing further books, leading to the bulk of computer books being written by newbies. One of my long term ambitions is to write a book on a geeky topic - I haven't been put off yet, but the prospect does seem slightly less appealing."
630-0,passage: Getting Started with XML Security is a SitePoint article of epic proportions. I had never really looked at any of the XML security applications but this article appears to cover the lot.
631-0,passage: This year's collection of Demotivators are out (via Doc Searls). I think my favourite is Motivation.
632-0,passage: The 2002 Perl Advent Calendar. Cute.
633-0,"passage: It's coursework crunch time. Deadline is Thursday, we have an application that works but doesn't work (if you get what I mean) and it looks like I will be spending the next few days immersed in Java. Fun fun fun."
634-0,"passage: Coursework continues, but I'm taking a quick break to blog the fact that Tony Bowden has changed the CSS style for blockquotes on Understanding Nothing. This may not be earth shattering news, but considering Tony's blogging technique (entries frequently consist of large blockquotes) and previous blockquote style (grey italic text) the new format makes an excellent blog a great deal more readable."
635-0,"passage: Coursework finished. It still has some niggling bugs but, as a group, we have agreed to stick them in a ""known issues"" list and forget about them."
636-0,"passage: Mark Pilgrim has discovered XFML. He provides an excellent description of the standard, but fails to mention XFML's most powerful ability; sharing metadata. Here's how it works:"
636-1,"passage: This is just the tip of the iceburg - apply the creative global mindset that is the blogging community and who knows what will happen :) In the meantime, marvel at Dive Into Accessibility as rendered by FacetMap, working from the XFML document provided here. Dive Into Accessibility is a great example of faceted navigation and a perfect example of XFML in action."
637-0,"passage: Via Scott, an article with some great tips on remembering your passwords. It includes the following vitally important tip:"
637-1,"passage: Ever since then, I have maintained a minimum of 3 passwords. I have a low security username/password for unimportant accounts, a medium level one for sites that I trust to a greater extent than the low security ones and a number of high security passwords used for e-commerce sites and important admin level accounts. I should probably start spreading myself even thinner."
637-2,"passage: A few years back I nearly learnt this one the hard way. An online gaming forum I had signed up for was cracked, and the password file started making its way around the less scrupulous members of the UK gaming community. The first I heard of this was when someone used my username and password form that forum to log in to my account on a different forum and post some messages. The bad news was that I had administrator access on the different forum, which at that time had over 20,000 active members and nearly 2 million posts."
637-3,"passage: Luckily the prankster in question didn't cause any damage and contacted me to warn me to change my password, but it gave me (and the other administrators of the forum) a pretty big scare."
637-4,"passage:
You may trust the provider you're signing up with, but are you confident no-one will hack into their database? If in doubt, err on the side of caution - be safe, not sorry.
"
638-0,"passage: YAML has a number of obvious influences, including Python and MIME. Implementations already exist for Perl, Python and Java. XML-RPC aptly demonstrates how powerful the combination of lists, dictionaries and arrays can be for exchanging data between different systems and YAML looks like it offers a very nice alternative to XML based data structure syntax. I have to admit to being slightly concerned by the length of the specification - while YAML is definitely human readable it looks like it could take a while for a human to learn to write it. Then again, the actual generation of the format is meant to be handled by computers (I imagine that humans will make simple edits to YAML files more often than they create them from scratch) so the complexity of the more advanced parts of the specification is probably not too much of a problem."
638-1,"passage: I forget quite how I got there, but the other day I found myself reading about YAML - YAML Ain't Markup Language. It looks really interesting. YAML aims to be an easily human readable format for storing and trasferring structurered data - so far, so XML. Where it differs from the IT world's favourite buzzword is that YAML is specifically designed to handle the three most common data structures - scalars (single values), lists and dictionaries. Here's a sample (taken from the official specification):"
639-0,"passage:
One thing they do quite well is hide the implementation from the calling classes. Why is that good? Well, when you want to change the implementation you don't have to change the calling classes.. Saves time, saves work, saves QA resources, code is more readable, more versatile and easier to maintain.
"
639-1,"passage: I'd seen this explained before but the example Kasia provides finally made it click for me. Kasia also provides a link to Design Techniques, a collection of articles on good Java design. I just wish I'd found these before I started on our (now handed in) Java coursework."
639-2,passage: While browsing through Kasia's Java Archives I came across this gem explaining why interfaces are such a useful feature of Java:
640-0,"passage: Via Stuart's latest catchup, a scientific explanation of the Vampire Population Ecology of Sunnydale."
641-0,"passage: For my future reference, here are some useful Prolog sites I found over the past few days while working on my (now complete) Prolog coursework:"
642-0,passage: The best 404 page I have ever seen. Text reproduced here in case they ever change it:
643-0,"passage: lloydi on the SitePoint forums made the excellent suggestion that the content of the notes should appear at the bottom of the page as footnotes, with the links that activate the popup notes doubling up as links to the footnote anchors. That way the content will stay accessible to user agents which do not support javascript."
643-1,"passage: Create Pop-Up Notes with DHTML is a disappointing new article on SitePoint which describes a technique for having a yellow Post-It style note appear when a link is clicked. The example given is for a link that shows the un-abbreviated form of NASA - a task better accomplished using the acronym tag. In addition, I spotted the following problems with the article:"
644-0,"passage: The W3C have redesigned to use CSS instead of tables (new layout explained here). About time too! It's a shame the site still looks so, well, ugly. I know it's a technical site and it doesn't have to look pretty but it would be a lot easier to convince designers to try out CSS and web standards if they didn't get instantly put off the W3C by the ugliness of the front page."
645-0,passage: PHP5: Ready For The Enterprise? (via Scott) discusses forthcoming improvements in PHP5 and asks if they will lead to acceptance of PHP as a suitable language for enterprise applications. It looks like a killer factor could well be PHP's improved Java and .NET integration abilities. Write the back-end in Java/.NET and use PHP for the front end - that way you get a powerful web-specific scripting language for the front end of your site. Then if you ever need to change technologies on the back end your front end code can be reused.
646-0,"passage: Phoenix 0.5 has been released, and so far it's an absolute dream. The Windows installer is a paltry 6.1 MB and it is noticable faster than Phoenix 0.4 - the initial speed boost was so impressive I spent several minutes loading up large, bloated sites just to admire the speed with which they appeared. The Phoenix team are aiming for a 5 MB Windows installer for the final release - here's hoping they manage it."
646-1,passage: Unfortunately there is still no menu option for the Mouse Gestures package to change the mouse button needed to trigger a gesture (it defaults to left but I much prefer right). If you want gestures to be linked to the right mouse button you'll need to do the following:
647-0,passage: Phil Ringnalda: The perils of good semantic markup. A throwaway comment by a blogger about some trashy manufactured band results in his (properly marked up) site ending ranked higher by Google than the official band's site for searches on their name. This results in a barrage of moronic fan comments and apparently an even bigger barrage of moronic fan email.
648-0,passage: Generating One-Time URLs with PHP has some simple example code which demonstrates PHP's file locking functions in action.
649-0,passage: Lawrence Lessig:
649-1,"passage:
Jason Schultz has done more amazing work calculating any ""chaos"" that would come from striking the 1976 Act. Using the Internet Movie Database, he confirmed the Copyright Office's numbers that about 37,000 movies were released in the period 1927-46. (IMDb reports 36,386). Of those, only 2,480 are currently available in any format, or 6.8%. 93.2% of the films during that period are are commercially dormant.
"
650-0,passage: It looks like Java is set to get a new feature - Generics - in version 1.5. Generics are the Java equivalent of C++ templates; they severely help clear up confusions over types used with abstract data types such as lists and sets. Preparing for Generics explains this new feature and the kind of problems it solves.
651-0,"passage: Les Orchard is considering building his own web proxy. I had never thought about the possibilities of these technologies beyond caching before, but Les's post has really got me thinking. I often find myself searching around for a web page I visited a few months ago and can only vaguely remember - a proxy generated searchable history (I never got the hang of using my browser's) would be a very useful tool. In addition, the ability to cache local copies of useful documents to preserve them should the original ever go offline would be very handy. How about a proxy with an accompanying small GUI desktop application which shows your recent browsing history (the last 15 pages or so) and allows you to mark documents for bookmarking / preserving? The application and proxy server could communicate via XML-RPC."
652-0,"passage: Acts of Volition: What's wrong with MSN Messenger 5.0. I rarely load up MSN (I like to browse in peace) but I'd like to add a few points, aimed at Messenger in general rather than any particular version of the software:"
652-1,"passage: Steve observes that Microsoft's UI design teams seem to need to implement an entirely different interface scheme for every product line. I concurr - but I have trouble understanding the motivation behind this. From my (admitedly limited) knowledge of user interface design, two of the most important considerations are to keep things consistent and to observe the principle of least surprise (don't so anything unexpected). How the biggest sofware company in the world gets away with fragrantly ignoring these principles at every turn is beyond me."
653-0,passage: Matthew Thomas lists 21 usability problems with the Opera 7 beta.
654-0,"passage: Coursework frenzy is kicking in again. This time I have a large group project and two personal projects (one small, one large) due for Tuesday of next week. I'm clearing out my things-to-blog list and then I intend to knuckle down to some work."
655-0,passage: An Introduction to Lambda Calculus and Scheme and Wikipedia's Lambda Calculus page have both proved useful recently.
656-0,passage: Soup is Good is a new blog by a friend of Jeremy Zawodny. It looks like one to watch - two quality rants and counting.
657-0,"passage: I've missed out on a whole bunch of Google news lately (all of which has come via the Google Weblog). Google labs have a couple of interesting new demos; Google Viewer, a weird slideshow thing that cycles through search results for you using bizzare DHTML and Google Webquotes, which annotates the results of your Google search with comments from other websites. Google have also published their End-of-Year Zeitgeist which offers a unique overview of the year's events based on Google search statistics."
658-0,"passage: Adrian Holovaty has revealed his previously hinted at secret project. Trodo.com is kind of an online bartering site. You give away stuff you no longer have a use for to earn credits, which you can then spend on requesting free items from other people. It's a very interesting idea, and the trading model is explained in depth in Adrian's comments section."
659-0,passage: There's a heck of a lot to learn.
660-0,passage: OSDir: Interview with Tim Perdue. GForge and behind the scenes at SourceForge.
661-0,"passage: On Monday, Slashdot posted an excellent in depth interview with Joe Clark, author of Building Accessible Websites. In a fantastic display of cluelessness they pasted the XHTML document which Joe sent them straight in to the Slashdot template, <html> tags and all. The good news is that there's more Joe Clark related goodness to come, courtesy of Jonathan Delacour:"
661-1,"passage:
... since next week all my posts will be devoted to Joe Clark's Building Accessible Websites: first a book review, then an extended conversation with Joe about accessibility matters.
"
662-0,"passage: For some reason, this was only removing approximately half of the items in the list. I checked it in both IE and Phoenix and the same bug was evident, demonstrating that it was almost certainly a flaw in my code rather than a strange browser bug. After much tweaking and adding of alert() debugging statements I realised my folly: Every time the loop went round I was removing an item from the list of items in the select box, but my code was not taking this in to account (a classic example of changing a data stucture while processing it). Once this had dawned on me the replacement code took a matter of moments:"
662-1,"passage: Deep in to coursework now, but I just spent more time than I care to mention struggling with what should have been a very simple task; removing all of the items from an HTML select box using Javascript. Here's the code that was causing me problems:"
662-2,passage: Hopefully this will soon be Googled and will eventually save someone else from making the same stupid mistake.
663-0,"passage:
The contents of this weblog is licensed under a
Creative Commons License."
664-0,passage: Coursework is done and dusted; normal service can now resume :)
665-0,"passage: Stuart has some interesting thoughts regarding Mark Pilgrim's latest entry: an excerpt from The Real Thing, a play by Tom Stoppard."
666-0,"passage: If I'm going to criticise the embedded RDF approach I should probably suggest an alternative. The HTML 4 specification describes a ""Copyright"" link type which is defined as follows:"
666-1,"passage: It's great to see the Creative Commons getting an overwhelmingly positive reception - as Lessig says on his blog, 'Tis the season to be giving, and this will be a great gift to the Commons. If you haven't seen their explanatory flash animation, Get Creative, you should really check it out."
666-2,"passage: That said, I have to admit I have a few reservations about the machine readable form of the CC licenses. The recommended way of including them in a page is RDF embedded in a comment, similar to Moveable Type's Trackback system. This is fine for HTML documents (although it feels like a bit of a cludge) but is problematic when used with XHTML. Why? Because XHTML documents are XML documents, and the XML specification states that an XML processor may, but need not, make it possible for an application to retrieve the text of comments. The logical way of extracting Creative Commons information from an XHTML document would be to parse it with an XML processor, but it is likely that many processors will be unable to extract the comments (and even those with the ability to extract them will not treat them as XML, requiring a second run of the XML parser to extract information from the RDF). In practical terms this is unlikely to be a problem as regular expressions can be used instead, but from an idealogical point of view it leaves something of a bad taste in the mouth."
666-3,passage: I suggest using a link element in the <head> section of a document which points to the Creative Commons license governing the page in question (or to an RDF document similar to that currently used by the embedded comments method). If you view source on your page you will see that I have done exactly that.
667-0,"passage: Secondly, Tantek frequently uses a combination of a pre and a code tag to mark up sections of example code. This works fine, but could potentially be improved by adding a class element hinting at the type of code being displayed, for example:"
667-1,"passage: Finally, Tantek's use of <a class=""local""> to differentiate local and external links introduces (technically) redundant data - the fact that the link is to a local resource is implicit in its URL. This information can even be extracted using CSS3 selectors, as is demonstrated by Stuart's ingenous article External link icons the CSS way."
667-2,"passage: In A Touch of Class, Tantek continues his series of tips on writing better semantic markup and then issues a challenge: find related improvements that can be made to his blog. I couldn't find anything in the overall structure, but I have a few (admittedly nit-picky) suggestions for his current entries. Firstly, the following line would, in my opinion, be better served with a titled <dfn> element:"
668-0,"passage: Douglas Bowman provides some background to the new HotBot redesign, which uses CSS for layout and almost but doesn't quite validate. It was all looking great until the HotBot Skins page told me I should upgrade to a browser that supports web standards (I was using Phoenix)."
669-0,"passage:
The larger CMSs are a kind of protection racket: You buy our system for six figures, and then you keep paying us every year to maintain your license, and also you'll have to hire a person trained in our ways to keep your system up and running. Fail to do any of that and your entire site crashes. It's extortion, really, and high-end CMSs are dogs in so many ways - they can't produce valid code, their URLs are appalling, and they are difficult to use. In essence, big CMSs are mainframe systems, with the same need for constant nursing and non-stop tending by codependent system administrators as those old mainframes.
"
669-1,"passage: Finally, yet another reason not to spend hundreds of thousands of pounds on an ""enterprise"" CMS:"
669-2,"passage:
People use tables for forms so that online forms look like printed forms - that is, they use as much of the ""paper"" as possible, because ""paper"" is expensive. But online we have unlimited screen real estate, at least in the vertical dimension. HTML forms, at root, yearn to be vertical, not horizontal. Do not flout their natural desires. Do not attempt to overlay the design of printed forms onto online forms.
"
669-3,passage: This note about accessible forms also caught my eye:
669-4,"passage: To avoid the risk of misrepresenting Joe's responses by quoting the above, I should mention that the rest of the series is far less inflammatory."
669-5,"passage: If we could rid the Web-development ecosystem of life-sapping parasites like these - essentially, everyone who is immature and/or has *bad taste* - then we stand a good chance of making valid, standards-compliant Web development the norm rather than the exception"
669-6,"passage: And of course we'll also have to fire the boy racers' clueless Dockers-wearing manager dweebs, who consider themselves old-timers because they got online in 1998 (!) and whose entire experience of the Internet is the commercial Web as rendered through Internet Explorer for Windows. These people cannot even *spell* ""W3C"" and still think banner ads have not been given a fair shake."
669-7,"passage: In the meantime, firing all the boy-racer HTML programmers who think they're tough shit would be a good place to start. They're jumped-up script kiddies; it was quite telling that my submission of well-written, copy-edited text in a valid HTML document was an absolute first for Slashdot. This is a clientele that does not know what the Shift key does or how to debug two nested ordered lists. (The latter is an actual example from a site I worked on. The concept of closing a paired tag had never occurred to them, so they could not find the error in the sequence <ol><li><ol><li></ol>.)"
669-8,"passage: Jonathan Delacour is three days in to his Conversation with Joe Clark series (see also parts one and two and the introductory book review). I thoroughly recommend reading the whole series, but here are a few points that stood out for me:"
669-9,passage: The comments attached to the various stories are also well worth reading. I particularly liked Mark Pilgrim's argument as to why Joe's controversial views on fixed font sizes should be taken with a healthy pinch of salt:
669-10,"passage:
Simply put, I believe that there is a large class of people who would not in any way refer to themselves as ""visually impaired"" or ""disabled"" in any way, who nonetheless can not read 9px type on their computer monitor. Reading on-screen is hard enough as it is, and tiny type in stupid fonts only makes a bad situation worse. These affected people are not running screen magnification software as Joe suggests; they are not running any accessibility-related software at all, because they do not view themselves as disabled. At most, they may be running in a display theme with slightly larger fonts, which means that everything on their computer that they read on a regular basis (menus, buttons, toolbars) is readable -- everything except web pages that use absolute font sizes.
"
669-11,"passage: My Father certainly falls in to this category of users, and was very impressed when I showed him Mozilla's text resizing ability (he had not realised text resizing was possible in IE either). I find it extremely annoying that modern browsers consistently hide their basic text resizing options - IE 3 got it right by including an increase/decrease text size button in the main toolbar by default but browsers since then have all conspired to hide the option in a menu where it is far less likely to be found by casual browser users."
670-0,"passage: StopDesign is a superb example of a site that degrades gracefully for Netscape 4, thanks to a carefully crafted basic stylesheet. Doug discusses the necessity of including a browser upgrade message and some of the different approaches used around the 'net."
671-0,"passage: It's not all bad - once you get over the utterly bizzare decision to use Flash for the primary navigation it is relatively easy to navigate the site, understand what it has to offer and find the information you are looking for. The site claims to have been designed with accessibility in mind so it is likely that they have implemented Flash MX's accessibility features (I have no way of testing this) but Flash is still inherently less accessible than plain HTML thanks to its graphical nature and reliance on a plugin. The thing that baffles me most is that the Flash used on the site is completely reproducable in standard HTML."
671-1,"passage: Someone, please, tell me UsabilityNet is a joke. Spotted via an article on hebig.org, UsabilityNet (apparently recently redesigned) claims to be ""a project funded by the European Union to provide resources and networking for usability practitioners, managers and EU projects"". Again, IANAUE but here are some things wrong with it just off the top of my head:"
672-0,"passage: Inspired by Adrian Holovaty, I spent an hour this morning getting dirty with the DOM in an effort to replicate his funky CSS blockquote citations effect but with links that you can actually click on. The resulting code is now active on this weblog - check the javascript out here."
672-1,passage: It turns out Paul Hammond had exactly the same idea - his implementation can be found here.
673-0,passage: A couple of good web development security resources:
673-1,"passage: I also found myself reading the Linux Kernel Coding Style document for some reason, and learnt some useful lessons about writing effective C (should I ever need to delve in to that language)."
674-0,"passage: Tantek has released two new favelets for revealing HTTP information, using Mozilla's ever useful Web Sniffer and Delorie's HTTP Header Viewer. I spotted a similar tool on a recent trip to MozDev: LiveHTTPHeaders adds a ""Headers"" tab to the page information box in Mozilla 1.2, showing the full request and response headers used for the current page. It's a very nice tool, but unfortunately does not yet work with Phoenix (the headers tab is added to the info box but the header information does not appear)."
675-0,passage: Useful Java article: Make Exceptions Smarter (via Keith).
676-0,"passage: I've had an off-line Christmas, during which I've been struck down with a particularly nasty combination of 'flu and a chest infection. After sweating it out for a week I finally decided it wasn't improving and went to see a doctor. Verdict: I think you're very ill. Exams are looming (they start on the 14th) and I haven't started revising yet. Ho hum."
677-0,"passage: I have no intention of starting a language war, but my God this is ugly. Still, I guess it must work for some people."
678-0,passage: How to write like a wanker is so true it almost hurts.
679-0,"passage: Every now and then I stumble across this and then lose it again, so I'm blogging it for safe keeping. The Anatomy of a Large-Scale Hypertextual Web Search Engine is the research paper that kicked off the Google phenomenon, and despite its age still provides a great insight in to how the world's favourite search engine works (or used to work)."
680-0,passage: Poor old AIFIA are still trying to explain what Information Architecture is in easily understood terms. Their latest effort should be pretty much garaunteed to succeed - 14 testimonials from web experts explaining why it is important in pleasant little sound bites.
681-0,"passage: Eric Meyer: ""Considered Harmful"" Essays Considered Harmful. That's a shame, because I was planning on writing one for target=""_blank"". I guess I'll have to find another way of expressing my forthcoming rant."
682-0,"passage: The result? No viral marketing, just because your URLs are too long. Bad way to lose business."
682-1,"passage: Jakob Nielsen: Top Ten Web-Design Mistakes of 2002. This is an astutely observed list, although I would add ""relying on Flash for navigation"" as one of the biggest modern mistakes (for some reason Jakob fails to mention Flash at all...). I particularly liked the following point about lengthy URLs, especially the (as far as I know) newly coined term social navigation."
682-2,"passage: Long URLs break the Web's social navigation because they make it virtually impossible to email a friend a recommendation to visit a Web page. If the URL is too long to show in the browser's address field, many users won't know how to select it. If the URL breaks across multiple lines in the email, most recipients won't know how to glue the pieces back together."
682-3,"passage: Jakob also mentions, among other things, javascript in links (and links that open in new windows) and fixed font sizes. As previously hinted, I have a mega-rant about the former lined up for some time in the next few days."
683-0,"passage: I had alway wondered why IE appears to work so fast sometimes (not that I am at all unhappy with the speed displayed by Phoenix). Now I know - unsurprisingly, IE and IIS are cheating. Read the explanation here (via mpt)."
684-0,"passage: A comment is a comment is a comment. Why should it matter whether it was posted using a web form, sent via email, entered into a blog, or posted to Netnews? From a blog reader's perspective, I'd just like to see a list of the comments, and not care (nor know) about how the comment got there. Presentation/interface should be designed to present the data (information), not the underlying plumbing."
684-1,"passage: [...] we now have Trackback and Pingback to help automate generating comment hyperlinks to blog-on-blog commentary. While I certainly applaud these efforts at automating the plumbing, I must ask - why is there any distinction in the presentation? I ask because many blogs present separate and different interfaces for their comments, trackbacks, and/or pingbacks."
684-2,"passage: Good point (besides, I'm kind of fed up of having a seperate counter for comments and pingbacks under every post). I'm sure I've seen a blog that combines comments, pingbacks and trackbacks in to the same interface - I think it was Sam Ruby's and I'm sure I've seen it elsewhere as well. Something else to add to the list for the forever forthcoming redesign."
684-3,passage: Tantek:
685-0,"passage: There's been something of a backlash against ""browser upgrade"" messages recently, for a variety of reasons. Now Jeffrey Zeldman, the man who brought upgrade messages widespread attention in the first place, has admitted that he too is moving away from them. With 4.0 browsers almost a thing of the past and awareness of web standards much greater than it was a year ago it looks like they may have hit their retirement date. Incidentally, Jeffrey's post includes the following piece of standards compliance propoganda which, while old hat to most people, I feel is still worth a quote:"
685-1,"passage:
The cost of bandwidth-intensive, invalid markup, and of detection scripts that continually run afoul of their target, is too high. Such methods waste site owners’ money in a futile effort to keep up with ever-changing browser versions. More importantly, they hurt web users, forcing everyone to download bandwidth-busting heaps of inaccessible junk markup and proprietary code forks so that an ever-shrinking minority of old browser users can have the exact same experience as the majority. (Meanwhile, this same junk code locks out screen reader and wireless users, and often denies access to the physically impaired as well.)
"
686-0,"passage: I agree with Brian that storing content as HTML (especially presentational HTML) could turn out to be a great mistake, but semantic XHTML provides a powerful and well defined format for storing content in a way that is both future proof and instantly accessible."
686-1,"passage: By carefully using semantic XHTML to store content, I gain the ability to easily extract and process information I have created using tried and tested XML tools. I can extract the links from an entry with a few lines of code, a technique used by my Pingback client implementation for this weblog. Furthermore, should I ever decide to serve my content in a different format I can do so using simple transformation tools that have already been created and extensively tested by other developers."
686-2,"passage: Since regular expressions were a bit risky, I decided to look at XML - after all, it boasts excellent support across multiple languages and platforms and is designed for storing content in the neutral manner I desired. I quickly realised I needed an XML tag set with support for the various content that I would be including in my blog - paragraphs, links, quotations, the occasional list and maybe a few other simple document components. Then I realised that XHTML offered exactly that, provided I stuck to the strict version and forgot about the presentation elements."
686-3,"passage: Both UBB code and WikiText have the disadvantage that they require extensive work with regular expressions to extract meaning from them. Regular expression support is excellent in the languages I normally work with (Python and PHP) but is not guaranteed across other technologies, especially when differences in regular expression syntax start to become a problem."
686-4,"passage: In Who dropped the deat cat into the well? (via Mark Pilgrim), Brian Donovan argues that keeping web site content in (X)HTML is a fundamentally bad idea. I thoroughly disagree. When I started this weblog, I realised I needed a format for storing my entries that would keep my content ""free"" to be reused in multiple different ways. I thought about a simple UBB style markup language, with [url=""http://www.example.com/""]links like this[/url], automatic line breaks and a few other simple structures such as lists and headings. I also considered Wiki markup of some sort, again looking for a reasonable expressive but controlled markup vocabulary for storing my blog entries in a reusable way."
687-0,passage: It seems Perl OOP doesn't have to be that ugly after all. Tony Bowden disects the code from the recent Evolt article and shows how it can be made much neater using Perl's Class::Accessor module. Much nicer - I should have guessed that there would be More Than One Way To Do It.
688-0,"passage: The MozillaZine Review of the Year 2002 shows just how far the Mozilla project progressed in 2002. From a 0.9.8 milestone in January, the open source browser bounded on past version 1.0 and span off popular sub projects in Chimera and Phoenix (soon to be renamed)."
689-0,"passage: Adrian Holovaty eloquently demonstrates why real page titles (as opposed to titles stuffed with meaningless marketing keywords) are so important, using local entertainment listings as his example. One site that would do well to take his advice (despite not being in the entertainments listings business) is The Register, which has been failing to provide story headlines in page titles for as long as I have been visiting it. This is almost certainly a flaw in their content management system, but in 2003 it is an inexcusable error to make."
690-0,"passage: Lots of people said it couldn't be done (myself included), but evidently we were wrong. Joe Gillespie shows how to achieve vertical centering with CSS in the latest edition of WPDFD. Via Craig Saila, who also has an experimental piece showing how the height of three divs can be set to the height of the tallest of the three, using javascript."
691-0,"passage:
I know wrapping your head around the idea of a wiki isn't the easiest thing (it took me many months between the first time I was exposed to one, and the time at which I found any use for them). Still, I'm surprised there isn't any sort of single community host for them. It seems like something I'd give someone five bucks a month for, to let me run a wiki that was instantaneous to sign up and get going.
"
691-1,"passage: While on Matt's site, I also noticed that he has launched stories.about.ticketstubs.org, an interesting concept site which encourages people to upload scanned images of their saved ticket stubs and tell a story about the night that the ticket stub represents."
691-2,"passage: Matthew Haughey asks why no one has launched a free host for people to set up Wikis, similar to blogspot for blogs or Yahoo Groups for mailing lists / collaborative communities. It's a good question."
692-0,"passage: Jeremy Zawodny demonstrates Spatial Indexes in MySQL 4.1. This clever new feature allows you to add data to a table in terms of geometric points, then run queries to find (for example) all points that occur inside a specified polygon. Weird and wonderful stuff."
693-0,"passage: Peter Merholtz has been thinking about collaborative software tools, and has concluded that the simplest are by far the most effective."
693-1,"passage: Surprisingly Peter fails to mention Wikis in his list of tools that do work - and from my experience of them Wikis are one of the most flexible collaborative tools around thanks both to their simplicity and their open ended nature. The comments attached to the story mention Wikis though, and also have some interesting thoughts on ""direct manipulation"" of content and the unix model of simple tools that work reliably for their purpose."
693-2,"passage:
This will likely frustrate the hell of out big software vendors, who want to develop over-engineered software solutions that require many servers and for which they can charge hundreds of thousands of dollars. Because, frankly, those things don't work. And these same vendors simply aren't interested in developing what does work, email applications and IM applications and web bulletin boards. And I suspect we'll see a lot of enterprise software companies go out of business, not because of a hurting economy, but simply because people realize that you can't automate unstructured collaboration, and that it's a foolish way to spend money.
"
694-0,"passage: Pepy's Diary is a serialization of the Diary of Samuel Pepys in weblog form, which launched on Christmas day plans to continue for the next ten years (the time period covered by the diary). The weblog is quickly becoming a meme, and Phil Gyford, its creator, has written an overview of how publicity spread after the diary's launch. He has also written a story for BBC News Online describing the project. I am reminded of Bloggus Caesari, a historical weblog by Julius Caesar."
695-0,"passage: I dunno, you take the evening off to watch a daft Bond movie (Goldeneye was showing on ITV and when you log on again the world is aflame with reports of Apple's new browser, Safari. To everyone's surprise it's based on the KHTML engine as seen in Konqueror, rather than using Mozilla's Gecko engine. I've used Konqueror a fair bit in the past few months and it really is an excellent rendering engine (I was amazed when it rendered all of my favourite CSS layout sites flawlessly) but this is still something of a shock, especially considering Apple's recent hiring of Dave Hyatt, a key member of the Mozilla project and the guy behind the excellent Gecko-based browser Chimera."
695-1,"passage: Mark Pilgrim appears to have the most in depth review of the browser so far (alas I lack an Apple Mac to play with new toys like this), but coverage is also available from Craig Saila, Jim Winstead, Scott Andrew, Leonard Lin and Mena Trott."
696-0,"passage: In response to Mark Pilgrim's Poisoning the envelope, Brian Donovan has expanded upon his opinion that long term web facing content should not be stored as (X)HTML:"
696-1,"passage: Again, I agree with Brian's points with respect to HTML. His argument fails however when you consider XHTML. The beautiful thing about (valid) XHTML is that it can be processed by any tool capable of processing XML. No hand editing is required - if you later need to convert your content to a newer standard (and personally I see XHTML 1.0 as a pretty stable horse) it takes a simple XSLT stylesheet, or possibly a short Python script. You have created future proof content without having to reinvent the wheel."
696-2,"passage: Do everything ""right"" (proper DTD's, validating all of your HTML, etc.) and, assuming that browser makers don't chuck backwards compatibility (about as reasonable as deciding not to pay for medical insurance because of your past track record of good health) and you will still either (1.) be locked into circa 2002 XHTML forever / until you find yourself with an extra month or two (or more) of free time and get the itch to go through several years of accumulated content to bring it up to spec or (2.) find yourself building a patchwork site because you've been incorporating recent developments as they've come along (i.e. all of the entries after 2006 use XForms where appropriate after MSIE 9, Opera 11, Moz3/NS 10 support finally solidified, but earlier entries using plain old (X)HTML forms)."
696-3,passage: Patching your cms (or getting/paying a someone to do it for you) from time to time could be (by far) preferable to and cheaper than periodically hand-editing several years' worth of articles stored in HTML format.
697-0,"passage: Seeing as Dorothea has years of experience as a markup expert, whereas I've only been using HTML correctly since last summer, I'll take her word for it that this is a problem (it certainly makes sense). I'm not a huge fan of additional semantics via the class attribute, but if you want to expand XHTML it can look like the only option. Perhaps this is where the modularisation of XHTML can come in to play? Lachlan Cannon's Inline XML story on ALA shows how namespaces can be used to embed custom XML information in an otherwise normal XHTML document, and it would be easy to build a simple CMS that could filter out this information before serving it to more simple web clients. Of course, this reintroduces the problem of having to define a custom XML vocabulary so in some ways it puts us back where we started."
697-1,"passage: Dorothea Salo has posted her thoughts on Semantic HTML as well. Dorothea points out that while pre-defined tags (paragraphs, lists and so forth) are well defined it is easy to run in to problems when you start to define extra semantics via the class attribute. Start with something like <code class=""python""> and the chances are that six months down the line your list of custom classes will have spiralled out of control, and as tools and validators will not be checking your class names (for typoes and so forth) you'll soon be in a whole world of trouble."
698-0,passage: [...]
698-1,"passage: Dave Hyatt has renamed his weblog Surfin' Safari and is extensively documenting the Safari team's progress in fixing problems and making their browser even more standards compliant. He has also been responding to questions posed by the blogging community concerning the new browser. Of particular interest is this post explaining the thinking behind Safari's controversial User Agent string (which identifies itself as ""like Gecko""):"
698-2,"passage: We chose to be more like Gecko than like MSIE because we wanted to be lumped into the standards compliant category, because fundamentally we are committed to supporting DOM 1&2, CSS1&2, and enough proprietary MSIE extensions and Gecko extensions (innerHTML, createContextualFragment, offsetWidth/Height, etc.) that we could be placed in a similar category."
698-3,"passage: The reason it is there is that in order to work with real-world DHTML sites you have essentially two options: you can claim to be MSIE or you can claim to be Gecko. We found that any other choice that we tried led to a significant portion of DHTML malfunctioning. You would not believe (well, maybe you would) how much DHTML exists out there that works only with MSIE or Gecko, and that uses proprietary extensions of each to accomplish the DHTML effects. Had we released a browser with a UA string that did not superficially match either MSIE or Gecko, users would have downloaded Safari and experienced many malfunctioning Web sites."
699-0,"passage: Craig Saila notes that the W3C have released DOM Level 2 as a recommendation and simultaneously recommended against its use in an article on News.com. Scripts should be used sparingly as they are less machine-readable or transparent than so-called declarative languages like SVG and SMIL. I'm a big advocate of the labels.js school of scripting where DOM scripts are used to enhance the functionality of a document using the semantic structure of the underlying XHTML, while degrading gracefully (and without loss of information) in user agents without the required javascript support."
700-0,"passage: In-Room Chat as a Social Tool: Clay Shirky describes an experiment with an online chat room set up to accompany a meeting of 30 people taking place in the same room. The chat room (available to attendees via Wifi laptops and displayed on a big screen at the front of the room) had some interesting effects on the dynamics of the meeting, not least of which was the dramatic impact the chat room had on the ""interrupt logic"" of the proceedings."
701-0,"passage: The current extended discussion over whether or not Safari should have some kind of specific CSS blocking technique built in (sparked off by Mark Pilgrim) reminds me of a relatively unpublicised feature of Internet Explorer called conditional comments. These specially crafted HTML comments allow web authors to specifically hide code from versions of IE, or alternatively to hide code from any browsers that are not a specified version of IE. Here's how they work:"
701-1,"passage: The downside of this approach is that it encourages ugly browser specific code to be added to the HTML of a page. Adrian Holovaty's suggestion for Safari is similar but, in my opinion, more elegant as the unpleasant code is restricted to the stylesheet (I always prefer nasty hacks to stay out of the way in the stylesheet rather than rearing their ugly heads in my markup)"
702-0,passage: Name your sections carefully (via Adrian) discusses how news (and other) sites could end up adversely affecting their content through badly chosen URL schemes.
703-0,passage: Stuart has a good summary of the recent advances being made in the Pingback/Trackback implementation sphere.
704-0,"passage: Mark Pilgrim is unhappy with XHTML 2.0. Since the rest of the blogging community has already provided mass commentary on his post, I'll make an observation concerning his further reading feature instead. The first link I saw to Mark's post (and the one I followed) was on techno weenie, but I was surprised to later notice that techno weenie was not listed in the further reading list. For those who haven't been paying attention, Mark's further reading list is automatically generated from referrals, with verification from a clever Python script that checks the source page to make sure there really is a link, extract a relevant portion of the page and attempts to find a permalink for the entry as well."
704-1,"passage: There isn't really a moral to this story, I just thought it was interesting."
704-2,"passage: Mark's system usually has a very high success rate, so why had it not picked up on the entry on techno weenie? On closer inspection of the entry in question, I noticed that the only link back to Mark's entry was the ""source"" link at the bottom of the quote. Suddenly it clicked - could Rick be using a DOM script to extract the cite attribute of the blockquote and display it on the page? I checked the code and, sure enough, Rick was using the script I published back in December. Mark's script looks for a ""real"" link in the page, and since the look was generated on the client side from the DOM it failed to find one and assumed that the referral was invalid."
704-3,"passage: Also spotted in Mark's further reading list, Tom Gilder has finally set himself up a blog. He promises lots of rants. This is a good thing."
705-0,"passage: Scott makes an interesting observation: Are blogs nothing more than agents for the internet?. A few years ago ""intelligent agents"" which knew your tastes and found content you would be interested in were the Next Big Thing™. Scott points out that by reading bloggers with similar tastes to us we are essentially getting the same service, with a nice human touch."
706-0,"passage: News.com: Apple snub stings Mozilla. Surprisingly comprehensive coverage of the Mozilla communities reactions to Safari. What impressed me was the number of links to weblogs in the news story. It looks like CNET ""gets"" blogging."
707-0,"passage:
Maybe one day, I’ll post a comment somewhere, and when someone responds, a CommentBack will be sent to my CommentBack server, and I can click straight to the response.
"
707-1,passage: Paul Freeman:
708-0,"passage: One for the reading list: The Making of Python - A conversation with Guido van Rossum, Part I."
709-0,"passage: Oooh... Stuart has moved his blog over to Vellum, his brand new sparkly Python powered blogging system. The full post is here, but his archive / permalinks aren't working yet. It's going to be fun watching the system develop."
710-0,"passage: As always, Mark Pilgrim provides an excellent example by adding both titles and abstracts (mentioned by James in his metadata article) to hist posts and serving them up with the search results. I don't think I have the energy to go back over all my old posts and add abstracts but some day I'm going to have to go back and add titles (probably adapting most of them from the permalink almost-titles I have already). But not today. Today I'm revising Lamda Calculus."
710-1,"passage: Not one, but three gems from James Robertson:"
710-2,"passage: One thing that I think is missing from the metadata article (probably because it is so obvious) is the importance of the availability of a good title for each piece of content. When I started this blog I chose not to use post titles as I wanted entries to stand together on the day they were posted rather than existing as completely unique entities. When I later changed my comments system to avoid popup windows I was forced to make entries available on their own page anyway, with the lack of titles forcing me to title the page with the date of the entry rather than something more explicit. Further more, when I finally get around to implementing a search engine I will probably be forced to return entire entries in the results rather than just a relevant extract thanks to the lack of a title to display on the results page."
711-0,passage: Aww crap.
712-0,"passage:
I always said that my ""further reading"" was like a prisoner's dilemma: great for me as long as nobody else did it. Once everybody's doing it, the feedback loops start and the signal-to-noise ratio skyrockets and it becomes worthless.
"
712-1,passage: Mark Pilgrim has been having an interesting problem with his Further Reading feature: Feedback loops.
713-0,"passage: I just noticed that PEAR is finally out of beta. This means that the PEAR installer will be included with PHP 4.3, but more importantly it means that the PEAR website finally has a usable navigation system."
714-0,"passage: Mark has hit on the clever idea of using the body tag's id attribute to apply different styles to different pages all from the same stylesheet. The technique is very neat, but it would be even neater if he combined it with Eric Meyer's CSS Signatures to allow advanced users to specify their own styles for his site. Since the ID attribute can't be overloaded with more than one value doing so would probably mean having to use the body tag's class attribute as well - the id attribute could hold the signature while the class attribute specified the page (or vice versa)."
715-0,"passage: Aquarion points out a truly moronic ""browser upgrade"" notice. I especially like Anything larger than 800 x 600 is too large, and the pages do not diosplay [sic] properly."
716-0,"passage: Stuart has released the code for Vellum, his new Python blogging system. I haven't tried it out yet (the installation process is pretty in depth and I don't have a properly configured server to hand) but it looks damn sexy. Key features include:"
716-1,passage: All in all it looks like a really smart system. It's going to be fun watching it evolve (comments are promised as a soon-to-be-added feature).
717-0,passage: Les Orchard describes an intriguing blogging tool built with AppleScript that posts links to a weblog when they are dragged on to a special folder on the OS X desktop.
718-0,"passage:
Often times, I like to think of these little thought experiments. Imagine the inventor of the wheel, or of stone cutting implements getting and enforcing a patent. Or perhaps the English language being under the modern notion of 'copyright'. Where would we be today? We won't have to wait long to find out I suspect. Our society seems perfectly fine with the unlimited expansion, in both breadth and length, of 'intellectual property'.
"
718-1,passage: A top notch rant from Leonard Lin:
719-0,"passage: Via Anitra Pavka (who has an excellent usability and accessibility weblog): Colourblind Web Page Filter, a clever server driven tool which shows how web pages would look to people suffering from three different forms of colour blindness."
720-0,passage: Codewalker.com have a tutorial up describing PEAR's ITX template system. Their forums also have an explanation of how bitshifting operators work in PHP (in the fifth message from the bottom of the thread).
721-0,"passage: It sounds like Paul Graham's Spam Conference was a huge success, with attendance rocketing to 560 from the original estimate of 50 - 60. Scott Johnson sings its praise and promises a full write up later on. In the meantime, webcasts of the talks are available on the conference website."
722-0,"passage: Larry Lessig has a new campaign: a ""copyright tax"" that kicks in 50 years in to a copyright term, demanding copyright owners to pay a nominal fee ($1 - $50) to maintain control of their copyright. Unused works that are no longer profitable should then default to falling in to the public domain, while more commercial works can stay copyrighted. Larry's idea was first announced in this New York Times Op-Ed and is also covered on Lessig's blog. He has also published an FAQ."
723-0,"passage: The script works fine in Mozilla 1.2, Phoenix 0.5 and IE6. It fails in Opera 7, thanks I think to problems dynamically adding new events in that browser. I would love to hear if it works in other browsers, especially Mac browsers such as IE 5 and Safari. Any suggestions on further improvements to the script would also be very welcome."
723-1,"passage: In these days of standards, the DOM and separating structure from presentation this is no longer good enough. Image rollovers are a presentational nicety - they add nothing to the underlying meaning of the document and as such I see no reason to pollute my markup with code to support them. I'm always on the lookout for fun new ways to use the DOM (see blockquote citations) so I took it upon myself to improve the situation. The first iteration of my improved rollover script, rollovers.js, is demonstrated here."
723-2,"passage: The approach I have taken is to give any images that are to have a rollover a CSS defined background image and a class attribute of ""rollover"". The rollovers.js script then finds all images with that class name and adds onmouseover and onmouseout events to them (using Scott Andrew's addEvent function to avoid cross browser incompatibilities). When an image is rolled over, the image is replaced with a preloaded transparent gif allowing the background image to show through. The gif is switched back to the default image when the mouse moves away."
723-3,"passage: When browsing through other site's source code, some of the ugliest HTML occurs when the site uses one of the most basic javascript effects: The image rollover. There are a myriad of these scripts available for free on the web, but as far as I can tell every single one of them requires event handling code to be added to the markup of the page."
724-0,"passage: And here's Daniel Nolan's standards compliant rollover script, which uses a different approach (based on rollover images using a standard naming convention with a suffix attached to the name of the original image) but achieves the same effect, working in Opera 7 as well. It also uses a neat way of adding events using javascript function prototypes."
725-0,"passage: Pythonology (via Deadly Bloody Serious about Python) is a Python advocacy site aimed at software engineers and managers. The site has a fantastic collection of case studies, Python Success Stories, which an interesting piece describing why and how Rackspace migrated their main enterprise data system from PHP to Python."
726-0,passage: I just can't figure out how Recursive was made.
727-0,"passage:
I'm old school. I think the cool thing about weblogs is that they are not discussion groups or mail lists. If I want to know what all the people are saying there are ways to do that, but very often I'm content to read email and a few weblogs that I trust. Personally I don't think there's gold in them thar hills, but of course I've been wrong before.
"
727-1,passage: Dave Winer on TrackBacks and push backs (and presumably PingBack as well):
727-2,"passage: So that's my rant. Unfortunately, seeing as I'm unlikely to feature on Dave's ""few weblogs"" that he trusts the chances are he'll never read it. Çe la vie."
727-3,"passage: Mark Pilgrim knows this, and his Recommended Reading and Automatic Linkback tools provide him with an excellent way of participating in the global conversation. Dave Winer, as a contrast, appears to treat his blog as read-only - no comments, no trackbacks. There's nothing wrong with this (how someone runs their blog is a very personal thing) but I can't help but think that by doing so Dave is missing out on a truly remarkable example of the two way web in action."
727-4,"passage: I think Dave has missed the boat on this one by a long way. Just the other day I realised that weblogs (or at least the one's I read) are essentially a huge global conversation. Anyone can join in, but the price of entry is having your own blog and something interesting to say. With those two pre-requisites the social network of the blogosphere does the rest - people will see what you have to say via random browsing, links on other blogs, TrackBack return links and so forth and before you know it your (useful) opinion will be being read by people who normally you wouldn't communicate with in your entire lifetime."
728-0,"passage: The idea as it stands is great, but at the moment it fails to address discussion forums that do not require the user to create an account (many blog comment systems for example). These could probably be served by a single text field asking for your optional You-Know-Me address. The problem that arises then is that of authentication - what's to stop someone maliciously signing you up for comment threads without your consent? The spectre of spam can't be too far over the horizon."
728-1,"passage: I have no doubt that someone will come up with solutions to any issues with Dave's system, and I look forward to seeing the spec develop. Once a basic protocol has been laid down the possibilities are huge - I-Know-You to RSS/email/Jabber gateways are an obvious extension that could be great fun to hack around with. It's been a while since I've messed around with web services and my XML-RPC library could do with an update."
728-2,"passage: Maybe a solution would be to turn subscription in to a two-step process - first you tell the comment thread your details and have it ping your identity server, then later on you visit the web application running on the identity server and ""approve"" that subscription. That should defend against unwanted subscriptions, but it also adds another layer of complexity to what should be an automatic process. You would also have to do this for every unauthenticated thread you subscribed to (I imagine that authenticated account based subscriptions such as the ones Dave describes in his initial article would handl auto-subscribing you to all threads you participate in)."
728-3,"passage: Dave Winer: The ""You Know Me"" Button. Dave hates posting comments on blogs and then having to check back constantly to see if anyone has replied (I do too). Sam Ruby's solution is to provide the comments as a separate RSS feed for each of his entries, but Dave wants something more automatic that won't clog up his aggregator. Dave's new proposal is intruiging to say the least. When you sign up for an account with a discussion forum you have the option of configuring a link to an ""identity server"" able to respond to a specific protocol. Once this has been done, the discussion software ""pings"" your identity server with your username and a message whenever someone responds to one of your posts."
729-0,"passage: So is it possible to stay open while maintaining a super high traffic site? Slashdot's moderation system has had a huge amount of effort put in to it but most of the discussions still devolve in to all out flames with useful comments failing to rise out of the morass. Trust metric is an interesting concept where user's boost each other's reliability ratings (the best implementation I've seen of this is Advogato) but such a system does not readily map to blogs where authentication systems are mostly non-existent - besides, a system based on who knows who will exclude the outside voices that we have already established may have interesting things to say."
729-1,"passage: Another Dave inspired post: It seems I misunderstood Dave's objections to blogging feedback mechanisms yesterday. I thought he was ruling out what I see as an invaluable tool for low traffic bloggers, but in fact his main complaint was that things like comments / TrackBacks and so forth simply don't scale. Mark Pilgrim echos his complaints, pointing out how overwhelmed his blog was with auto-linkbacks from his Safari review. l.m.orchard concurrs: At present, I'm safe. My rating is Mostly Harmless, so all my open systems are mostly free from abuse. But, the first time I really strike a nerve somewhere, I'm a sitting duck."
729-2,"passage: I guess scaling the two way web is what my Software Engineering lecturers would call a ""wicked problem""."
730-0,"passage: Craig Saila points to the SearchEngineWatch Webpage Size Checker. It's a nice tool, but it doesn't appear to take the size of linked style sheets in to account. I was playing around with the idea of a web page cache written in Python over Christmas and I hit the same kind of problem - while finding linked stylesheets using Python's HTML parser wasn't too difficult (and could be achieved equally well using a regular expression) things get a lot hairier when you start to take @import statements and CSS defined background images / custom bullet images in to account. Again I imagine a solution could be hacked out with regular expressions but a nicer method would be some kind of CSS parser (the Python standard library has yet to include one). Maybe another project for a rainy day..."
731-0,"passage: Vellum 1.0a4 is out, and features comment support via a new Comments plugin and an Audience generic object type that abstracts the concept of ""responses to your post"" and is also used for Pingback support. Different response types within the same interface is a very neat idea, as Sam Ruby has demonstrated with his integrated comments, referral tracking, Pingbacks and TrackBacks. Stuart also suggests auto-discovery of You-Know-Me information from the URL of your weblog, presumably by another link element. This is a great idea, but I have reservations about the performance trade off as unauthenticated comment systems will have to retrieve the poster's home page in the background every time they make a post."
732-0,"passage: Scott Andrew points out another smart trick with body tag ID attributes - selectively showing and hiding navigation elements depending on the current page. This is a really neat idea, but it does lead to a blurring of the lines between structure and presentation - if a navigation section isn't relevant to a particular page this should be mirrored in the markup rather than worked around by the CSS. That said, there are some nice presentational touches which could be achieved with this technique without sacrificing structural purity, such as highlighting the navigation menu item for the current page in a different colour:"
732-1,passage: But then I suppose you could argue that the link to the current page shouldn't be a link at all.
733-0,passage: Anil Dash: Diamonds are for never. A thoroughly entertaining and educating rant about the Diamond industry. Some day I hope to be this articulate.
734-0,"passage: Found via PPK, this Object Model Browser is a nice tool for browsing around the available DOM properties and methods in different browsers."
734-1,"passage: PPK's ever excellent JavaScript Section now features updated DOM compatibility tables for W3C Core and W3C HTML. The tables contain detailed descriptions of suport for DOM features in IE 5 and 6 for Windows, IE for Mac, Mozilla 1.2, Safari 1.0 Beta, Opera 7 Beta and iCab 2.8.2. I've been playing around with the DOM quite a lot recently and the differences between IE and Mozilla were driving me up the wall - I only wish I'd found this fantastic resource sooner."
734-2,passage: PPK's W3C DOM vs. innerHTML demonstration is interesting as well - it compares the performance of the W3C and Microsoft's widely supported innerHTML extension for generating large amounts of new page content.
735-0,passage: I'd go for the third one any day.
735-1,passage: The path Python module (via The Daily Python-URL) is a nice looking wrapper class for Python's oft-confusing os.path module. Check out this neat code comparison:
736-0,"passage: A message to clueless website authors is an entertaining and informative rant against browser specific, standards incompliant sites. Via Aquarionics."
737-0,"passage: It looks like Adequacy.org has come to an end. For those unfamiliar with the site, it was a truly unique evolution of the common internet troll. Adequacy specialised in posting stories that were deliberately designed to cause controversy, then sending out carefully crafted ""invitations"" to any online communities that were most likely to take the bait. Since, unlike other trolling situations, the trolls were now in control of the discussion they could prolong the scam by deleting any comments which had figured out what was going on and were trying to warn other clueless participants."
737-1,"passage: The best explanation of the site is probably this one, by Stuart Caie. An archive of adequacy stories is still available on the site - I recommend the classic Is Your Son a Computer Hacker? (sadly archived without comments) for an example of how the site used to work."
738-0,"passage:
MySQL Version 4.1 includes support for SQL subselects, also called subqueries or nested queries, a powerful feature that lets users search complex data with ease and efficiency. With subselects, users can achieve query consolidation by nesting one query inside another query, creating a resource otherwise unavailable for searching in a single statement. Subselects allow users to query within a result set, creatively limit the result set or correlate results with an otherwise unrelated query in a single call to the database.
"
738-1,"passage: MySQL Adds Subselects, Upgrades Performance and Security:"
739-0,"passage: Scott is horrified by the fact that some American political organisations are co-ordinating massive ""letter to the editor"" campaigns using email lists and websites. It's certainly a worrying trend, but once again Google comes to the rescue. Try this query and see for yourself."
740-0,"passage: Here's a novel use of a stylesheet switcher: Providing a ""work safe"" edition of a weblog."
741-0,"passage: Dynamically extending APIs: Mark Pilgrim demonstrates how Python's ""new"" module can be used to dynamically add new methods to existing classes at run time, and shows how this can be used to increase productivity when parsing XML. I've long been impressed with Python's ability to add new methods to an object at runtime just by assigning a function reference to an object property but I had no idea it was possible to do this with classes as well. If you liked that tip, Dive Into Python has in depth explanations of more obscure Python features than you can shake a stick at."
742-0,"passage:
A question for CSS design gurus. What's the best you can do with a table that has three columns like the one on Weblogs.Com. Let's see an example. I'd like the page to look good and load fast. Postscript: No one seems to understand -- I want to do weblogs.com without a table. Column 1 is the number, column 2 is the name of the weblog. Column 3 is the time it last updated. Look at the page.
"
742-1,passage: Dave Winer:
742-2,"passage: I've tested it on Phoenix 0.5 and IE 6 on the PC and it worked fine. However, I would be surprised if it worked flawlessly on all modern browsers as it makes heavy use of an absolutely positioned element inside a relatively positioned element. As a result, the data is probably best left as a (perfectly semantically valid) table."
742-3,"passage: At first glance this seems an odd request - from a semantic point of view, the data on Weblogs.com is tabular in nature and would seem like a fine place for a table. I imagine Dave's request relates to performance - I don't know if modern browsers still refuse to render tables until they have loaded all of the content but if that is the case then the Weblogs page could be pretty slow on a narrow-band connection. In any case, the data on the page could also be interpreted as an ordered list. I can never resist a challenge so I had a go."
743-0,"passage: Also, I know it isn't what Dave was after but I've recreated the front page of Weblogs.com in structural/semantic XHTML and CSS as well. Again, it works fine in Phoenix and IE 6 but probably needs a few tweaks for other modern browsers (and Netscape 4 gets a plain layout without any styles at all). I've actually got quite a large collection of ""markovers"" now - I started doing them last year while learning CSS and they have been accumulating ever since. One of these days I plan to put them online together with a basic overview of the techniques used and problems encountered with each one."
744-0,"passage: Via Inluminent, a short Q&Awith Rusty of K5 discussing the site's innovative new text-ads-with-comments format."
744-1,passage: It's probably too radical to take off as a mainstream advertising technique (most companies would run a mile at the idea of unmoderated comments appended to their adverts) but I can see it working really well on many community style sites.
744-2,"passage: ""And for the users, the benefit is that they can see what others have said abut the product, whether that's good or bad, and how the advertiser has dealt with other people. A key feature of this is that ad discussions operate according to K5's normal discussion rules -- comments can be rated by everyone, and aren't subject to the desires of the advertiser."
744-3,"passage: ""It definitely is better understood by some advertisers than others. The idea behind ad comments is two-fold. First, for the advertiser, the benefit is that potential customers can meet you on ""neutral ground,"" ask questions and get more information in a place they're already comfortable. It gives advertisers a space they can use to tailor their message to individuals, rather than keeping them at the kind of impersonal distance that a banner ad can create."
744-4,"passage: Quite frankly, I think this is a truly inspired twist to internet advertising. A text ad on its own (as seen on Google, for example) is a couple of lines of text trying to convey a whole bunch of information. They are trivial to ignore - in fact I suspect I am already developing a form of ""banner blindness"" towards them. K5 ads are different - it's a text add, but what's this ""131 comments"" link? Suddenly the tiny advert has become the gateway to an informative two way discussion about the product. Smart companies can get stuck in with potential customers, answering questions and generally demonstrating that they know what they are talking about and are worth doing business with."
745-0,"passage: I've knocked up another attempt at Weblogs.com in CSS, this time using floats instead of absolute/relative positioning. It seems to work pretty well."
746-0,"passage: Other weblogs.com remakes: (via Scripting News): Gary Taylor, Dave Polaschek, Douglas Bowman. Doug's is particularly impressive, featuring an almost pixel perfect recreation of the original page with nice semantic markup and nods towards accessibility as well."
747-0,"passage: Weebl and Bob like pie. I also like pie. Luckily for me, my girlfriend, while frequently a disaster in the kitchen (rice and OXO gravy anyone?), is a truly accomplished pie chef as of last night. She has posted her delectable recipe here. Her chocolate chip cookies are even better."
748-0,"passage: The only thing I'm really missing is a good text editor - I'm spoiled for choice, but nothing I've played with so far has been half as productive as UltraEdit. I think I need to pick a Unix editor and stick with it until I've learnt it inside out, but deciding which one to dedicate myself to is proving difficult."
748-1,"passage: Phoenix on Linux is exactly the same as Phoenix on Windows, and remains an absolute pleasure. My mail is now handled by Evolution, which has been crunching through my six week backlog (don't ask) on both of my mail accounts with consumate ease, thanks to the excellent filtering. I've also been introduced to Dillo, a truly tiny graphical web browser (less than 200KB compiled) which never the less does a great job of rendering table based sites at almost ridiculous speeds. CSS is completely ignored, but CSS sites tend to be perfectly usable without formatting anyway."
748-2,"passage: I never thought I'd actually do it, but I've switched. Not to one of these (I only wish I could afford it), but to Mandrake 9. The way I figured it I only ever use Windows 98 for browsing the web, editing text files and messing around with Python, so I might as well get stuck in to a more exciting operating system with the same capabilities."
749-0,"passage: Two fun bits from the Daily Python URL today (still without permalinks). SQLObject is an object-relational mapper class which can create objects that directly map to rows in a relational database, making INSERTs and UPDATEs much simpler. I've tried to write this kind of thing in PHP before with mixed results, so I'm quite tempted to pinch the idea of tracking foreign keys and joins for my next attempt. More immediately useful however is rlcompleter2 which adds tab based auto completion to the Python interactive prompt. I had a play with it earlier and it was definitely an improvement on the vanilla command line."
750-0,passage: Off to Amsterdam. Back Sunday.
751-0,"passage: I'm still not quite impressed enough to learn Perl, but I'm very tempted to borrow some of the ideas and re-implement them in PHP or Python."
751-1,"passage: Via Keith Devens, Screen-scraping with WWW::Mechanize describes how Perl's WWW::Mechanize module can be used to grab information from sites that require a user login. I've always dismissed screen scraping as something of a wasted effort, given the fact that a major rewrite of the scraper is required whenever the target site tweaks its HTML. This article has encouraged me to reconsider - some of the functionality in WWW::Mechanise is fantastic:"
751-2,"passage:
We create a WWW::Mechanize object and tell it the address of the site
we'll be working from. The Radio Times' front page has an image link
with an ALT text of ""My Diary"", so we can use that to get to the right
section of the site:"
751-3,"passage: Now we can fill in our e-mail address for the '<INPUT name=""email""
type=""text"">' field, and click the submit button. Nothing too
complicated."
751-4,"passage: The returned page contains two forms - one to allow you to choose from a
list box of program types, and then a login form for the diary
function. We tell WWW::Mechanize to use the second form for input.
(Something to remember here is that WWW::Mechanize's list of forms,
unlike an array in Perl, is indexed starting at 1 rather than 0. Our
index is, therefore,'2.')"
752-0,"passage: Via Paul Freeman, detailed instructions for installing Stuart's Vellum Python blogging system on Windows using either IIS or Apache."
753-0,"passage: In response to yesterday's screen scraping post, Richard Jones describes a screen scraping technique that uses PyWebPwerf, a Python performance measuring tool."
753-1,"passage: I forgot to mention it in the article, but Snoopy is a PHP web client library which can retrieve content and emulate a browser interacting with forms. I've used it for simple screen scraping before, but it still lacks some of the more impressive functionality that WWW::Mechanize demonstrates."
754-0,"passage: 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."
754-1,passage: [...]
754-2,passage: Definition lists vary only slightly from other types of lists in that list items consist of two parts: a term and a description. The term is given by the DT element and is restricted to inline content. The description is given with a DD element that contains block-level content.
754-3,"passage: It makes sense in that ""Relevant Externals"" is a definition of the following list of defined terms. The official specification for definition lists is notoriously vague in any case:"
754-4,"passage: I'm really liking Jeffrey Zeldman's latest redesign. Aside from a pretty face, the markup holds some interesting ideas as well. For example, I've never seen a definition list used for a blogroll style list before:"
755-0,passage: Dave Winer asks why Joel Spolsky gets much more traffic when slashdotted than UserLand's hosted sites tend to. Joel explains (it's all down to network effects) and mpt kicks in a few ideas as well.
756-0,"passage: Paul Tchistopolskii's XML Alternatives reminded me to take another look at YAML. The specification has been updated since I last looked and seems to be a bit more complicated, but it's still a very nicely designed format. Implementations are available for Perl, Python and Ruby with C and Java on the way but strangely no one seems to be doing one for PHP yet. I'm doing a course at Uni on compilers at the moment which includes quite a lot of stuff about writing parsers so I'm very tempted to have a go at a YAML implementation in the next few weeks just to try stuff out. The possibility of easily swapping relatively complex data structures between PHP and Python is pretty tempting as well."
757-0,"passage: Via Leonard Lin, a nice demonstration of an enhanced HTML text area (with buttons to add tags) that works in IE, Mozilla and Phoenix. Until recently this had not been possible thanks to a long standing Mozilla bug."
758-0,"passage: I have severe trouble browsing without gestures these days, but the biggest time saver of them all has to be the W3C validation gesture - draw a V on the page and instantly see if it is valid [X]HTML or not."
758-1,passage: Optimoz have released Version 0.3.5 Release Candidate 3 of their mouse gestures add-on for Mozilla based browsers. I hadn't tried the version 0.3.5 series before and the improvements are impressive to say the least:
759-0,"passage: And over on Blogzilla, Lim Chee Aun has finally solved the niggling bug with Phoenix 0.5 on Windows where the icon shown in the taskbar is an ugly default Windows image."
760-0,"passage: It looks like Scott got burned by a PHP MeetUp arranged at an out of business restaurant that then failed to materialise at all. From his comments it seems like he's not the only person to hit problems. I have yet to attend a meetup (the Bristol UK ones rarely have anyone sign up for them) but I love the concept, so it's a real shame to hear about problems like this. Hopefully the MeetUp team are working on ways to stop this kind of thing from happening - some kind of short-lived email mailing list for each location/event might go some way to ensuring people who sign up for them know what's going on and bother to show up. At least their recent changes page shows that they have been actively trying to improve the overall experience."
761-0,passage: Real girls eat beef. Cool-2B-Real was brought to you by the Cattlemen's Beef Board and the National Cattlemen's Beef Association.
761-1,"passage: Cool-2B-Real is a site for teenage girls. Real girls are ""keepin' it real"" by building strong bodies and strong minds... and they're feeling great about themselves! It has health and fitness tips, tips on feeling good about yourself, a poll (""What type of beef do you most like to eat with your friends?""), and a set of Smart Snackin' recipes such as Nacho Beef Dip, Beef on Bamboo, Easy Beef Chili and Roast Beef and Veggie Wrap. And beef games too."
762-0,"passage: Does anyone know if it is possible to find an HTML element's exact position on the page (in terms of pixels-from-the-top and pixels-from-the-left) using javascript? The element I have in mind is an image that has not had any positioning applied to it, but I imagine any solution will work for other elements as well. I need something that works in Mozilla/Phoenix, although a solution for IE would be nice as well. It's for a bookmarklet I'm thinking of writing."
763-0,passage: Update: It turns out the bookmarklet only works for pages that aren't being served with an XHTML doctype. Curious.
763-1,passage: I got a good response to yesterday's call for help on finding an HTML element's co-ordinates on a page. I ended up using PPK's findPos functions which seemed to do the trick just fine.
763-2,passage: Here's the result:
763-3,"passage: Image Drag (bookmarklet, drag on to your links bar)."
763-4,"passage: Image Drag makes every image on a page ""draggable"", using youngpup's DOM-Drag library. It works by ""cloning"" each image on the page and making the clone an absolutely positioned, draggable element then changing the original image to a transparent pixel of the correct width and height. I wrote it because I wanted my girlfriend to be able to play with GothMaker in Phoenix instead of IE, but it works for other pages too. There is a weird bug which affects any pages that use absolute positioning (such as this one) - I think it's a bug in DOM-Drag rather than a problem with findPos but I'm not entirely sure what's causing it."
763-5,passage: The bookmarklet works fine in Phoenix (on both Linux and Windows) but doesn't work in IE. I'm not too bothered about this - with IE6 nearing it's second birthday if you are still using it you should seriously considering upgrading to something a bit more up to date anyway.
763-6,"passage: Since most of the sites linked to from this one use absolute positioning, here are a few which the bookmarklet works well on that are fun to mess around with:"
763-7,"passage: Incidentally, although it's only meant as a fun distraction, having played with it a bit it looks like it could be quite useful as a tool for web site design tweaks such as seeing if the page would look better with images moved around a bit."
764-0,"passage: Via Scott, a clever PHP technique for ensuring data sent to the browser as a cookie or hidden form variable isn't tampered with by the user:"
764-1,"passage: Incidentally, while the hashing method is clever and should be nice and secure I personally advocate not sending the user any information unless absolutely necessary - use sessions and store sensitive data on the server instead. I suppose you could always use the hash to add an extra layer of security to the session identifier though."
764-2,"passage: A further explanation and example code can be found in PHP and the OWASP Top Ten Security Vulnerabilities, a handy article describing how PHP coders can combat the top ten web application security problems highlighted by a recent report from OWASP. Incidentally, OWASP still haven't fixed the cross site scripting vulnerability on their own site, discovered by Tom Gilder several weeks ago."
764-3,"passage:
If you're expecting to receive data in a cookie or a hidden form field that you've previously sent to a client, make sure it hasn't been tampered with by sending a hash of the data and a secret word along with the data. Put the hash in a hidden form field (or in the cookie) along with the data. When you receive the data and the hash, re-hash the data and make sure the new hash matches the old one.
"
765-0,passage: Mark invoked the lazy web earlier today in a bid to find a good way of bulk optimizing PNG files. Several people recommended pngcrush in the comments and it sounds like a fantastically useful piece of software - apparently it can run 114 different lossless compression methods on an image and automatically chose the most efficient one.
766-0,"passage: Stuart has posted yet another inobtrusive DHTML gem - Nice Titles, inspired by a thread on web graphics."
767-0,passage: In-Valids is an enjoyable rant by Joe Clark chastising the big guys on the web for being completely incapable of producing valid HTML.
768-0,"passage: Peter Van Djick asks why does hardly anyone use LABEL tags? It's a very good question - in my opinion label tags, like title attributes on links, are a complete no-brainer. They're well supported by all modern browsers, completely backwards compatible (in that there are no ill effects for older browsers), great for accessibility and easy to implement. They're much more than just an accessibility issue - the usability of a form is dramatically increased by the addition of label tags, especially for radio and check boxes where they greatly increase the ""target area"" for the user to click on."
768-1,"passage: If you aren't using label elements, now's the time to start."
768-2,"passage: The for attribute on the label links it to the form element with that ID. When the user clicks on the label, their cursor will jump to the form field. If the targetted form element is a check box or radio box clicking the label text will toggle it. Labels can by styled using CSS just like any other element - I often use display: block to stack them above their corresponding form elements to save me from having to mess around with the layout of a form, as can be seen on my Contact Page."
768-3,"passage: In case you haven't come across them before, here's how they work:"
769-0,"passage: Dorothea Salo explains the thorny problem of indexing (the back-of-a-book kind rather than the search-engine-spider kind) marked up electronic documents. Another example of what my first year software engineering lecturer would call a ""wicked problem""."
770-0,passage: Image Drag
770-1,"passage: Boris Zbarsky offered a fix for my image drag bookmarklet's problems in Strict doctype pages. The problem was due to Mozilla, when operating in strict mode, refusing to absolutely position elements that don't have a unit of measurement specified. The bookmarklet now works perfectly on pretty much every page I've tried it on."
771-0,"passage: This weekend I started work on my latest web project, further details of which will no doubt follow soon. For the moment I'll just say that it follows the classic news/articles/users with logins model - basically another small-to-medium sized PHP content management system."
771-1,"passage: This time I told myself firmly that I wasn't going to reinvent the wheel and I wasn't going to build myself yet another web framework library. I had a look at a whole bunch of Open Source systems (mostly thanks to opensourceCMS but none of them seemed to fit my (admittedly pretty stringent) requirements. I was looking for something flexible and easily modified with a well defined API, strictly standards compliant, structural/semantic templates, excellent CSS support, an easily extended user and permissions system, a powerful but straight forward control panel and a well designed, object oriented code base. It also had to be suitable for a team of programmers to hack on together, as the site will be maintained by a group of coders. With requirements like that maybe it's not surprising that nothing fitted the bill, so I resigned myself to starting from scratch."
771-2,"passage: This class on its own is not much use, but the beautiful thing about using classes is that they can be extended. I created a second class, SitePage, which extended Page and performed some site specific cusotmisations such as adding the standard site header and menu divs and setting the stylesheet. Further extensions of this class will allow me to create more specialised templates for specific areas of the site. The code I have so far only took a few hours to write and is already proving to be a very productive way of controlling the overall look of the site."
771-3,"passage: My original intentions may have gone up in smoke, but I'm very happy with the code that's been developing. I just hope it stands up to the scrutiny of my fellow coders... if not, it's definitely been a productive learning experience."
771-4,"passage: I said I wasn't going to build a framework, and that really was my intention, but yesterday afternoon I hit on an idea that just got my itching to write some code. The way I see it, the structure of an HTML page is just asking to be represented with a class. All pages have a doctype, a title, a head with a bunch of script / link elements, and a body. Further more, almost all CSS designs depend on a number of div elements one after another in the body. Using these points as guidance, I quickly created a Page class that was capable of gathering this information over time until the display() method prompted it to render itself as HTML, or XHTML if that doctype was specified."
772-0,passage: micro_httpd is a very small Unix-based HTTP server - so small in fact that it is implemented in just 150 lines of C. From the perspective of a relative C newbie the code makes fun reading.
773-0,"passage: l.m.orchard has released the code for his oft-discussed personal web proxy in the form of Agent Frank. It looks really neat, but unfortunately as it's written in Java and I don't have space on my shiny new Linux install to get Java set up I can't play with it yet (looks like I'll have to finally shell out for the new hard drive I've been promising myself). Cute logo though :)"
774-0,"passage: Lots of analysis around the blogosphere today of Google's surprise aquisition of Blogger. Cory Doctorow's analysis is (in my opinion) especially worth reading. Personally, I just hope Google do something about Blogger's revolting archive URLs :)"
775-0,"passage: Eric Meyer's Color Blender is an incredibly useful tool for picking colours for a web site. Give it two different hexadecimal colour codes and it will calculuate and display between 1 and 10 ""midpoint"" colours. It's fun to play with and great for tracking down that elusive perfect shade of green..."
776-0,"passage: Robert Graham's analysis of SQL Slammer cleared up quite a few things I had been wondering about the worm. It confirms that the majority of the infections were caused not by SQL Server (as reported widely by the press) but by the embedded MSDE component, which is far less likely to be patched (or firewalled off from the public internet) than SQL Server."
776-1,"passage: Incidentally, Curious Yellow is a fascinating explanation of a theoretical ""co-ordinated super-worm"" capable of adapting to attempts to combat it using advanced peeer to peer techniques. It is an extension of the Warhol worm concept where a worm that pre-scans the internet for targets could infect all susceptile hots world-wide in less than 30 seconds. Scary stuff."
777-0,"passage: Note to 123-reg: most people only have to mess around with DNS and nameserver settings one or twice a year. If the interface for doing so is anything less than 100% clear they're going to run in to problems. A warning message to the tune of ""make sure you know exactly what you are doing before you touch this"" just doesn't cut it."
777-1,"passage: As the recent lack of updates demonstrates, I've been getting stuck in to a pretty time consuming new project. It should have launched several days ago but I made a right royal hash of the DNS settings - hopefully everything will be working fine in about 24 hours time."
778-0,"passage: Douglas Bowman has been having some amusing problems with robots and his calendar. The calendar, visible on every page of the site, automatically adds a ""next month"" and ""previous month"" link to allow surfers to browser through the archive in both directions. Unfortunately, Doug ommitted the logic to stop showing a ""previous month"" link when there were no earlier entries. An enterprising crawler started following the links, and didn't stop until it had reached 1542!"
778-1,passage: I've written a few dynamic calendars in the past and I'm pretty sure at least one of them was susceptible to this kind of bug. Definitely one to watch out for.
779-0,"passage: Via Scott, this oh-so-true quote from a Microsoft ""next-generation technology"" consultant:"
779-1,passage: It's not like the alternative options are even particularly arduous to install. Opera 7 for Windows weighs in at a paltry 3.2 MB without Java support and Phoenix (my browser of choice) is only 6.2 MB. Both install without making any unpleasant changes to your system and are easy to remove if you decide you don't like them. If you do a lot of web development Mozilla offers a superb range of web development related tools for only a 11 MB of your valuable download time.
779-2,"passage: I've been telling my friend's something similar for a while. Internet Explorer 6 is now over a year and a half old, and in my opinion just doesn't cut it as a serious browsing platform any more. It's fine for casual use, but if like me you spend well over an hour every day surfing the web you would almost certainly be better off with something more capable. Pop-up blocking, tabbed browsing and fixed-sized-font resizing all go a long way towards making the web a more pleasant and productive place - not to mention the fact that most really lame advertising techniques use MS proprietary DHTML and fail to work at all in other browsers."
779-3,"passage:
Internet Explorer hasn't had any revolutionary features for over 3 versions now. And it's now surprise why. No outside push. Not to say Internet Explorer is bad. But I use it more because it's always there not because it's necessarily better than other alternatives that I would have to download and install.
"
779-4,passage: Further reading:
779-5,"passage: The only reason I can see to stick with IE is if you frequently work with a web-based application that requires proprietary IE extensions (such as the ever problematic contentEditable), and of course for testing sites to ensure they stay compatible with the web's most wide-spread browser. For every day web browsing you can be a lot more productive with something else."
780-0,passage: She even got a link from The Register for her troubles.
780-1,passage: Here's a good reminder why you should always encode < and > as HTML entities when displaying content from an untrusted (i.e external) source: Kasia in a nutshell was hit by a false referrer containing javascript deliberately aimed at hijacking the page the referrer was displayed on:
781-0,"passage: Intelligent Enterprise: For all of you unfamiliar with Python, get ready for the ""next big thing."""
782-0,"passage: Python and Jelly: Scripting Power for Java and XML incorporates an excellent introduction to Python and Jython for Java programmers, with a whole bunch of comparative code samples and comprehensive coverage of differences between the two languages."
783-0,"passage: I'm probably the last person on earth to cotton on to this, but it's so neat I just had to share."
783-1,"passage: I've been having fun with SSH lately. Did you know you can set up SSH so you can log in to servers without having to provide a password? It's called ""public key authentication"" and is apparently more secure than using a normal password. You generate a public/private key using a program called ssh-keygen, and store a copy of the public key on the server(s) you wish to authenticate with. When you attempt to log in, the server sends you a message encrypted with your public key - your machine decrypts it and sends back the original message, proving your identity."
783-2,"passage: I learnt how to set it up from this PDF file (well, actually the Google HTML conversion). PuTTY on Windows has the same capability but needs to be set up in a very different way - information on that can be found in the excellent PuTTY documentation."
784-0,passage: Al Sparber makes perfect sense in article from June last year:
784-1,passage: Al has just started a very promising tutorial series on CSS Layouts: Woven with CSS: Quick Draw MacFly.
784-2,"passage: Web design is like medicine. Successful doctors are the ones who keep up with the latest techniques. You wouldn't want to go to a doctor who doesn't know the latest imaging and non-invasive surgical methods. I wouldn't hire a web designer who couldn't wax poetic about CSS, W3C Standards, Accessibility, and Usability."
784-3,"passage: There's nothing inherently wrong with using tables to layout a web page. They are great for rapidly deployment sites for clients who need to support a wide range of older browsers, or in any site that needs to display organized tabular data. Tables are not evil. But in terms of web page design, nothing is absolute. The target is constantly moving... but not in circles. To only use tables is as wrong a decision as to never use tables. Not to embrace CSS, could be tantamount to a slow professional suicide."
785-0,passage: The code for the main class is available here: SafeHtmlChecker.class.php
785-1,"passage: The system I have implemented works by running submitted posts through an XML parser, which checks that each element is in my list of allowed elements, is nested correctly (you can't put a blockquote inside a p for example) and doesn't have any illegal attributes. My initial test have shown it to work pretty well, but if anyone wants to have a go at breaking it please, be my guest."
785-2,"passage: I've finally enabled a subset of HTML in my comments. In doing so, I had several requirements that needed to be fulfilled:"
786-0,"passage: Matthew Thomas offers a fascinating example of usability gone horribly wrong (the explanation is provided here). Incidentally, while showing the above to my girlfriend she uncovered an interesting usability issue on Matthew's site itself - ""is this a collaborative weblog then?"" she asked, having spotted the Posted by mpt on 2/24/03; 3:51:24 AM text below the entry. Clicking on the name link provided no extra information, bringing up a screen with no useful content at all. I imagine this is an issue with the CMS powering the blog, but it does neatly demonstrate how some CMS features can detract from the unserstandibility of a site."
787-0,"passage: Of course, this issue is true of table layouts as well. Who knows, maybe in about 5 years time the browsers will have caught up with the current set of standards (and we'll all be stressing over how much of CSS3 we can use without the house of cards tumbling back down again)."
787-1,passage: Leonard Lin on The Folly of Depending on CSS Parsing Bugs:
787-2,"passage: I would not compensate for CSS rendering bugs by exploiting CSS parsing bugs except as a last resort. Think about it from a standardized test perspective: what strong relation does CSS rendering bugs have with CSS parsing bugs? There's no reason (nor right!) to assume that all future browsers with the same rendering bugs will have the same parsing bugs (and vice versa). In fact, if you look at the recent past releases (Safari, Opera, IE), even within browser families you'll see that this is absolutely not true!"
787-3,"passage: He has an interesting point - user agent sniffing, while derided by many, is at least predictable in that you can deliberately target specific versions of specific browsers (as long as you're careful not to feed a user-agent cloaked Opera something nasty by mistake). CSS hacks may target browsers based purely on their capabilities (which cannot be cloaked by a false user agent string) but require careful maintenance against future version changes - as with Safari which has fixed some CSS parsing errors that were being used to filter Safari specific styles."
787-4,"passage: I suppose it boils down to the question of which is easier to maintain - a site-wide stylesheet (or two) with hacks in vs a server side (I'll ignore client side as it's even uglier) browser detection routine to serve up the right stylesheet. Either way, if you don't have a full set of browsers and platforms to test on the best you can do is cross your fingers and pray nothing breaks."
788-0,"passage: Pingback client implementations would say similar to the way they work now, except instead of having to retrieve the target page, check for Pingback server information and send an XML-RPC ping they would just have to send a single request with the specified referral and user agent information. Implementation is thus simpler for both client and server sides of the system, while keeping the required functionality."
788-1,"passage: Pingback solves these problems through ""alert me if you link to me information"" embedded in the HTTP headers / embedded metadata of a page, combined with a simple XML-RPC server for accepting alerts. While this solves the problems outlined above, the overhead of carrying out a Pingback is quite large and the implementation of the client / server is quite challenging. The system is also of no use at all unless both parties have Pingback installed."
788-2,"passage: Here is some outline PHP code for spotting and responding to my proposed ""pingback-probe"" requests:"
788-3,"passage: My solution is an extension of my own Pingback implementation. Whenever I link to a site from my blog, a script running on my server requests each of the pages I have linked to and checks for information on a related Pingback server (this is standard behaviour for any conformant Pingback client). As a nod towards those users who do not have Pingback enabled, the script sends the permalink of the linking item as the Referer header, to ensure that their logs have at least one hit from the entry in question. It dawned upon me that if this single ""hit"" was identifiable as a Pingback probe the process could stop there - the target server would have the required information that ""Page X linked to Page Y at Time T"" and would be able to process the Pingback straight away. How to identify the hit? Two methods come to mind - the request could include an additional header (X-Pingback-Probe: yes) or the User-Agent string could include some standard string. Since some scripting languages (such as PHP) do not provide access to non-standard headers in the HTTP request, the second option seems immediately favourable."
788-4,"passage: There are three principle reasons for using Pingback to ""detect"" a link to a page rather than relying on referrals:"
788-5,"passage: I think I've worked out a way of implementing Pingback (or a Pingback-like system) without any need for XML-RPC, <link> elements or custom HTTP headers."
789-0,"passage: Dan Loda: Doing forms justice. A demonstration of how labels, accesskeys, fieldsets and CSS can make a form that's usable, accessible and looks great. He even uses an optgroup in a select box, an element I've never seen demonstrated before."
790-0,passage: A great preview describing the features we have to look forward to in PHP 5. Proper object reference handling is going to be sweet.
791-0,"passage: I had my first ever Quasar (otherwise known as laser tag) experience last night with the Bath University Computer Science Society (BCSS). Due to various misunderstandings our booking failed to materialise, but Quasar were very nice and said we could play against another group at 7.30pm. They failed to mention that the other group had an average age of about 9. Suffice to say it was an entertaining match, which we won by a very small margin (little kids spend all day running about; lazy students don't)."
791-1,"passage: Despite the interface nightmare, it was great fun. We beat our half-sized oponents by an embaressingly small margin, and stumbled out after 20 minutes looking and feeling like we'd just been through a two hour intensive session in the gym. Hopefully next time we'll be up against a team with a bit less of a height advantage :)"
791-2,"passage: The other features of the gun, such as the ""special weapon"" switch on the front (which appeared to change the noise the gun made) and the powerups hidden around the map were completely lost on me as I spent most of my time desperately trying to figure out if I was dead or not."
791-3,"passage: Although it was good fun, the first ten minutes of the match were marred by our complete confusion as to what we were meant to do and how we could do it. ""Shoot people on the other team and try to shoot their command centre"" is a clear enough objective, but the overall user experience left a lot to be desired. Seeing as 10% of the male population are red-green colour blind, red and green are questionable choices for team colours (one friend with this problem could only really tell the difference thanks to the enemy team being about half our height). The interface on the guns was very poor as well - important messages were conveyed by an electronic voice, which was practically inaudible in the loud environment of the game area, and the display on the back proved extremely confusing. The guns have a small digital readout which displays your number of lives and remaining ammo. When you are hit (making your gun inactive for 2-3 seconds) the display changes to a rapidly reducing counter to show that you are unable to shoot. Of course, this also means that while you are recovering you can't tell how many lives you have left making it impossible to judge whether or not you should head back to base for a recharge."
792-0,"passage: When Safari came out, who had the best coverage? Look no further than Mark Pilgrim. The Eldred case was graced with coverage by Lawrence Lessig, the man at the very centre of the story. I'm sure there are plenty of other examples."
792-1,"passage: So, for a lot of tech related news I find blogs a far more useful source of information than the mainstream press. The problem of course is one of reputation - before I can judge the value of a blog entry I need to know something about the blogger who wrote it. Part of this judgement is helped by links from bloggers who I already trust (the linking nature of the web at work). Unlike Tantek I still have a use for traditional media for my non-tech news, but as the blogosphere expands and new methods evolve for finding quality blogs on a variety of subject matter I can see my dependence on the media reducing even more."
792-2,"passage: I've been pretty much ignoring the whole ""Blogging vs Journalism"" thing but recently I've begun to understand what the big fuss is about. One of the most popular arguments put forth by journalists concerned by competition from blogs is that the information contained therein isn't as reliable thanks to a lack of an editor to check facts. Rubbish. I can't remember the last time I read a technology article in the main stream press about something I have more than a passing interest in that didn't have at least a few errors. Some of the blogs I read on the other hand are written by subject matter experts - these people are not being paid to knock out 750 vaguely relevant words on a breaking story, they are voluntarily providing their insights because they are heavily involved with the topic at hand."
793-0,"passage:
But the more I think about it, the more it resonates with what I have read in books like 'Hard Drive' about Microsoft's ethos being one of 'Win at all costs, and they are all out to get us'. It seems the automatic assumption of some of the other speakers was that I was in some way 'out to get' Microsoft, that my agenda was attack, so despite that being absent from my intent it was read in as a sub-text to what I said. Considering that the people involved represent the attitudes of the largest, most aggressive company in my industry, immune from almost every attack and even able to shrug off conviction under the Sherman Act like a speeding ticket from a small-town cop, they showed a vulnerablity and insecurity which speaks volumes of the way Microsoft likes its people to feel and act. I stand educated.
"
793-1,"passage: Simon Phipp is Chief Technology Evangelist at Sun, and recently participated as a speaker on the "".NET Nirvana"" Geek Cruise. His blog entries covering the event make interesting reading. To cut a long story short, after a couple of presentations on Java web services and open source coftware the Microsoft contingent at the event requested that he be barred from attending an evening Q & A. Simon makes the following observation:"
794-0,"passage: To search our collection, we project a query into this term space and calculate the distance from the query vector to all the document vectors in turn. Those documents that are within a certain threshold distance get added to our result set. If all this sounds like gobbledygook to you, then don't worry - it will become clearer when we write the code."
794-1,"passage: Having done a course on Linear Algebra last term, it's interesting to see how it can be applied to the search problem. The technique described lends itself well to finding ""similar documents"" as well, as documents with similar word content will end up ""near"" to each other when projected on to the vector space."
794-2,"passage: The article is also yet another demonstration of how Perl's modules make it such a powerful tool. Lingua::Stem is used to find word ""stems"", providing a free algorithm for eliminating related words like cat and cats. The performance overhead of using Perl arrays to represent large vectors is avoided with the PDL module, which implements a whole set of matrix algebra functions in compiled C for high performance. Without these two modules the technique described would be a great deal less powerful. Of course, neither of them are available for PHP or Python, my scripting languages of choice."
794-3,passage: Building a Vector Space Search Engine in Perl:
794-4,"passage: Vector-space search engines use the notion of a term space, where each document is represented as a vector in a high-dimensional space. There are as many dimensions as there are unique words in the entire collection. Because a document's position in the term space is determined by the words it contains, documents with many words in common end up close together, while documents with few shared words end up far apart."
795-0,"passage: An interview with Cory Doctorow, via Leonard. Provides some great background insight in to the world described in Down and Out, along with Cory's thoughts on such topics as the recording industry and the Disney corporation."
796-0,passage: Sigh. I guess I'll stick with the console version.
797-0,"passage:
From Google the news was mixed. He said he wouldn’t start indexing .0 URIs, which includes the URIs for all our licenses. He also said that he wouldn’t parse RDF for at least six months, since it required involved changes to their system and added overhead (which you need to keep down when parsing 3B pages). However, he did say that if we added <meta> tags for license information, they’d add a new search key like link: or inurl: right away, since they already had a meta tag parser.
"
797-1,passage: Did they say anything about using the link element instead?
797-2,passage: Aaron Swartz has been talking to Google about indexing Creative Commons licensed works:
798-0,"passage: Gordon Weakliem reminds us that the most important RSS element is <title>. I'm painfully reminded of this each and every time I add a new entry - I have well over 800 entries now, and I've promised myself that next time I perform a major upgrade on this blog I'm going to go through and manually add titles to every single one. The task should be made slightly easier by the camelCase permalinks, which I can convert in to ""suggested"" titles to help the task along. It's still not going to be much fun though."
799-0,"passage: The reaction on the forums has been mixed, with a lot of people declaring their preference for the old design. Personally I think it's great to see such a useful web master resource embracing the next generation of standards compliant web design."
799-1,"passage: I don't know how I missed it, but SitePoint have redesigned in funky valid structural XHTML and CSS. I quite like the new look (not so keen on the new logo though) and the navigation is definitely a huge improvement - instead of the previous confusing arangement of several ""sister"" sites they now divide content in to ""Articles"" and ""Forums"", which makes a lot more sense. They have some clever DHTML enhancements as well, such as a collapsible left hand navigation panel. The right hand navigation that scrolls up and down (jerkily) with the window is quite distracting unfortunately. "
800-0,passage: Matthew Haughey (freshly redesigned) has published a Mozilla advocacy article explaining why Mozilla (and variants) are excellent tools for bloggers. Spot on.
801-0,passage: Here's the reason I've been blogging at a relatively low frequency lately: BCSS - the Bath University Computer Science Society. The site is still under heavy development (there's a surprise) but there's enough information there now for it to be worth linking to. At the moment the site is valid HTML 4.01 Strict but it works as XHTML as well (try appending ?xhtml=1 to the URL of any page on the site) thanks to an ultra flexible page template class (outlined here) and a few simple tricks to convert XHTML in to HTML beforethe page is displayed.
801-1,"passage: That's the long term plan at any rate. For the moment, we're just trying to get established, sign up some members and get some experience at running things. Our first undertaking is a introductory C++ course run by Tristan Caulfield, which got off to a good start on Monday and will be followed by a course on graphics programming with Direct 3D. We're also on the look out for a relatively high profile open source developer in the Bath/Bristol area willing to come in and give a presentation on the Open Source development model (it's scary the number of people on our course with little or no understanding of the Open Source ethic). Any suggestions for a candidate would be more than welcome :)"
801-2,"passage: Enough web geekery, I should probably explain a few things about the society itself. We initally formed a few weeks before Christmas, but due to coursework deadlines, the Christmas break, exam revision and exams were unable to sort much out until about a month ago. Our aim is to ""fill the gaps"" in the Computer Science degree courses provided by the University of Bath. While the official courses provide an excellent theoretical background for CS students, no University course could possibly hope to keep up with the lastest developments in our fast moving industry. We plan to provide student-run activities that complement the course, such as seminars on topics like XML, Web Services, J2EE and .NET, training courses in different programming languages and talks from invited speakers on hot topics in Computer Science."
802-0,"passage: Craig Saila has a minor rant about HTTP error codes. Did you know that a 410 should be served instead of a 404 when a resource has been deliberately, permanently removed? I didn't."
803-0,passage: Jeremy Zawodny drops a so-subtle-that-I-probably-misread-it hint that the Yahoo search page might some day follow AllTheWeb in Google's footsteps.
804-0,"passage: Of course, the golden rule for this kind of thing is to build for your audience. If your stats show a significant Netscape 4 population (which is thankfully getting less and less likely) you're going to have to break out the tables."
804-1,"passage: Incidentally, James is currently working on a redesign. It's looking really nice, but my one suggestion would be for him to include his surname somewhere on the site! It took me a good five minutes to track that piece of information down for this entry, and I only ended up finding it thanks's to my own blog's comment archives."
804-2,passage: James Buckley links to a new report on How people evaluate a web site's credibility. His comments:
804-3,"passage:
Take a look and the first thing you'll notice is that Design was king of the hill with 46.1%, I think its a common misconception with some hardcore usability people that if a site is usable it doesn't matter how it looks, or it's a significantly lower priority, I hope they keep results like this in mind.
"
804-4,"passage: What interested me about this concept is the angle it brings to the CSS layouts and Netscape 4 debate. A lot of CSS advocates (myself included) recomend ""hiding"" advanced stylesheets from Netscape 4, leaving it to render structural markup using its default styles or a ultra-basic stylesheet provided by the site. The site remains fully usable, all of the content is accessible, but you can garauntee that the site's credibility in the eyes of a potential customer is going to take a serious knock. If you're using leading edge, backwards compatible, structural and standards compliant markup with CSS while your competitors are using 3 year old table hacks and hundreds of font tags, Netscape 4 users will see theirs as a professional, credible site and yours as so much unimpressive looking text."
805-0,passage: Scott Andrew has been hit by redesign fever as well. His reworking is accompanied by a change in direction:
805-1,"passage:
For a lot of the past two years, I've been grappling with this dual existence of mine, and I've finally reached a point where, if I were to be run over by a freight train tomorrow, I'd rather be remembered as that songwriter guy than that JavaScript guy.
"
805-2,"passage: I'm not much of a folk/country fan, but I have to admit I rather like his brand of urban acoustic pop and weirdo country music. His blog seemed to lose the web focus a few months ago so it's nice to see him ""come out"" and show where he's going with his site. Incidentally, the redesign looks great and is especially notable for its warm colour scheme and non-white background. My girlfriend is mildly dyslexic and finds it hard to read text on white, which has raised my awareness that white is not necessarily the best choice for a background colour (the BCSS site uses a light blue for this very reason). "
806-0,"passage: Linked to from Sam's comments are Mark Pilgrim's thoughts on OPML from April last year. I'm not too keen on OPML's ""invent attributes as you need them"" attitude but I am intrigued by Dave Winer's thoughts on using OPML as the basis for a massive, distributed directory of the web - a sort of decentralised dmoz."
806-1,passage: Sam Ruby's ultra-simple 3-paned aggregator is a great example of the power of high level scripting languages. Using the wxPython cross-platform GUI toolkit and Mark Pilgrim's ultra-liberal RSS Parser it provides a full application in a mere 107 lines of (highly readable and maintainable) code.
807-0,passage: Wow. Jeff Minter has a blog.
808-0,"passage: It would be fun to integrate something like this with a rich text editor, such as the recently announced htmlArea 3.0 that works with Mozilla 1.3b as well as IE (more information here)."
808-1,passage: Sam Ruby has enabled spell checking for the preview comment tool on his blog. I wonder how it works... I've lost track of the scripting language Sam uses for Intertwingly (PHP? Python? Perl?) but I know PHP can be compiled with support for the Pspell module.
808-2,"passage: Sam's user interface is pretty neat - misspelled words are marked up with a span, underlined in dashed red and have suggested spellings listed in the span's title attribute. Theoretically, it should be possible to build a javascript right-click menu offering alternatives instead (preferably dynamically generated from the list of words in the title attribute using the DOM). Actually modifying the preview textarea text based on the menu selection would be quite a lot harder - it could be done with a simple search-and-replace operation, but doing so might change other words with the same ""incorrect"" spelling without the user realising."
809-0,"passage: The WThRemix contest has posted a list of submitted entries. The contest (to design a new homepage for the W3C) asked entrants to use valid tableless XHTML, CSS and meet WAI accessibility level 1. The entries demonstrate a wide variety of layout and design techniques and are well worth browsing through. The winners will be announced on March 17th."
810-0,"passage: Scott Johnson has put together a blog search engine with a difference: it indexes RSS feeds rather than crawling the blogs themselves. Roogle is still under heavy development (and Scott is blogging it as he goes) but is shaping up to be a very neat tool. If your blog isn't already being indexed, you can add it using this form."
811-0,"passage:
HTTP/1.1 200 OK
Server: Microsoft-IIS/5.0
Date: Sun, 09 Mar 2003 14:38:50 GMT
Connection: Keep-Alive
Content-Length: 6629
Content-Type: text/html
Set-Cookie: CTST=yes; expires=Sun, 09-Mar-2003 15:03:50 GMT; path=/
Cache-control: private
"
811-1,"passage: I'm finding myself slightly confused about the Google backlash washing around the blogosphere, which is summarised quite well by Gavin Sheridan. Most of the arguments against using Google unsurprisingly centre around privacy issues, in particular the ""35 year cookie"". I was under the impression that cookies could only be set for a maximum of a year, but having checked Netscape's Cookie Specification and RFC 2965 it appears I was mistaken."
811-2,"passage: So let's take a look at the cookies in question, via the Mozilla project's handy Web Sniffer utility (the front page for this tool is here):"
811-3,"passage:
HTTP/1.0 200 OK
Content-Length: 3403
Connection: Keep-Alive
Server: GWS/2.0
Date: Sun, 09 Mar 2003 14:34:32 GMT
Content-Type: text/html
Cache-control: private
Set-Cookie: PREF=ID=05ba0c124de8df6e:TM=1047220472:LM=1047220472:S=Ke2RQCqjCEowS1x-; expires=Sun, 17-Jan-2038 19:14:07 GMT; path=/; domain=.google.com
"
811-4,passage: There it is - a 35 year cookie. Now let's take a look at some of Google's competitors.
811-5,passage: AllTheWeb:
811-6,"passage:
HTTP/1.1 200 OK
Date: Sun, 09 Mar 2003 14:36:42 GMT
Server: Apache/1.3.27 (Unix) PHP/4.2.3-atw
Set-Cookie: atw-uid=CgVSBj5rUXoAAQnFAwSFAg==; path=/; domain=.alltheweb.com; expires=Sat, 09-Mar-13 02:36:42 GMT
X-Powered-By: PHP/4.2.3-atw
Last-Modified: Sun, 09 Mar 2003 14:35:00 GMT
Expires: Thu, 19 Apr 2001 04:25:21 GMT
Cache-Control: max-age=0, private
Set-Cookie: PREF=frschk=1:_lm=1047220602; expires=Fri, 07-Mar-08 14:36:42 GMT; path=/
Connection: close
Content-Type: text/html; charset=iso-8859-1
"
811-7,passage: That's two cookies - one for 5 years and one for 10 years. Interesting to see that they're using their own modified version of PHP 4.2.3 :)
811-8,passage: Teoma:
811-9,passage: That cookie lasts for about half an hour and doesn't contain a unique identifier. Plus they're running IIS!
811-10,passage: Altavista:
811-11,"passage:
HTTP/1.0 200 OK
Set-Cookie: AV_POS=pos=1047220999574; path=/; domain=.altavista.com;
Set-Cookie: AV_USERKEY=AVS03b87123ae55d80a1c21250000022; expires=Tuesday, 31-Dec-2013 12:00:00 GMT; path=/; domain=altavista.com;
Server: AV/1.0.1
MIME-Version: 1.0
Cache-Control: no-cache,no-store,max-age=0
pragma: no-cache
Expires: Sun, 09 Mar 2003 14:43:19 GMT
Set-Cookie: AV_MKT=1; Domain=altavista.com; Path=/; Expires=Thu, 01-Dec-1994 16:00:00 GMT
Content-Type: text/html; charset=ISO-8859-1
Content-Length: 10020
Date: Sun, 09 Mar 2003 14:43:19 GMT
"
811-12,"passage: What a mess! There's a session cookie (which only lasts until the browser s closed) recording what looks like the time I first visited the front page, a 10 year cookie with a unique ID and another cookie set to expire in 1994, possibly in an attempt to wipe out cookies set by an older version of the site."
811-13,"passage: So what have we learnt? Both AllTheWeb and Altavista set 10 year unique identifier cookies, while Teoma appears not to set any. At the end of the day though, what is the difference between a 10 year and a 35 year cookie? How many people are going to go a whole ten years without losing their browser's cookies, through a browser upgrade, PC upgrade, change of job or just wiping the cookie directory? Thee answer to that question is self evident, so in practise a 10 year unique identifier cookie is just as big an invasion of privacy as a 35 year cookie."
811-14,"passage: On the privacy front, AllTheWeb and Altavista are just as guilty as Google."
812-0,passage: It doesn't have to be weblogs.com - a ping to blo.gs would be just as effective.
812-1,"passage: Without pings, they languish at the bottom of my blogroll where I won't notice or visit them. My blogroll is my only mechanism for keeping track of the blogs that I read regularly - aggregators just don't do it for me, and with tabbed browsing my blogroll is almost as efficient for staying up to date."
812-2,passage: Blogs I would read a lot more often if only they pinged weblogs.com when they updated:
813-0,"passage: Douglas Bowman writes about Guiltless Image Use, describing a technique that uses CSS to cause text to vanish from the page, then replaces it with a background-image. I experimented with this technique (see comments attached to that entry) myself last year but ended up using image tags inside h1 elements instead. Doug's drop cap example shows that the technique can be applied in interesting ways outside of headers."
814-0,"passage: Adrian Holovaty's open email to Staci D. Kramer of Online Journalism Review makes an excellent case for the adoption of web standards by online news sites. It's written in nice, clear non technical terms and does a good job of explaining the web standards movement in a short space of time. Could definitely be useful for forwarding on to non-technical people (managers for example?) to help spread the word."
815-0,"passage: Scott Johnson's Roogle RSS search engine got slashdotted yesterday, and survived the storm unharmed thanks to Scott's quick thinking server admin Demitrious setting up mod_throttle to help handle the load. Demitrious describes the solution in this post."
816-0,passage: I really like the approach of relying on the filesystem to do as much of the work as possible. I suppose most web developers who start with PHP (myself included) get stuck in to mySQL databases straight away and never realise quite how much you can do with a bunch of simple text files.
816-1,"passage: I've been hearing a few good things about Blosxom recently, so a few days ago I decided to see what all the fuss was about. It's a blogging tool, but it's a very different species from the average system. Firstly, it's only 282 lines of Perl (of which only 135 are actual code). Secondly, rather than having a web interface of some sort to add entries it runs entirely from the file system. You specify a data directory, then create entries by dropping .txt files in to that directory using your favourite text editor. The first line of each file is the title, the rest of the file is the entry, and the entry's date is taken from the last-modified time of the file."
816-2,"passage: So far, so straight forward. Where it gets really clever is the template and category systems. To customise your basic blog you drop a head.html and foot.html file in to your data directory. To customise the display of entries, drop in a story.html file with a few simple replacement variables in it. Categories are again handled by the filesystem - you create directories (or nested subdirectories) for the categories you want and simply drop entries in to those directories instead of the top one."
816-3,"passage: I doubt I'll switch over to using Blosxom myself, but the cleanness of its design combined with the ease with which it can be extended (Blosxom 2.0 has a very promising plugin architecture) make it an excellent choice for aspiring geek-bloggers. If I'd known about it before I started this blog I may well have used it (or a variant) instead of rolling my own. l.m.orchard is building Decafbad 2.0 around it and has already done some pretty exciting things."
816-4,"passage: Blosxom supports RSS straight out of the box, and can support any custom format you could possibly want thanks to its support for ""flavours"" - explained on the site. Pretty good for 150 lines of code!"
817-0,"passage: That said, the lack of a security model (databases are stored in a single file with no user authentication / permissions system) and the fact that it's very much meant for embedding rather than featuring a client-server model mean it isn't really suitable for web applications. Where it would shine (and where the author intended it to be used) is in applications that would benefit from an ultra fast relational database but don't need the overhead of embedding a large system such as mySQL. The no-strings license makes it a tempting prospect for that kind of work as well."
817-1,"passage: The other toy I've been playing with recently is SQLite. SQLite is an embeddable SQL database engine written in just under 25,000 lines of (heavily commented) C. Don't let the size fool you - it's phenomenally powerful and is released under a no-holds-barred public domain license that practically begs you to include it in your applications, commercial or not."
817-2,passage: Definitely one for the tool box.
817-3,"passage: The feature list is pretty awesome - it's two times faster than both mySQL and Postgres on simple operations, implements an impressive amount of the SQL92 standard (including transaction support) and has bindings for Tcl, PHP, Perl, Python and Java."
818-0,passage: Update: I obviously wasn't paying attention: RFC 0023: Short URL Support
818-1,"passage: [PHP|Post|myPHP]-Nuke has to be one of the most-forked open source projects in history! Xaraya appears to be a fork from Post-Nuke, which itself forked from PHP-Nuke several years ago (and I'm pretty sure there are more). They've got an interesting set of RFCs on how they intend to build the next big open source content / community management system (nothing about generating pretty URLs yet). While browsing their site I found a link to PHPXref, a powerful looking tool for generating PHP source code documentation. Unsurprisingly for such a lot of text munging, it's written in Perl ;)"
819-0,passage: I think that was my first ever micropayment.
819-1,"passage: Fredrik Lundh has started posting his book The Standard Python Library online, in response to O'Reilly's decision not to publish a second edition of the book. I'd never read it before, but having sampled the first two chapters I'm hooked. It works a bit like a ""cookbook"", with a plethora of code samples explained in detail accompanied by tips and tricks relating to the language. The Lazy Import class, which loads a module only when an attribute of the module is called for the first time, is a classic example:"
819-2,"passage: Frederick plans to release a chapter every Friday until the whole book has been posted. Alernatively, you can buy the whole 1999 edition from him as a PDF file for the princely sum of $5.00, which works out at £3.18 in GBP via PayPal."
820-0,"passage: It looks like there's a shakedown going on in technical book publishing land. Glasshaus are no more, and (so far unsubstantiated) rumours are flying round that Wrox are going bust / have gone bust as well."
820-1,"passage: Incidentally, a search for wrox on Scott Johnson's Feedster is currently a great way of seeing what people are saying. It's a shame Feedster doesn't support some kind of permalink-to-these-search-results feature for letting bloggers link to the search results as a useful overview of the blogosphere's opinion on something on a specific date."
820-2,"passage: I wonder what happens to the copyright of a book once the publisher goes under? Does it end up in some kind of limbo, eternally awaiting the day when someone ""buys"" it from the liquidator or does ownership revert back to the author? If the latter is true, we may see other authors following the lead of Frederick Lundh in publishing their work online and/or charging a small fee for a downloadable version."
820-3,"passage: I've got a few Wrox books lying around but I have to admit I never liked them nearly as much as my O'Reilly collection (although Beginning Java 2 is still the book I recommend to anyone who wants to learn that language). I've heard they are very good for ASP and .NET related content though. If Wrox really have gone under it will have a pretty dramatic impact on the amount and variety of my local tech bookshops (not too mention a lot less red). My only experience with glasshaus has been their Cascading Style Sheets book, which is absolutely excellent. In fact, if you have any interest in CSS and haven't picked up a copy yet I suggest doing so now before it becomes too rare a commodity. I've got my eye on a few other glasshaus titles though - their policy of covering ""leading edge"" web techniques (Accessibility, Usability, CSS, Web Database design) made them an interesting small scale publisher - plus they also seemed to hire a lot of their authors from mailing lists I occasionally frequent such as Evolt and Webdesign-L."
821-0,passage: This post exists mainly to clear out interesting tabs.
821-1,passage: I really need to get myself a linkroll.
821-2,"passage: I've inadvertantly discovered a flaw in the tabbed browsing model - if you're not disciplined about them you can quickly end up lost in a see of tabs. Right now I have 6 Phoenix windows open with a total of 57 tabs between them. This is the result of about a week's accumulated browsing, leaving me unable to even think about shutting down or rebooting my computer without clearing them all out first. The fact that Mandrake is churning along happily without any noticable slowdown (despite me having several other applications running as well) doesn't help at all as it gives me even less impetus to tidy everything up."
822-0,"passage: Okay, now I have absolutely no intention of taking this blog in a political direction (for the record I'm anti-war) but I've seen a couple of links to the Onion recently that I just can't resist blogging. First up is Bush: ""Our Long National Nightmare of Peace and Propserity is Finally Over"" which was written two years ago but, read now, just looks spookily accurate (link via Back-to-Iraq). The second one is the absolute classic God Angrily Clarifies ""Don't Kill"" Rule, linked by Simon Brunning."
823-0,passage: What Do I Know points to Macromedia's progress report explaining how thy have been responding to feedback on their recent site redesign. Todd Dominey makes the following insightful observation:
823-1,"passage: Perhaps most interesting, to me anyhow, was the crossroad of choosing which tool to use to solve a particular navigational problem, and the internal politics that likely surrounded their decision making. Case in point - the drop down option boxes on their index page. In Beta 1, the forms were created in Flash MX. In Beta 2, they have been completely replaced by tried and true, raw HTML option forms."
823-2,"passage: The Flash versions were styled nicely, with radius corners and a fancy diagonal light bevel, and some pretty nice interactivity. But did they solve any particular problem that a standard html form couldn’t handle? The answer was, and is, no. Sure, they looked nice, and were a good showcase of what you can do with Flash, but were they worth the extra bandwidth, page weight, and development time? Apparently not. They have been completely removed and replaced with much more familiar, lighter, and easier to update standard option boxes."
824-0,"passage: I've tested it on Phoenix and IE5 on Windows - I'll check it on IE6 later on this evening. IE5 gets the menus in the wrong place but other than that it seems to work fine in both browsers. I adapted Sam's Python code for PHP on the server side, while the client side bit is a whole lot of messing around with the DOM."
824-1,"passage: If you want to nose around the source code, take a look at this lot:"
824-2,"passage: There are still a few bugs, and I haven't quite worked out an elegant way to get the menus to behave more like menus, but on the whole it's worked out pretty well."
824-3,"passage: Last week I commented that Sam Ruby's spell checking feature could be made even funkier with the addition of a javascript powered ""corrections"" menu. I spent a few hours this afternoon playing with the idea, and I've now got quite a nice proof of concept:"
824-4,passage: Spell Checker Demo
825-0,"passage: Via Zeldman, Ian Lloyd (who has recently re-launched his personal blog) has released a pair of invaluable bookmarklets for dissecting the structure of properly marked up pages: Show and label divs with ids and Show and label divs with classes. Combine with Liorean's ViewStyles and ViewScripts for best effect."
826-0,"passage: Sterling Hughes (recently blogrolled) has been working on mod_psp, a Python Server Pages module for Apache. He's up to version 0.2.1 already. Stuart once told me that the toughest problem when embedding Python code in HTML is figuring out how to deal with indentation blocks - PSP appears to handle this by letting the indentation ""leak"" in to the HTML, which seems a bit of an ugly workaround. Still, if the module ends up being any where near as straight forward to install and use as PHP it could become a very useful tool."
827-0,passage: As seen on the css-discuss wiki. This method is just wierd
827-1,passage: It's nice to have an old hack recognised :) The css-discuss wiki technique is something I put together last July as an experiment in the most semantic way of marking up code so as to get line numbers - as an ordered list. It's pretty bizzare but it achieves the desired effect. These days my preferred method of marking up code is to use a <code> element nested inside a <pre>.
827-2,"passage: Paul Hammond is seeking the perfect way of marking up code snippets. He examines several methods, including this interesting specimen:"
827-3,"passage:
<ol class=""codeListing""> <li><code>…</code></li> … </ol>"
828-0,"passage: We've been looking at javascript in our ""Concepts of Programming Languages"" course this semester and it's proving a much more interesting language than I had originally thought."
828-1,passage: Andrew Hayward (a friend from Uni who has recently started blogging) has been playing with javascript's prototypes. prototype is a value related to a particular class from which all instances of that class are created - only in javascript classes are actually functions... and then it all gets really complicated.
828-2,"passage: Anyway, Andy's experiments concern using the prototype property to add new methods to javascript's built in classes such as String, Array and even Object. He uses this trick to add useful methods such as String.trim(), Array.implode() and Object.dump(). It looks remarkably useful both for debugging and for making javascript do more stuff in less lines of code by adding additional layers of abstraction to the core language."
829-0,"passage:
One thing that always bothered me about DHTML APIs in particular is that you introduce a whole set of non-standard properties and methods in order to deal with the fact that not all browsers implement the standard properties and methods. You should attempt to preserve a standard as best you can. For instance, in order to get a reference to an element, the standard defines document.getElementById(). For systems that don't support this method, you could create a method of the document object with the name getElementById that mimics the standard behaviour. That way, you aren't married to a non-standard API and won't be screwed when the developer stops supporting it or a new browser introduces something that breaks the API.
"
829-1,passage: Dithered.com's DOM Scripts follow an interesting philosophy:
830-0,"passage: And via Kevin Altis, Paint Shop Pro 8 features Python as an embedded scripting language."
830-1,passage: A bunch of useful Python resources:
831-0,"passage: I ran an intermediate to advanced PHP session at University today, on behalf of BCSS. The turn out wasn't particularly impressive, probably because the only lecture today had been cancelled so there were a lot fewer people from our course on campus than I had expected (the session was arranged because a piece of group coursework we are working on at the moment uses PHP). The notes I put together from the course are available online. They were put together in a bit of a hurry, so please tell me if you spot any mistakes. Topics covered include sessions and cookies, classes and objects, references and some brief notes on writing secure code."
832-0,"passage: Then again, I need to save up £100 for a Glastonbury ticket so it doesn't look like there's a chance of me scraping together the dough for both. Aah well."
832-1,"passage: Like Stuart, I'm severely tempted by the UK Python conference - as a student it would cost me £85 to go for the first day, not including train fairs. That's a lot of money (considering I currently have none) for 4 sessions and the opportunity of a BOF meeting, but it's quite rare for the UK to host a conference on something I'm heavily interested in (I'm yet to go to one). These tips on getting the most out of a conference would certainly come in handy."
833-0,"passage: coWiki is the first open source project I have seen being developed with PHP 5, using snapshots from CVS. It looks like a really neat wiki system. Of particular interest for PHP heads is the development log on the front page (sorry, no permalinks) which provides some insight in to the progress of PHP 5's development."
834-0,"passage: PHP 5 will also feature support for class access control, interfaces and type hinting where a function or method can declare the type it expects for each of its arguments. It's sounding more and more like Java all the time, but seeing as all of the new support for stricter control are optional I don't see this as a disadvantage at all. Coders who want serious OOP can have it, while people knocking out a quick script don't need to worry about them at all."
834-1,"passage: Sterling Hughes has posted the slides he will be using for his presentation on PHP 5 next week. They provide a great deal of insight in to the new additions to look forward to in PHP 5, including a few I hadn't heard about before."
834-2,passage: One of the most instantly useful looking is Class Autoloading. By creating a function called __autoload() you can add logic to automatically include a class the first time it is called. The example code explains this much better:
835-0,"passage: Find: %^([0-9]+^)^(?+^)$ and Replace with: <option value=""^1"">^1^2</option>"
835-1,passage: The task completed by this regular expression is to turn a file containing numbers like this:
835-2,"passage: Every now and then I find myself needing to use a regular expression in UltraEdit, and whenever I do I invariably have to spend five minutes re-reading that section of the manual to remind myself how its syntax differs from more traditional regular expressions. This time, I'm recording the result in the hope that it might jog my memory next time I need to use them."
835-3,passage: In to this:
836-0,"passage: I'm starting to wonder why it's not really implemented in every area, considering the usefulness that this would provide not only to the common web surfing, but also to the corporate world and cutting down on costs for support."
836-1,"passage: Dan Kalowsky is realising the importance of using a smart scripting technique to generate ""nice"" URLs:"
837-0,"passage: Tim Bray provides an in depth, practical explanation of the binary search algorithm with example code in Java. Great revision material for second year computer scientists like myself."
838-0,passage: Wez Furlong is working on a generic PHP installation script. If he finds a nice solution to the safe_mode and open_basedir restrictions mentioned in his post this could be a hugely useful tool for the PHP community.
839-0,"passage: Paul DuBois, the author of the huge great MySQL Book I have sat on my bookshelf, has a whole bunch of useful MySQL articles published on his site."
840-0,passage: More handy javascript from Andy: document.getElementsByClassName.
841-0,passage: Recent additions to the blogroll:
842-0,"passage: It seemed like a good idea at the time but with hindsight, it was a mistake. The first signs of trouble came when I switched the comments system over to displaying comments on a full page rather than using popup windows. I chose to do this both for accessibility reasons and because I just didn't like them. This meant introducing a new ""view"" to my blog which displayed an entry and its associated comments (and pingbacks as well). This worked fine, but the lack of titles on entries meant the resulting page lacked an identifier at the top. It also meant that there were two potential permalinks for every piece of content - the ""official"" permalink in the context of the day the entry was posted and the permalink to the entry and its comments on a separate page."
842-1,"passage: That much I could live with, although as time went by the lack of entry titles became a constant thorn (I've had several complaints that the lack of titles in my RSS feed makes it useless in some aggregators). The real problems emerged over the past few days, when I decided to implement a referral tracking system."
842-2,"passage: My plan was to log the HTTP_REFERER request variable of any visit to an archive page on the site, then display them in the relevant place (like Mark Pilgrim used to do but without the automated validation and extract generation system). Logging referrals was easy enough, but when I tried to display them I ran in to problems. The permalinks on this site are actually a link to a specific day plus a fragment ID to identify the individual entry. Unfortunately, the browser only requests the ""real"" part of the URL before using the fragment ID to jump the browser screen to a specific point. The fragment ID is not included in the request, so as far as my server is controlled the request was for the whole day page."
842-3,"passage: My solution is highly inelegant and features some of the hackiest PHP I've written in a long time. Instead of displaying referrals on the page they link to, I've put together a last 50 referrals script which displays the last 50 inbound links along with a list of shortened entries (if the link was to a day page) or the first 120 characters of an entry (if the link was to an actual entry page). It works, and it means I can get a much better idea of who is linking to me, but the code leaves a pretty bitter taste in my mouth."
842-4,passage: Hopefully I'll get a chance to do some pretty major rearchitecting of this blog over the Easter break. I want to move to an entry-centric design where the date of an entry is less prominent and the entry title is on prominent display. Permalinks will go to entry pages (although I will make sure older links continue to work) and I may even finally implement the search engine I've been promising myself for so long (the lack of titles on entries is one of the main things putting me off writing one).
842-5,"passage: When I started this blog, I made the decision to use days rather than entries as the principle navigation unit of the site. Each day's entries are grouped under a single heading for that day, archives are arranged by day (with permalinks linking to anchors on those pages) and individual entries come without titles, to emphasise the fact that they are part of a larger whole."
843-0,passage: So far I've only tested it on Phoenix but it seems to work as intended for the small number of test cases I've tried. If you spot any bugs please let me know. I'm about to fire up a Windows PC and see how much it breaks in IE...
843-1,"passage: Inspired by Andy, I decided to have a crack at something I've been thinking about trying for a long time. document.getElementsBySelector is a javascript function which takes a standard CSS style selector and returns an array of elements objects from the document that match that selector. For example:"
843-2,passage: This will return an array containing all of the links that have 'external' in their class attribute and are contained inside a paragraph which is itself contained inside a div with its id attribute set to 'main'.
843-3,passage: Update: I've put together a demo page showing the function in action. It works fine in IE 6.
844-0,"passage: First observation of the day: IE 5 for Windows doesn't understand element.getElementsByTagName('*') to retrieve all descendants of an element in the DOM. element.all has the desired effect for that browser. So to retrieve all descendants in a way that will work on standards compliant browsers plus IE 5, the following seems to be the best bet:"
845-0,"passage: It has been pointed out that the function does not have the capability to deal with chained selectors such as div#main.layoutDiv. I have no intention of supporting this kind of advanced CSS syntax - one of my principle design aims is to keep the code short and simple, and implementing a full parser would add a lot of bulk and complexity without significantly improving the utility of the function."
845-1,"passage: I've updated document.getElementsBySelector to support CSS2 and CSS3 attribute selectors, as described here. Attribute selectors allow you to match elements based on any attribute using a variety or different rules including begins-with, ends-with, contains and more. The new version is tested in Mozilla, Phoenix and IE5/Windows (and I'm almost certain it works in IE6). There is a slight bug in Opera 7 preventing the ends-with selector from working which I have been unable to track down - any Opera javascript experts out there?"
846-0,passage: Tim Bray: Why XML Doesn't Suck (a follow up to XML Is Too Hard For Programmers). I'd quote the best bits but there are just too many - this article clears up all of the loose ends in my understanding of why XML is such an important technology.
847-0,"passage: Jeremy Allaire has posted notes on an interview with Sergey Brin of Google, conducted at the PC Forum conference. Some highlights:"
847-1,"passage:
When or will you go IPO?"
847-2,"passage: I was really impressed with his answer on this. He understands the incredible distraction that an IPO can be both for the management team and employees. He says it comes down to the fact that he's just too lazy (which is clearly not the case!). The essence is a moral response --- public markets are too short-term focused and he wants his team focused on the long-run. Whatever the case, he admits that ultimately their employees and investors want liquidity and that will have to happen through an IPO or acquisition of Google."
847-3,"passage: A person in the audience asked a very interesting question -- idea -- about Google playing a leading role in enabling the semantic web. The basic idea was that Google should process pages and classify them into ontologies, and that they can derive lots of linked ontologies from all the content they already index."
847-4,"passage: He basically said he doesn't believe in the semantic web as a set of linked RDF data-structures. His basic argument is that the structure of natural language and what it presents is much much richer than meta-data tagging schemes. Clearly, Google's understanding of natural language is unique, but there still is a need for machine readable APIs for data on the Internet."
848-0,"passage: The Reflective Surface post reminded me that Wikipedia is traditionally excellent for programming related topics. Their overviews of Functional Programming, Imperative Programming and Scheme all live up to their usual high standards."
848-1,passage: Two interesting reads relating to the Programming Languages course I'm taking at University:
849-0,"passage: ""But the fact is, with an initial investment of only $800, in two weeks' time he had a portfolio valued at over $350 million. Every trade he made capitalized on unexpected business developments, which simply can't be pure luck.
"
849-1,"passage:
Officials are quite confident the ""time-traveler's"" claims are bogus. Yet the SEC source admits, ""No one can find any record of any Andrew Carlssin existing anywhere before December 2002."" "
849-2,"passage:
In a bid for leniency, Carlssin has reportedly offered to divulge ""historical facts"" such as the whereabouts of Osama Bin Laden and a cure for AIDS.
"
849-3,"passage:
""It was just too tempting to resist,"" Carlssin allegedly said in his videotaped confession. ""I had planned to make it look natural, you know, lose a little here and there so it doesn't look too perfect. But I just got caught in the moment.""
"
849-4,"passage:
""We don't believe this guy's story -- he's either a lunatic or a pathological liar,"" says an SEC insider."
849-5,"passage:
Carlssin declared that he had traveled back in time from over 200 years in the future, when it is common knowledge that our era experienced one of the worst stock plunges in history. Yet anyone armed with knowledge of the handful of stocks destined to go through the roof could make a fortune.
"
849-6,"passage: ""Time-Traveller"" Busted for Insider Trading (via Tony Bowden). This just has to be some kind of early April fools."
850-0,passage: This Ruler bookmarklet is really cool - it shows the current coordinates of the cursor within the browser window and allows you to draw boxes and see how large they are in pixels - invaluable for tweaking CSS layouts.
851-0,"passage: SmartPHP.net has some useful looking classes, including SmartTemplate (like Smarty but much simpler to use) and SmartCache, a very intelligent caching class that can be used to cache data objects as well as the output from whole pages. The example given caches a database query using the SQL statement as a unique cache key:"
852-0,"passage: UIE debunk three usability ""myths"" (the three click rule, the idea that users give up on slow loading web sites, and the ""5 to 8 test subjects should post most usability problems"" idea). 37Signals do a pretty good job of debunking the debunkers."
853-0,passage: Daniel Glazman's proposal for smarter positioning in CSS (see also this blog entry) makes a lot of sense.
854-0,passage: Clearing out some more tabs:
855-0,"passage: I think I've just bought my ticket. Unfortunately the online order form asked for the last 3 digits of my CCV number which, being printed on the signature strip of my card, rubbed off a long time ago. I disabled javascript and the form submitted just fine so it'll be interesting to see if my order succeeds. If it does, chalk one up for user friendly client-side security holes :)"
855-1,"passage: Cool - the new Glastonbury Festival website uses a CSS layout! Unfortunately it completely fails to validate as XHTML Transitional, but comes to within an inch of validating as HTML 4.01 Transitional (they just need to change the doctype, take out a few XHTML specific attributes and clean up a misplaced <b> tag)."
856-0,"passage: SitePoint are running an excellent new tutorial series: XHTML Web Design for Beginners. There's little there for non-beginnners, but I'll certainly be sending new learners in that direction."
857-0,"passage: Via Craig, Big John's new CSS layout ""I can't believe it's not a table!"". I've played with the key concept of this before: using a background-left image on the body and a background-right on an all-encompassing div to create the illusion of two columns stretching the length of the page, but I never got it working quite as well as this. Big John's layout uses that trick and a few others to get it rock solid across all browsers, then explains exactly how it all works in excruciating detail. Essential reading."
858-0,"passage: I'm playing around with a borrowed Compaq iPAQ at the moment. Unfortunately I don't have permission to go the whole hog and install linux on it but, as the next best thing, I've been working out how to get it to talk to my Linux box. A quick Google search brought up SynCE, an open source project providing all kinds of software to allow communication between *nix and handhelds running Pocket PC. So far I've got the command line tools working which allow me to transfer files to and from the iPAQ and start up iPAQ programs remotely. The next step is synchronisation with Evolution."
859-0,"passage: Yesterday, inspired by Keith's Programming page, I decided to take a look at REBOL. REBOL is a very high level scripting language designed for working with the internet. It has the interbnet built in to its very core - its 45 core datatypes include email addresses and URIs and it includes support for 14 standard protocols including HTTP, FTP, POP and even finger."
859-1,"passage: The language itself is impressively expressive. A classic example is the following one-liner, which retrieves the contents of a web page and emails it to a specified address:"
859-2,"passage: While the core of REBOL is closed source (and looks set to remain that way) implementations are available for 40 different platforms and the language has an developed a large community. I've hardly scratched the surface of the capabilities of the language - the GUI stuff in particular is very impressive. Also worth a look is Simple Content Management on ALA, which demonstrates how REBOL can be used to construct a simple, template based offline content management system."
860-0,"passage: Andy has rewritten getElementsByClassName, resulting in much cleaner code and a method which can be called on any DOM element, not just the document object."
861-0,"passage: From the number of Glasto tickets already selling on Ebay, it looks like this is going to be the year the festival was nearly ruined by the touts :/"
861-1,"passage: Bloody hell - Glastonbury 2003 has sold out within just 24 hours of tickets going on sale! My first thought was that this must be an April Fool's thing, but it seems extremely unlikely considering that Glasto fans are already being driven to paying double the price of the ticket from ticket touts (if it is a joke, it's gone horribly wrong). Luckily the main group of friends I'm going with all got there in time, but any hopes I had of convincing other friends to go are well and truly squashed."
862-0,"passage: Gotta dig Sam's retro redesign, nested tables galore ;)"
863-0,"passage: April Fool's day online hasn't been quite as much fun this year (call me sad but I enjoy a good April Fool's gag) thanks no doubt to people's sense of humour being dampened by the war. Still, CPAN and MetaFilter put on a good show. Disturbingly, I just flicked on the TV and caught Anne Robinson being nice to people on the Weakest Link. Maybe it's a good thing April Fool's only comes one a year ;)"
863-1,"passage: Via Simon Brunning, the Top 100 April Fool's Day Hoaxes of All Time."
864-0,"passage: From the same site as the Javascript article: jslint, a utility for checking Javascript for common programming errors and evidence of bad coding practise."
864-1,"passage: Stuart spotted this one too. In The Power of JavaScript he waxes lyrical about the untapped potential of JavaScript and the DOM in web applications. While I agree that remote scripting is a vastly under-used technique, I'm cautious to get too excited about Javaccript enhanced web application interfaces having seen Matthew Thomas rant about their usability implications at every available opportunity..."
864-2,"passage: Spotted on paranoidfish.org/links, JavaScript: The World's Most Misunderstood Programming Language dispells some myths about Javascript and shows how it is actually a very powerful and expressive language. The comparisons made to Lisp are particularly interesting."
865-0,"passage: The Mozilla project is shifting focus to concentrate more on standalone apps such as Phoenix and Minotaur. Cool. The full story can be found on MozillaZine, with further details on the Mozilla.org Roadmap. See also comments from Blogzilla and mpt."
866-0,"passage: The additional CSS required to use it (and to make quotes look pretty in better browsers), based on Mark Pilgrim's code from The Q tag, looks like this:"
866-1,"passage: Time for bed, said Zebedee."
866-2,passage: (This issue is fixed in Lynx 2.8).
866-3,"passage: Mark Pilgrim advocates using a server side script to mark up quotations with the relevant HTML entities. I'm not too keen on this solution purely because I tend to surf the web using Lynx 2.7 from University every now and then, and Lynx 2.7 displays some entities untranslated resulting in sites looking like this:"
866-4,"passage: There are two main disadvantages to this solution: It introduces an invalid property to your CSS, and it could result in duplicated quotes in IE 7 should that browser finally fix the lack of quote element support."
866-5,passage: The HTC file (fixquotes.htc)looks like this:
866-6,"passage: Marek Prokop has a cunning way of getting Internet Explorer to style <abbr> elements (IE, for reasons unknown, usually ignores their existence both as stylable elements and through the DOM). A comment by Mr. Farlops on diveintomark inspired me to have a go at fixing IE's equally faulty quotes behaviour using javascript. Rather than detecting IE by checking for the presence of document.all, I decided to use a Microsoft specific proprietary extension: DHTML Behaviors."
867-0,"passage: After several months spent offline, the css-discuss archives are back and better than ever thanks to the hard work of my colleagues at Incutio. As well as updating the archives with all of the missing posts from the past few months they've improved the URL scheme to make things more search engine friendly (hopefully Google will start indexing the archives now)."
868-0,passage: ThreeColumnLayouts in the css-discuss Wiki currently lists 24 freely available three column CSS layout templates.
869-0,"passage: Adrian Holovaty demonstrates how standards compliant code and effectively written javascript can decimate the size of a clunky navigation interface, and make it more usable and accessible to boot: Web standards improve 2theadvocate.com navigation."
870-0,"passage: This site now sports a funky favicon, care of Nat."
871-0,"passage: Thanks to Dan Sugalski (designer of Parrot, the next generation Perl VM) I finally understand what continuations and closures actually are. He explains them as part of a comparison between the forthcoming Parrot and two popular virtual machines already in existence:"
872-0,passage: If you get the basic idea of web services but are still looking to get your head around SOAP (I know I am) the lively discussion currently taking place in Sam Ruby's comment section looks like a great place to start.
873-0,passage: The concept is expanded upon in Steve's recent presentation Inclusive Web Design For the Future.
873-1,"passage: Meet The Makers are carrying a great interview with Steve Champeon, author, web standards advocate and founder of the Webdesign-L mailing list (which I re-subscribed to today). Steve's explanation of the concept of ""progressive enhancement"" is particularly interesting:"
873-2,"passage:
The idea is to separate not only the structure from its presentation, but also make distinctions between what content needs to be arranged in what way for lowest common denominator browsers, and how to build on that structure, adding more features for those browsers that can handle them. It's basically just taking the idea of a ""target browser"" and throwing it away, and taking the idea of ""graceful degradation"" and standing it on its head. We're trying to make sure we build sites that not only work okay everywhere, they're designed to work everywhere before they do fancy things in modern graphical desktop browsers. It's too common to build sites that work ""right"" in IE/Win and work ""acceptably poorly"" everywhere else. I think it's ridiculous, it's lazy, and it's not that much more work to do it right.
"
874-0,"passage: If you have ever watched someone browse for information you'll notice how they are really afraid of not finding their way back. They'll find an interesting page, they want to hold on to it, but they also want to explore its out-links -- so they open up more windows with the out-links. I call this ""The Hansel und Gretel mode of browsing"" because these people leave a trail of breadcrumbs in the form of open browser windows to find their way back. (Sometimes experiencing that their breadcrumbs are eaten by the gremlins that make browsers crash)."
874-1,"passage: Bjørn Borud (a Senior Software Engineer at AllTheWeb) has recently started blogging. His thoughts on wikis make interesting reading. I also rather liked his description of something he calls the ""Hansel und Gretel"" mode of browsing:"
874-2,"passage: I can really identify with the above. I open links in new tabs far more often than following them normally, partly because having them load in the background means I'm never left waiting for something to load but mainly because I've never felt comfortable using the back button for some reason. Browser crashes, when they do happen, can be extremely disorientating."
874-3,"passage: People who have developed an understanding for how the back button works (yes, a lot of people do not understand the semantics of the back button) often seem to employ a different strategy. Their browsing looks like a depth-first traversal of a tree -- always making sure that they can use the back button to find their way back. Occasionally bookmarking a page or opening a new page for later perusal, but always preserving the history stack in a state that ensures that they can traverse the link structure sensibly. "
875-0,"passage: PhotoPal is a new PHP image gallery system by Noel Jackson inspired by the Photos section on Textism. The way it is implemented reminds me somewhat of the Blosxom philosophy - the album's structures is defined by the directory structure, with simple text files adding additional descriptions, and metadata is extracted from the photos themselves using PHP's exif_read_data() function."
876-0,"passage: Could Tom Watson be the blogging world's best kept secret? He's the Labour MP for west Bromich East, he's been blogging apparently since since July 2001 and posts updates several times a day, including an almost daily ""Today in parliament"" entry. I'm surprised I haven't seen him linked to by someone before. I wander if any other UK MPs have frequently updated blogs?"
877-0,passage: Further reading:
877-1,"passage: I spent most of today knee deep in RSS, writing an aggregator for a project at work. It has been quickly becoming apparent that ""Really Simple Syndication"" is anything but! There are currently three major (and goodness knows how many minor) specifications doing the rounds, and the majority of feeds seem to pick and chose between the three at will. Even the three core elements that describe an item (title, link and description) are both optional and heavily overloaded."
877-2,"passage: Consider, for example, the seemingly simple task of extracting the URL of an item. All three specifications define a <link> element for this, but RSS 2.0 introduces guid which can also be used to define a permalink (unless its isPermaLink attribute is set to false). The Scripting News RSS Feed provides a guid rather than a link, and some Radio Userland feeds provide both but leave the link element blank. Introduce the ongoing discussion on how relative URLs should be resolved and things get even nastier."
877-3,"passage: Next up, extracting the actual content of an entry. Traditionally, this occurs as an HTML entity encoded string in the description element. Recently however a new element, content:encoded, has started to become fashionable (this uses a CDATA section). Even more recently, xhtml:body has started gaining ground which uses namespaces to embed unencoded XHTML, making event based parsing of content that much more difficult..."
877-4,"passage: The aggregator I'm building is similar in style to Spycyroll, and as such needs to know the date that an entry was posted. On this point the specifications start to differ dramatically: RSS 2.0 uses pubDate, while RSS 1.0 relies on the Dublin Core element dc:date. In the wild this gets really messy - in a survey of the feeds linked to by Python Programmer Weblogs I found no less than 5 subtly (and not to subtly) different ways of representing dates. Here are some examples I picked up:"
877-5,passage: pubDate
877-6,"passage: So what have I done? For the moment, I've gone with the path of least resistance. Onyx RSS is a well designed parser based on PHP's XML support (so no invalid feed support) which works just fine for the moment. Unfortunately it is licensed under the GPL, and since this is likely to end up as a commercial project I'll have to find something else for the final cut - or more likely implement something from scratch that uses REX."
877-7,"passage: Having battled through that lot, the conscientious aggregator writer hits the next big hurdle: Approximately 10% of RSS feeds are badly formed XML! This issue is covered by Mark Pilgrim in Parsing RSS at all costs where he presents an ultra liberal Python RSS parser which uses Python's relatively forgiving sgmllib module. Great, except PHP doesn't have one of those... enter REX, a technique for ""shallow parsing"" of XML using regular expressions (no, it's not as cludgy as it sounds - in fact Python's sgmllib module is built on the same principles). Martin Spernau has an excellent article showing how REX can be implemented in PHP and demonstrates the technique in a modified version of the MagpieRSS library. Of course, XML purists (with very good reason) advocate ignoring badly formed feeds but as Mark points out, this really isn't a very practical approach."
877-8,passage: dc:date
878-0,"passage: I've just finished migrating this site to a new server. Everything seems to be working, and the site appears to load noticably faster now."
879-0,passage: The other comments are well worth reading as well.
879-1,passage: Bill Kearney posted this comment in response to yesterday's semi-rant:
879-2,"passage:
Sure, the trouble is getting the developers of the applications creating the RSS to stop being pigheaded. This is, unfortunately, a non-trivial matter. Several battles have been waged, to varying degrees of success. Fundamentally, there's a faction that naively worries about 'readability' of the XML. Then there's a crowd that worries about the verbosity. Over in another corner is the 'but I want to theoretically be able to use mod_kitchensink in my RSS'. Meanwhile, vendor jockeying with proprietary, half-baked extensions keeps happening, over and over... "
879-3,"passage: The fortunate thing is diversity. As more tools come online it becomes apparent that giving the users what they want often means switching tools. When one tool doesn't cut it, the users switch. Witness the incredible growth of MovableType. It defaults to creating RSS-1.0 files and makes a lot of use of RDF (via trackbacks). The users never see the gritty details, they just see nice functionality and use it.
"
880-0,"passage: I've put together some notes on constructing CSS layouts using absolute positioning over on the css-discuss Wiki. If you have any suggestions or improvements, just make them :)"
881-0,"passage: Installation was handled by Java Web Start, which is a technology I've completely ignored before now. It's very smart - essentially, it integrates with your browser (via a mime-type association) to allow execution and installation of applications with a single click on a link. Spaces weighs in at 2.5MB, so on broadband it took about a minute for it to download. It showed me a certificate, asked for permission to access my hard drive and loaded up the application. Now that it's installed I can execute it through the Java Web Start icon on my desktop (with an option to add a direct shortcut to the start menu - yup, I'm using Windows XP at the moment). It's very slick."
881-1,passage: I'm sorely tempted to give Java another go.
881-2,"passage: My opinion of Java as a platform for developing GUI applications has generally been that it results in slow, clunky, ugly software that is a pain to install, feels unresponsive and fails to behave in the way I expect a GUI to behave. I based this on my experience with Java applets (ugh) and Mediasurface, a content management system I had to struggle with for two years working for a dot-bomb in London."
881-3,"passage: I've just had my mind opinion reversed by spaces and Java Web Start. Spaces is a PIM of sorts, but stands apart from the rest in that it introduces the concepts of ""spaces"", which are abstract entities that group related content together. Content comes in the form of contacts, email, notes, tasks, a calendar and RSS feeds. It's an interesting concept and the implementation is excellent for an alpha release."
881-4,"passage: While spaces is interesting, it's not quite good enough for me to switch to it over Evolution. What it has done is shown me that a Java application can be fast, good looking and every bit as usable as a native application. It uses Java's look-and-feel functionality to adapt to the system it is running on, which I had seen in action once or twice before but never really took seriously until now. The author claims that write once run anywhere is no longer a myth, and backs it up with a screenshot of spaces running on OS/2."
882-0,"passage: Of course, with the amount of personal data I am now accumulating security is likely to become more of an issue due to the threat of identity theft (I'm not keeping anything truly vital like passwords on there but it's still a consideration). Maybe I should start looking in to https."
882-1,"passage: I've been struggling with different methods of staying organised for as long a I can remember, but I think I've finally found something that works. A couple of days ago I set myself up a password protected Wiki (using my own slightly modified version of WikkiTikkiTavi) to see if a private personal Wiki could help me stay on top of things. It's already proving remarkably useful. I've set up the front page as a to-do list, split in to University, Work and Personal sections. Any tasks which involve writing or developing ideas are wiki words linking to a page where I can develop them further. I've also got a section devoted to things I plan to blog (hence the recent surge in blogging activity), a bunch of links to useful sites and the beginnings of a collection of phone numbers and contact details. I also finally have a good place to keep all of those irritating but essential pieces of information such as my National Insurance number."
883-0,passage: I'd been thinking about implementing a personal web proxy (inspired by Les Orchard) with some kind of interface for telling it to cache the page I last visited but a simple bookmarklet sounds like a much better solution. I don't think I'd want it as part of an aggregator though. Starts tinkering...
883-1,passage: Jesse Lawrence is also looking to implement his own aggregator:
883-2,"passage:
I've been searching high and low for an RSS reader that I'm happy with and that works on Linux, but so far I've been unsuccessful. So, last night I started coding my own. It's going to be more of a personal communication system, though, not just an RSS reader. I want it to have email reading and writing capabilities, and also webpage caching, through the use of javascript bookmarks. This way, when you find a page you like, hit a bookmark, and it gets saved to you system, in a way which makes it easy to find.
"
884-0,"passage: As an aside, I learnt a couple of useful things about HTTP while putting the class together, both of them from reading comments in the PHP Manual. Firstly, HTTP 1.1 is best avoided from a scripting point of view - it requires support for chunked encoding if you want to avoid random hex added to your content, and provides no practical advantages over HTTP 1.0 (cookies / gzip encoding and the all important Host: header work just fine without it). Secondly, if you want to uncompress gzip encoded content from an HTTP response you need to remove the first 10 characters before running the gzinflate() function or it will fail with a mysterious error."
884-1,"passage: The HttpClient site has example code, a manual and a demo which shows the client accessing Amazon.com with debug mode turned on."
884-2,"passage: I've been working in quite a roundabout fashion recently. My principle target is to build a collaborative blogging system. As part of this, I needed an RSS aggregator to allow a single blog to show the most recent entries from a number of other, related blogs. Then I needed a way of downloading RSS feeds from external sites. While thinking about this (although to be fair it's pretty much a solved problem) I was inspired to build something that could cache whole sites. And that lead me to need a PHP HTTP client class for retriving information from the web. So I wrote one of those :)"
884-3,"passage: HttpClient is similar in some ways to Snoopy (which I have been using and recommending for years) but takes a different approach and includes some interesting new features. Firstly, while Snoopy contains a bunch of code for parsing HTML (to extract forms, links and the link) HttpClient concentrates purely on the HTTP side of things, leaving HTML parsing to other classes. Secondly, HttpClient supports gzip encoding. And finally, HttpClient is designed to be used multiple times in a single session, and will store and resend cookies and referral information between requests."
885-0,"passage: The alternative W3C buttons on AntiPixel are great. Jamie Zawinsky suggested recreating them in CSS. Stuart Langridge, Marek Prokop, Nick Boalch and Eric Meyer all had a go. Eric even did the Raging Platypus ones as well."
886-0,passage: Mike Golding has some interesting thoughts on Archive Navigation in blogs. He uses mine as an example of what not to do. I agree - the archives on this site leave an awful lot to be desired. I've got a few ideas to improve them (mostly inspired by Mark Pilgrim's excellent calendar navigation) but I can't really do anything until I've been through and added titles to every single entry :/
887-0,"passage: htmlcleaner is a PHP class which claims to be able to clean up the revolting HTML generated by Micrsoft's HTML libraries, in particular the one that is used for browser embedded WYSIWYG editors. We're using HTML Tidy for this with excellent results, but for people who can't run HTML Tody this could be a useful solution. Unfortunately the class is hosted on PHP Classes which still insists on making you log in for no apparent reason."
888-0,"passage: UltraEdit tip (discovered just now): If you keep trying to copy and paste between UltraEdit and other applications and it just doesn't work, the chances are that you've accidentally hit Ctrl + 1 through 9, which is the UltraEdit shortcut for selecting a custom clipboard. Hit Ctrl + 0 to get back to the Windows system clipboard and have everything behave as it should again. I suppose this feature could be useful, but I've got ridiculously fast at hitting Ctrl + Windows Key and typing ""notepad"" whenever I want to dump my current clipboard contents somewhere temporary without losing it."
889-0,"passage: Ed Swindelles has relicensed his Onyx RSS Parser under the MIT License, meaning it can now be used without risk for building commercial software. I haven't decided which license to place HttpClient under, but that one looks like a pretty good bet. I'll work it out in the morning."
890-0,"passage: On gazingus.org, Flexible Node Retrieval introduces a new addition to the getElementsBy* family of javascript functions, getNodesByType. This general purpose function uses a callback function to ""filter"" the child nodes of a DOM element. It works a bit like PHP's array_filter function. One for the toolbox."
891-0,passage: I thought the US was meant to be the land of the free.
892-0,passage: New York Times: Yahoo Plans Improvements in Effort to Regain Lost Ground. I'm guessing this is what it's going to look like (via thelist).
893-0,"passage: Unsurprisingly, the new Yahoo is generating a whole load of commentary. There's a good thread going on Signals vs Noise, and ia/ has coverage as well. I've been playing with it a bit and it's definitely an immense improvement on the current Yahoo, although it's still not quite as usable or responsive as Google. I also noticed that the search results are exactly the same as Google's (even for image search) so it looks like Yahoo haven't switched over to Inktomi just yet."
893-1,"passage: It's worth clicking through the tour to get an overview of the new interface. The ""open in new window"" icon for each search result is a clever addition, but the smartest feature in my opinion are the specialised Yahoo shortcuts. mail! takes you to Yahoo mail, calendar! to Yahoo calendar and so on. It looks like are Yahoo hoping to out do Google by capitalising on their many other services, which seems like a very sensible approach."
894-0,"passage: Via Sam Buchanan, Hydra is a remarkably innovative text editor that allows multiple users, via a network, to edit the same document at the same time and have it update live on each other's screens. This screenshot probably demonstrates it best, showing multiple participants working on the same code simultaneously. The colour coding (where each person's edits shows up in a different colour) is a particularly nice touch. Unfortunately, Hydra is only available for Mac OS X so I can't try it out myself. Hopefully they'll release the code at some point and let aspiring Windows / Unix hackers try and port it to their respective platforms."
895-0,"passage: A post on Bryan Richard's blog about Safari leads to a query about whether or not Py (a Python print magazine) should move to PDF, which in turn leads to a fascinating discussion about the accessibility of both websites and Python source code itself. Well worth taking the time to read."
896-0,"passage: Via Sam Buchanan, Daniel Savard's incredibly useful LiveHTTPHeaders addon for Mozilla and Phoenix. It adds an extra tab to the Page Info dialog with the full HTTP headers sent with the page, and also adds a HTTP Headers tool to the Tools menu which can be used to watch and debug HTTP requests in real time. I wish I'd known about this when I was developing HttpClient."
896-1,"passage: Incidentally, check out the headers on Slashdot for a particularly geeky in-joke ;)"
897-0,passage: Russell Beattie rants with zealot passion about how next generation mobile phones will change the way we live:
897-1,"passage: Like the mid 1990s when suddenly you could easily use the internet for the first time to look up timely information - say medical information or shopping comparsions for cars - at first it seemed incredible, now 90+ percent of new car buyers start on the web. It's now become a part of how we all live. We've been waiting for the past few years for another technical revolution of similar proportions. An enabling technology that will seem interesting, fun and new at first, but then soon become vital to our every day lives. Well it's arrived..."
897-2,"passage: It's about anywhere/anytime communication and access to the information that you need. Life itself is about communication: we talk to, we listen to, we read about, we watch other people every day all day. It's why we get up in the morning. Suddenly we're going to be able to communicate in new and varied ways: via voice, email, chat, images and video instantly and receive the same all in return. And we're going to LOVE it. But as a bonus, suddenly you can access information where and when you need it as well: ""What time's that movie? Where are we? How do we get there? Do our friends want to come? I better buy tickets now..."" The combination of the two is a powerful package and soon you won't be able to remember what it was like to have to boot your computer just to browse the web or send an email or chat or play games.
"
898-0,"passage: The Python Programmer Weblogs script apparently scrapes this wiki page for feed information, so I've updated the link on there to my RSS feed."
898-1,"passage: I frequently check the Python Programmer Weblogs page for an addition to my daily blogging fix. It's a simple but very effective idea: Subscribe an aggregator to a bunch of feeds about a similar topic and publish the results for all to see. I'm one of the more prolific bloggers of the ones listed there, and since I tend to post a whole bunch of entries in a relatively narrow timeframe my stuff often appears in a big lump on the front page of the site. I've been feeling slightly guilty about this, as most of my posts have nothing to do with Python at all. So I've finally got my act together and knocked out RSS feeds for individual blog categories."
899-0,"passage: Via the XHTML-L mailing list, Simon St.Laurent's XHTML tips archive. An abundance of useful XHTML related information."
900-0,"passage: Via Eric Meyer, the best bookmarklets collection on the web. Make a bee line for the Web Development Bookmarklets and grab test styles and shell (both Netscape / Mozilla only) - shell brings up a javascript console shell which can actively modify the DOM of the current page, while test styles (easily the most useful bookmarklet I've ever used) allows you to make live, dynamic changes to the CSS currently affecting the document. You type CSS statements and as soon as they are complete enough to be parsed they are applied to the current page. The other bookmarklets are well worth a look as well, especially ancestors which displays the CSS selector hierarchy of the element under your mouse pointer in the browser's status bar."
901-0,"passage: I've tested it in Phoenix, IE6 and Opera 7 on Windows. If you spot any problems in Mac based browsers please let me know."
901-1,"passage: Redesigned. CSS changes only, took less than half an hour thanks to the zap style sheets, test styles and ancestors bookmarklets. I'm feeling orange :)"
902-0,passage: Truly bizzare.
902-1,"passage: And the prize for freakiest CSS bug in the universe goes to... IE6! I was having a problem with the new design and a horizontal scrollbar occuring in IE6 for no readily apparent reason (the same bug had plagued my previous design as well). Bill Simoni on CSS discuss pointed out that the scrollbar wasn't appearing on the comment / entry pages. After an extensive trial and error session I tracked the problem down to the fact that my blockquotes were in italic. If I removed the font-style: italic property from the blockquote declaration, the horizontal scrollbar vanished. No other changes were needed."
903-0,"passage:
Python is an Agile programming language!
"
903-1,"passage:
Python is like the Lament Configuration in Hellraiser: looks
like an exotic puzzle, is actually a gateway to a world of
programming discipline and pleasure beyond pain.
"
903-2,"passage: Two views on Python, from Kevin Altis and NTK respectively:"
904-0,"passage: Via Ed Tech Dev, HEML, the Historical Event Event Markup and Linking project, looks like a really interesting concept. It defines an XML format for marking up historical events, along with tools based on Java and XSLT that can convert Heml data in to SVG timelines and other useful representations."
904-1,"passage:
Consider, for instance, twelve diaries or memoirs, each a different view of the Siege of Sarajevo in 1994 and published on the web. They would include entries about events such as the stationing of troops or the evacuation of a certain region on such-and-such a day. If a standard form of mark-up were used to tag the text that recorded these events and their date and location, a computer could collect this information and associate it with the document. It would then be possible to search for descriptions of events on a certain day, or in a certain region or both, and retrieve references to the proper section of the pertinent memoir or memoirs.
"
905-0,"passage: Via Accessify, Joe Clark's analysis of Accessibility implications of digital rights management. Also, the new issue of Made For All includes an interview with Joe Clark which focusses on web accessibility."
906-0,"passage: CodeBitch's tips on isolating ""crashing"" bugs in CSS are mostly common sense, but are well worth reading in any case. Her methods could easily be adapted to help track down less serious bugs as well."
907-0,"passage: Via Column Two, pixelcharmer's collection of URI design resources."
908-0,"passage: PHP also has support for verbose REs, thanks to the excellent pcre functions. Just use the 'x' modifier as explained on this manual page."
908-1,passage: Ned Batchelder describes Verbose Python regular expressions. This is one of the things I've known about (as in known that they exist) for ages but have never got around to using. I've been working with some pretty heavy regular expressions recently that could really do with the clarity of being defined in verbose format with comments.
909-0,passage: That's the second time this week I've come across an opinion that questions the benefits of the OOP-at-all-costs approach to programming. The first was in Paul Graham's The Hundred Year Language:
909-1,"passage: Somehow the idea of reusability got attached to object-oriented programming in the 1980s, and no amount of evidence to the contrary seems to be able to shake it free. But although some object-oriented software is reusable, what makes it reusable is its bottom-upness, not its object-orientedness. Consider libraries: they're reusable because they're language, whether they're written in an object-oriented style or not."
909-2,"passage: I don't predict the demise of object-oriented programming, by the way. Though I don't think it has much to offer good programmers, except in certain specialized domains, it is irresistible to large organizations. Object-oriented programming offers a sustainable way to write spaghetti code. It lets you accrete programs as a series of patches. Large organizations always tend to develop software this way, and I expect this to be as true in a hundred years as it is today."
909-3,"passage: As undergraduates, we have been exposed to the joys of object oriented programming from our first week at Uni, possible because we're supposedly destined for the large organisations Paul mentions. It's nice to see the view from the other side of the fence for a change."
909-4,"passage: That's not to say I'm unhappy with PHP5. Most of the stuff in PHP5 is great, most notably exceptions; I'll certainly be taking advantage of many of the new features in Zend Engine 2. But most of my code is procedural, and Zend Engine 2 is mostly an object oriented functionality upgrade."
909-5,"passage:
Personally, while I have programmed with both C++ and Java, I am mostly a procedural guy. I feel that most object oriented programming consists of abstracting different problems into the same problem and then resolving that problem. Sure it makes it easier, but its incredibly inefficient for developing a small set of interconnected programs, which really is the whole point in web development."
909-6,passage: An Interview with Sterling Hughes on PHP5 from the PHP-Con site:
910-0,"passage: Via Ed Tech Dev (and others), an RSS Feed Reader / News Aggregators directory and an RSS Readers wiki page."
911-0,"passage: Finally some good documentation on using SOAP with PHP: PEAR::SOAP Client Fast Start and Extending PEAR::SOAP WSDL, both from the excellent phpPatterns."
912-0,"passage: Time to update bookmarks: The Web Review CSS Support Charts, which went offline several weeks ago, are back at a new home on Netscape DevEdge. Despite not having been signiicantly updated since 2001 they still are still an excellent reference to refer to for CSS browser compatibility issues. More information from Eric Meyer."
913-0,"passage: In all the fuss about Yahoo's new search interface over the past few days, the extensive use of CSS in the results pages was almost completely overlooked, probably because the page still contains a small layout table for the top and bottom navigation. The results themselves are served up as a styled ordered list, at least for modern browsers (thanks to a server side browser sniffer). More information in this message from Yahoo's Brian Ghidinelli, who is seeking feedback."
914-0,"passage: Search Engine Watch (with a nice new design but horrible markup) have an extensive analysis of the recent ""Big Brother"" accusations that have been levelled at Google."
915-0,"passage: Via Leonard, GNU utilities for Win32 provides a whole bunch of useful utilities in Windows friendly binaries, without the need for external libraries such as Cygwin, including gzip, tar, flex, bison, make, grep and the ever useful wget. The package also includes diff, which makes me feel a lot more comfortable about using it from within PHP scripts as portability to Windows will no longer be an issue."
916-0,"passage: 100 random AltaVista pictures is fascinating, if not guaranteed work-safe."
917-0,"passage: Update (April 15th, 17:30): It appears that this wasn'e really intended for public consumption outside of css-discuss. Alex Robinson has posted a note to this effect on the page. It also doesn't use the source ordered columns technique, but this alternative tool does."
917-1,"passage: A tool for generating 3 column CSS layouts that appears to use Big John's Source Ordered Columns technique. CSS generating tools are a thoroughly excellent idea and I'm surprised no one has done one before; the CSS community is at a point now where there are some well understood, solid layout techniques available and some kind of tool that helps generate frameworks for new designers could really help speed up CSS adoption."
918-0,"passage: As someone with virtually no graphic design skills, Create A Collage With Fireworks on SitePoint is the kind of article I'd love to see more of."
919-0,"passage: Opera 7.10 is out, and includes the first Opera 7 beta release for Linux. I'll have to try this out when I get home."
920-0,passage: There's something almost Zen-like about the dullest blog in the world.
921-0,passage: Phil Ringnalda posted a rant about sites that don't tell you how their comments system works - like this one. I've been meaning to add instructions for ages but never got round to it; now I have. Hopefully this will mean less comments with no line breaks or links that don't work.
922-0,"passage: Artima.com recently started hosting weblogs, with membership by invitation only. With people like Guido van Rossum and Ward Cunningham already signed up Artima looks set to become a very interesting corner of the blogging world."
923-0,"passage: That's pretty much it. The class also has support for passphrases which can be used to add an extra layer of protection to a private key, as well as methods to handle crypotgraphic signing and verification."
923-1,"passage: Via Garth Kidd's Python cryptography roundup, ezPyCrypto is a cryptography API so simple even I can use it. Unfortunately the example code is only available in the download archive (not on the web site) but here's an overview of how it works:"
923-2,"passage: ezPyCrypto is an easy to use wrapper for the excellent PyCrypto module, and includes PyCrypto (and a handy Windows installer) in the distribution."
924-0,"passage: Wired have a fascinating article on the technology being used for The Matrix Reloaded. They've apparently achieved photo-realistic CGI humans using a technique caleld ""image-based rendering"" based on taking a huge number of high resolution photos from different angles and using them to generate the 3D geometry of a scene."
924-1,passage: The MetaFilter discussion about the Wired article has comments from the author of the article himself.
924-2,"passage: The technique was first demonstrated in The Campanile Movie, where it was used to create a flyover of a University campus using still photos taken from a kite. It's worth downloading the film to get an idea of just how powerful the technique is."
925-0,"passage: Last 40 comments, more for my use than anything else (I keep missing comments posted on older entries)."
926-0,"passage: ""If the software makes publishing your thoughts and ideas easier, it will certainly catch on. For me, there is the advantage of getting ideas and opinions in the public domain quickly, without the reliance on your good profession (journalists) to interpret/edit what I've said."""
926-1,"passage: What's more, Watson is convinced that weblogging will catch on among his fellow MPs."
926-2,"passage: Watson admits: ""I'll get some stick but I think eventually people will see that is fundamentally a more honest way of communicating with people who want to know what you think and do. Oh, and its also great fun and slightly addictive."""
926-3,passage: It is a huge political risk (Watson's spoof page for teenagers caught the eyes of the national newspapers last week) but Watson is determined to stick with it.
926-4,"passage: Via Tom Watson himself, a short interview with Tom, the UK's first blogging MP:"
926-5,"passage: Not only is Tom's weblog a great precedent for a more open, accessible government, it is also a fascinating insight in to the day to day life of an elected representative in this country. It's a shame all the press coverage so far has been about the spoof teens page rather than the format of the site itself."
927-0,passage: No blogging for a while; I'm getting stuck in to a whole load of University coursework. In the meantime though here are some Python links I've been hoarding for a few days on my private wiki:
928-0,"passage: Dave Winer, in a follow up to his recent CSS problems:"
928-1,passage: Mark Pilgrim responds:
928-2,"passage: This is certainly a problem with CSS layouts - their maintainability can suffer due to the separation of the presentation from the layout (itself the greatest advantage that CSS provides). Tools such as the ViewStyles, ancestors and ShowDivs bookmarklets certainly make this easier but to my knowledge no one has written a bookmarklet that shows the inherited styles for the currently selected element - at least not yet. Pixy's List Computed Styles comes close, but shows styles for every element in the document all in one big window."
928-3,"passage:
Your site [code] still is signifigantly harder to read, at least for me. I'm constantly cross referencing - HTML to CSS, HTML to CSS, HTML to CSS, HTML to ... When you dissassociate style information, I contend that its really not about the humans editing the file anymore. Its about robots understanding the file. This point is made even clearer by XHTML 2.0, where they remove the style attribute.
"
928-4,"passage: Meanwhile, Sterling Hughes poses a valid point in favour of presentational markup in response to Sam Ruby:"
928-5,passage: Those are the key posts. The resulting flame war can mostly be found here (along with trackbacks to pretty much every other bit of blog coverage).
928-6,"passage:
Over the past two years, Mr Winer has repeatedly complained about CSS and structural, semantic markup, and has even asked what is wrong with tag soup. As one who sees the web as a vehicle for writing, Mr Winer should know instinctively what is wrong with tag soup. Tag soup bloats web pages, slowing their delivery for all users and especially penalizing dialup users. Tag soup corrupts data by yoking it to nonstandard formatting instructions. These formatting instructions work in some environments but fail in others. For instance, they get in the way when trying to deliver content to text-oriented devices with small view ports, such as Palm Pilots and web-enabled cell phones. Why should the users of these devices be forced to download 40K of HTML formatting instructions that will not work for them? And then have to download 40K more when they link to a new page? And 40 more on the next?
"
928-7,passage: Jeffrey Zeldman offers some solid arguments against tag soup:
928-8,"passage:
I used to work reasonably well with Dave Winer until the RSS validator came along. Now my feed is supposed to be a soldier in the fight for ""validation"" and ""standards"". Help. My syndicated feed has to look great in NetNewsWire (according to my site statistics, it has more than 4 times the market share of Radio), and I can’t wait for the other newsreaders to fix their bugs. So I’m going to skip required elements and use invalid XML whenever it suits me, and to hell with the validator, and to hell with these newfangled ""standards"".
"
928-9,"passage:
I used to work reasonably well with designers until CSS came along. Now my writing is supposed to be a soldier in the fight for Web ""standards."" Help. My work has to look great in MSIE, and I can't wait for the other browsers to fix their bugs. So I'm going to use paragraphs and breaks and old unbuggy stuff like that where I need to.
"
928-10,"passage: In my experience, resistance to CSS seems to come mostly from people who have been creating table based layouts for years. This is unsurprsing - they are being told to throw out everything they have learnt and start with a completely clean slate. I think the real evidence that CSS is a less complex way of laying out pages comes from new developers; I recently taught my girlfriend to design pages (starting from no previous experience) and she took to CSS like a duck to water."
928-11,"passage: So Dave dislikes CSS because support is buggy, while Sterling sees it as adding extra complexity. Buggy suport is pretty much a solved problem now, at least for most simple layouts - the CSS-Discuss Wiki is accumulating information on how to defeat bugs at a very decent rate and any problems not solved on there are certain to be understood by the friendly inhabitants of the CSS-Discuss mailing list. As for the extra complexity argument, laying out web sites with HTML has always been complicated - take a look at any site that uses nested tables to see what I mean."
929-0,passage: One of the things that has always bugged me about creating login forms for web based applications is that the password is passed in clear text when the user logs in. Even if you then set a session cookie of some sort for future access the password has stilled been transmitted unencrypted at least once.
929-1,"passage: The author links to implementations of this idea in various languages, and implementing it from scratch in PHP is quite trivial. With a bit of care the system can be set up so that browsers with no javascript support submit the password normally, while those with javascript send only the hash."
929-2,"passage: The obvious way around this is to use https, but for the vast majority of sites this isn't an option. Enter Javascript MD5 - an implementation of the cryptographically secure MD5 hashing function in Javascript. This can be used to build a CHAP login system where the client sends the MD5 of the password appended on to a challenge string, which the server can then recalculate and compare (all without the password being transmitted from client to server)."
929-3,"passage: A modified version of the system is used by Yahoo's Login Page, so it is certainly feasible for deployment in a commercial environment. Obviously an https encrypted session is far more secure, but for non-ecommerce web applications this technique is a no-brainer."
930-0,"passage: What the *F* happened to the internet? is a rambling but entertaining description of how big business stole the 'net, and how it doesn't really matter (via Paul Hammond's links blog)."
931-0,"passage: Keith is calling for bloggers to implement a ""notify me of any replies"" feature for their comments systems:"
931-1,"passage: I like it. It's a relatively simple feature to implement with instant, obvious benefits. I'll try and work on this some time this week."
931-2,"passage:
There are a few ways to do this. You could get an e-mail for every reply that's made, but that could quickly flood you with e-mail. It doesn't scale well, and I guarantee you messages are harder to put in context this way. The better solution, and the one that message boards use, is to e-mail you when there's a new post made, but then not e-mail you again until you've visited the site and seen all the new posts. This scales better.
"
932-0,"passage: Dave Winer has launched an experimental ""open"" blogroll. It looks a bit too open to abuse for my liking (Wikis are protected to a certain extent by their revision historys) but the interface for changing the order of entries is one of the most elegant non-javascript solutions I've seen."
933-0,"passage: My rambling post on CSS yesterday has had some excellent feedback, including some insightful comments on the weaknesses of CSS layouts. My call for a new bookmarklet drew responses (and implementations) from both Stuart Langridge and Jesse Ruderman! Both are well worth installing."
934-0,passage: Sam Ruby has plenty of RSS stuff today as well.
934-1,"passage:
Because, boys and girls, RSS is no longer a science experiment, it's becoming an important part of the infrastructure, which means that a lot of programmmers are going to get the assignment of generating and parsing it, and they need better instructions.
"
934-2,passage: Tim Bray: RSS Needs Fixing:
934-3,"passage: I've calmed down a bit from my RSS is too complicated rant of a few weeks ago. I still think there is a huge challenge facing implementors of tools that consume RSS, but when you compare that to the challenge of constructing a modern web browser it really isn't such a big deal. The biggest problem is probably keeping up with the myriad of versions, extensions and proposed extensions to the current standards."
934-4,"passage: Tim's main problems are with escaped HTML in the <description> element and the lack of support in RSS for relative URI references. Tim says double-escaping of entities is ""stupid"", but it seems to me to be a fairly logical extension of escaped HTML. Of course, escaped HTML itself is probably the single ugliest thing about the current RSS spec but there are good practical reasons for it, and if I've learnt anything about Dave Winer over the past few days it's that he prefers practical solutions to theoretical ones."
935-0,passage: Credit where credit's due: It turns out the interface for re-ordering items I praised yesterday was designed by Bryan Bell.
936-0,"passage: I'm using Smarty in a project at Uni at the moment, mainly as a tool to allow team members to modify different parts of the codebase without stepping on each other's toes. I've seen some good arguments against templating solutions such as Smarty, based around the point that PHP is already a templating engine so the extra layer of abstraction just isn't necessary. Never-the-less, I've been finding that Smarty dramatically improves my productivity even when I'm working on my own. Here are the links I've provided for my team members to help get them up to scratch on how it can be used:"
937-0,"passage:
Some areas of your life you want to expand and grow. Others have been neglected, and you need to work on restoring them. Most things just need to be maintained, and it might help to make a list of all the things that demand maintenance (how much and how frequently) in your life. Some of those things should probably be pruned away. And everyone I know has areas of their lives or unfinished projects that need to be closed off and put/parked away for good.
"
937-1,passage: (I think this is the most introspective thing I've ever posted on here).
937-2,passage: Tantek: What to do with things to do:
937-3,passage: I can really relate to this. There are definitely things in my life that could do with either closure or pruning (or both). The problem is facing up to them.
938-0,passage: Nothing like a bunch of coursework deadlines to focus the mind on alternative activities :)
938-1,"passage: As promised many times, I've finally implemented titles on my blog entries. I'm in the transitional stage at the moment - new posts will have them, old posts won't. At some point in the near future I'm going to trawl through the archives (all 938 entries) and add titles to everything. Once I've done that I can look at changing other stuff like the RSS feeds, and maybe even get around to re-implementing some kind of search engine. Then there's the new hierarchical category system, a whole bunch of accessibility improvements, better archives, comment email-alerts..."
939-0,"passage: Usage is simple: Work out the timestamp that the page content was last modified and call doConditionalGet($timestamp);. It will send the 304 header for you and exit if the client claims to have seen the content already - otherwise control will return to your main script and you can serve content as normal. Slightly inelegant, but it does the job."
939-1,passage: Update: I've changed the above code sample (and my implementation) to send the ETag header as ETag rather than etag.
939-2,passage: Unfortunately I don't have a Conditional-GET supporting RSS aggregator to hand so I have no idea if it works or not (so far I've only tested it by watching the headers sent with LiveHTTPHeaders). I'd be grateful if someone could confirm that this has had the desired effect.
939-3,"passage: This site's RSS feeds now support Conditional GET. Since the feeds are dynamically generated on every request, adding support took a bit of hacking around with PHP. Here's the function I came up with (based on the excellent description provided by Charles Miller in the article linked above):"
940-0,"passage: A suggestion: How about making the dictionary (already available in table form) available in some kind of easily parsable format (comma delimited, tab seperated or XML) so people constructing their own tools can use it instead of building their own?"
940-1,"passage: Bug report: While I didn't manage to catch it out with pre-marked-up acronyms, the XML) in the above wasn't converted."
940-2,"passage: Ian Lloyd has a very neat new tool on Accessify: Acrobot, an abbreviation and acronym generator. It takes a chunk of text and wraps any recognised abbreviations or acronyms in the appropriate tag, with the expanded term as the title (it can also optionally just use IE friendly acronyms). It shames me to say that after a good 6 months of using these tags I'm still doing them by hand, so Acrobot is just what I need (at least until I get something similar working in my blogging system). Registered Accessify members can expand the tool's dictionary, so maybe I'll have to bite the bullet and sign up for yet another web site account..."
941-0,"passage: Not only have they had a ""major investment"" from the firm run by Joi Ito, but they've just hired Anil Dash! More information on the Six Apart weblog. Exciting stuff."
941-1,"passage: Like its rival, Blogger, the new system will be stored along with the user's writing on a central server. This means that, for the first time, budding webloggers who want to use Movable Type - regarded as the one of the most powerful weblog-building systems - will not have to hire server space from hosting companies. Nor will they need to go through the sometimes difficult processes required to install the Movable Type system on their server."
941-2,"passage: SixApart, the company behind the Movable Type weblogging system, is to lanch a new ""hosted"" service called TypePad later this year."
941-3,"passage: Ben Hammersley reports on SixApart's (creators of Moveable Type) new venture, TypePad:"
942-0,"passage: The Python 2.2 Quick Reference, via Michael Twomey. All the essential bits of Python on a single (if quite long) HTML page. Magic."
943-0,"passage: Useful tip for web based tools for boring jobs: tabindex is your friend. I set it up so hitting tab would jump straight to the next item's title entry field (skipping the links in between) and the final tab would jump to the ""submit"" button at the bottom of the page. Not having to use the mouse at all definitely speeded up the process."
943-1,"passage: Next break from coursework, I think I'll have a go at improving the archives."
943-2,"passage: I've added titles to every single one of my archived blog entries; nearly a thousand of them. It took just over an hour, thanks mainly to my decision a long time ago to use camelCase for my permalinks. I put together a simple tool that displayed un-titled entries, ten at a time, with a suggested title based on the permalink (split in to words and sensibly capitalised). This probably knocked a good 75% off my workload."
944-0,passage: By jove I think they've cracked it: Show applicable styles from Stuart and List computed (cascaded) styles from Pixy. Talk about being spoiled for choice :)
945-0,"passage: MySQL 4.0 introduces far more powerful boolean mode full text searches which allow all kinds of modifiers and extra syntax, but this site currently runs on 3.23.54 so I can't play with those just yet. Jeremy Zawodny's article on MySQL 4 explains boolean mode and describes many other exciting new MySQL features as well."
945-1,"passage: I've finally got around to adding a search page to this site. It uses MySQL's full text indexing, which is extremely fast and provides good results but comes at the expense of flexibility. Search terms less than 4 letters long are ignored, and multi-word searches are handled using OR rather than AND. This nearly put me off using it, but the relevancy algorithm is excellent which I think outweighs the disadvantage of not being able to use pure AND queries."
946-0,"passage: I'm experimenting with using MySQL full text indexing to generate a list of ""related entries"" for each entry (click on an item's permalink to see it in action). It works by concatenating the item's title and entry body together and running a full text search on it, which sounds horendously inefficient but seems to work surpsingly quickly. If I decide to keep the feature I'll probably cache the results somewhere to reduce the overhead, but for the moment it's fast enough."
946-1,"passage: Update 2: It's back on again now, with caching. I'm still getting quite a few database timeouts for some reason - if they don't resolve themselves I'll have to do some more tweaking."
946-2,passage: Update: I've turned it off again - it was resulting in ugly database timeouts all over the place. I'll switch it back on once I've added caching.
947-0,"passage: Via Craig Saila, a method for getting IE to apply position: fixed without resorting to Javascript. It uses a conditional comment (slightly ugly but perfectly valid HTML) and works a treat. Kudos to Eric Bednarz for clearing up another of those niggling CSS problems."
948-0,"passage: Blogzilla has more information on the branding issue, which appears to have been resolved."
948-1,"passage: Word on the street is that Phoenix 0.6 (or Firebird or Mozilla Firebird or Mozilla Browser or whatever else you want to call it) could be out within the next week or so. I'm using the 28th April nightly build and it really is a big improvement on Phoenix 0.5, which is a very respectable browser in its own right. The new preferences panel (shown below) has been in the nightlies for quite a while now and really does add to the overall feel of the browser, and new features from Mozilla such as an editable about:config screen are handy as well."
949-0,"passage: I'm a sucker for new toys, so click here to add the simon.incutio.com search engine to your (Mozilla or Firebird) browser :)"
949-1,"passage: While browsing around my phoenix/ directory I spotted a sub-directory called searchplugins, which appears to control the list of search engines available in the very useful search box at the top right corner of the browser. A bit of digging later and it turns out that adding new search engines to Mozilla based browsers is remarkably easy: The Mozilla Search Project."
950-0,"passage: Via Craig Saila, Christopher Schmitt's 50 CSS Headings. Free CSS code snippets is definitely an idea who's time has come - there are hundreds of copy-and-paste javascript sites out there but hardly any for CSS (discounting the many excellent full layout sites). Mark Newhouse's extremely popular CSS Design: Taming Lists article does the same thing for lists but other than that this kind of resource is extremely rare. Web developers not interested in moving to CSS completely can still benefit hugely from using it in their current sites in place of nested formatting tables and presentational tags used to give the visual appearance of headings, so the more of this kind of thing out there the better."
951-0,"passage: The Python Tutorial now includes a new appendix on the limitations of floating point arithmetic. Via Simon Brunning, who also linked to the lengthier What Every Computer Scientist Should Know About Floating-Point Arithmetic almost exactly a year ago."
952-0,"passage: Tim Bray's ongoing really is one of the best technical blogs out there (if it even is a blog). One of his current topics is Unicode, which is one of those topics that pretty much every software developer should try to get under their belt. On the Goodness of Unicode gives a thorough, entertaining overview of the subject (including its importance and why it isn't as scary as it sounds) while Characters vs. Bytes is the first in a promised three part essay covering the technical details of modern character processing."
953-0,passage: Sterling Hughes: THOU SHALT NOT USE THREADS TO SERVE DYNAMIC CONTENT.
954-0,passage: SkillSwap is a voluntary group set up by members of the local web design community and specifically members of the Brighton New Media mailing list.
954-1,"passage: The idea is that on a semi-regular basis, people from the local new media community volunteer to give up some of their free time to train a small group of their peers in a subject that interests them."
954-2,"passage: It piqued my interest because it seems to be similar to the model we're hoping to achieve with our student computer society, BCSS."
954-3,"passage: Via Zeldman, Skill Swap is a community based new mania free training scheme based in Brighton:"
955-0,passage: XmlWriter.class.php
955-1,passage: Which produces this:
955-2,"passage: Lars Marius Garshol's XMLWriter class for Python struck me as a particularly elegant solution for generating simple XML documents without having to worry about encoding issues, missing tags and so forth - so I re-implemented it in PHP:"
955-3,passage: Example code:
956-0,"passage: Via Joe Gregorio, Functional programming in Python Part 1 and Part 2. I'm reading Structure and Interpretation of Computer Programs at the moment (available for free online, but I've got a library copy) and it has been getting me seriously interested in the functional programming paradigm. It's also by far the most enlightening (in terms of ""wow, that really makes sense"") computer science text book I've ever read. There's something naturally elegant about the functional style, probably thanks to the encapsulation encouraged by the lack of global variables and the extensive use of recursion in functional code examples. It's definitely true that exposure to a variety of programming styles encourages you to think about problems in different ways."
957-0,"passage: Why You Should Switch to the Mozilla Firebird by Ben Goodger is an excellent overview of Firebird's advantages over other browsers, hosted on the Phoenix project site. I'm really looking forward to the release of 0.6 as a good, stable, easy to use browser I can recommend to non-geeky friends."
958-0,"passage: Feedster finally supports AND as the default search operator. This is a very good thing. I've decided to leave this site's search engine as using OR, mainly because I feel for a small search set (approximately a thousand entries) more search results is better than fewer search results and because relevancy algorithm used by MySQL to order the results appears to be working extremely well. For large data sets such as Feedster or Google I definitely prefer to only see results containing all of my search terms."
959-0,"passage: XUL: rendering GUIs with PHP and XUL to PHP-GTK, both on the excellent phpPatterns(). If you're using a Gecko-based browser be sure to check out the XUL Interface to phpPatterns() proof-of-concept, which adds an XUL powered menu bar to the browser chrome at the top of the page."
960-0,"passage: Via Tim Bray, it turns out Apple's new iTunes Music Store is driven under the hood by a whole load of XML documents, which are available via HTTP. Here's hoping this leads to something similar to the Amazon Web Services API."
961-0,"passage: And now some clarification. The core issue I am interested in isn't CSS vs Tables, it's structural vs presentational markup. To clarify those terms, presentational markup is when you use HTML markup tags purely to control the ""look"" of your site in desktop browsers, while structural markup is when you use tags to provide a logical structure to a document and keep visual display information separate, generally through use of a stylesheet. The two are not mutually exclusive; for practical reasons, it is often necessary to add markup to a document for purely presentational reasons. The trick is to minimise this as much as possible."
961-1,passage: Update 2: I've delayed the planned start of my CSS tutorial series by a week or two.
961-2,"passage: Update: Having re-read the above it doesn't quite say what I wanted it to. My key point was going to be that CSS may not be perfect, and it may not yet be a complete replacement for presentational markup, but it's an ultra-powerful tool that is ready to be used now and should have a place in any web professional's toolbox. The promise of a tutorial series still stands."
961-3,"passage: I've been somewhat taken by surprise by the latest round of anti-CSS rants (initiated by JWZ, followups all over the place), mainly because I've been using CSS for long enough now that I'd started to forget about the legions of web developers out there who haven't yet realised what they're missing. Instead of getting stuck in to dissecting other people's complaints I'm just going to lay down a few of my own core beliefs."
961-4,"passage: Enough ranting: I'm going to put my money where my mouth is. Over the next few weeks I will give this blog over to a complete course in structural HTML and CSS, aimed at web developers who know their way around HTML but haven't yet come to terms with CSS - kind of like Dive Into Accessibility with a different focus. I haven't planned this, so I have no idea how long it will take or exactly what it will cover. I'm hoping it will lead to some lively discussions and help drag a few more web developers out of the 90s."
961-5,"passage: Why is separating structure from presentation a good idea? From a theoretical point of view, the answer should be obvious: separating the two adds a powerful additional layer of abstraction which allows either to be modified without needing to make changes to the other. The practical benefits come in the form of increased accessibility, better maintainability and greatly reduced amounts of code (compare the size of a presentational HTML page to that of one that uses structural markup and CSS). Being able to change the look of a whole site by modifying a single CSS file is Finally, the ability to re-use content is greatly increased as the clean structure makes it far easier for content to be remoulded for other distribution mediums."
961-6,"passage: It is true that there are some things (in particular relating to layout) that cannot yet be reliably achieved using CSS rather than presentational tables, almost entirely due to bugs in modern browser implementations of CSS. It is also true that there are a lot of layout effects that cannot be achieved using purely presentational markup. All web designers should be aware that they are working within the limitations of their medium - if you want pixel perfect control of how something appears then go and play with Flash (and throw universal access to content to the wind). Alternatively, the ""transitional"" approach where presentational markup is used only when there is no other alternative) is a perfectly valid way approach to modern web design."
962-0,"passage: In Strong Typing vs. Strong Testing, Bruce Eckel reconsiders the old idea that languages without strong typing can't be relied on to create large programs:"
962-1,"passage: Incidentally, Bruce recently added an RSS feed."
962-2,"passage: This became a puzzle to me: if strong static type checking is so important, why are people able to build big, complex Python programs (with much shorter time and effort than the strong static counterparts) without the disaster that I was so sure would ensue?"
962-3,"passage: His conclusion is that type checking by the compiler does not garauntee the correctness of a program in the first place; it's just another test. Comprehensive unit testing can more than compensate for the lack of type checking in languages such as Python, especially since the huge productivity bonus provided by Python allows more tests to be written starting at an earlier stage in development."
963-0,"passage: Via the WaSP blog (I wish they would ping Weblogs.com), How to achieve web standards and quality on your web site and List of valid DTDs you can use in your document, both by the W3C QA team. The former includes a great selection of questions and answers to typical reasons for not using standards (as well as some great tips on how to create standard compliant sites) while the latter finally provides all of the DTDs in one place."
964-0,"passage: Better structural markup rants than mine: Owen Briggs' classic Design Rant and Craig Saila's Tables or CSS? Choosing a Layout. Incidentally, my rant has sparked some excellent feedback in the comments section."
965-0,"passage: I've been getting more database timeout errors today, probably due to increased traffic from links to recent entries. A permanent solution would be to switch to generating static HTML (this site is currently dynamically generated for every request), but I don't have time for a full re-write at the moment. Luckily, PHP offers an extremely simple solution to dynamic caching in the form of output buffering. The front page of the site (which generates by far the most traffic) is now served from a cached copy if it has been cached within the last 5 minutes. Best of all, I didn't have to edit any of my core application logic - I just dropped in some extra code at the top and bottom of the index.php file. Here's how it works:"
965-1,"passage: I've added a few extra bits of logic to check that the page being cached isn't itself a database error page, but the above is the bulk of the code. Best of all, due to the nature of output buffering it should work on practically any PHP application."
966-0,"passage: The results are depressing, but not necessarily surprising. Only one site passed all three tests - beandizzy. Of the others, most fell at the first hurdle with only 13 getting as far as the third test."
966-1,"passage: In The XHTML 100, Evan Goer describes an experiment in which he checked 119 site claiming to be with an XHTML doctype for full compliance with the W3C standards. His test consisted of three parts - a validation check on the front page, a check on another ""inside"" page, and a check to see if the correct Content-Type header (application/xhtml+xml) was served to supporting User Agents (in his case Mozilla 1.3)."
966-2,"passage: I've been cautious about recommending XHTML for several months now, and this turn of events has made me even more wary of it as a technology that is ready for mainstream use. Creating valid XHTML documents is extremely difficult - virtually impossible by hand without regular checks with the validator, and hard to achieve using home grown tools as well. I plan to revise my Validator Web Service code shortly to help run automated validation checks whenver I update, but it's going to take quite a lot of effort to keep things working as they should."
966-3,"passage: So why bother when HTML 4.01 Strict gives all of the benefits of structural, valid markup with none of the additional hassles provided by XHTML? 6 months ago I would have said that XHTML is vital to support new light weight devices that can only handle an XML parser, but with mobile phones carrying full tag-soup capable web browsers that's looking more and more unlikely. The greatest benefit provided by valid XHTML is the increased ability to automate the extraction and processing of content at a later date (see Mark Pilgrim's acclaimed acronym and citation support for a concrete demonstration of this idea). I've been storing my blog entries as XHTML since I started blogging, and I maintain a firm belief that XHTML is an excellent format for storing items of content. Sadly, it just doesn't seem practical or worthwhile to serve it to browsers."
966-4,"passage: I'm going to keep serving this blog as XHTML as an open experiment in the practicalities and challenges involved in doing so, but from now on my other web projects will target HTML 4.01 Strict."
966-5,"passage: I don't know if my site was included in the experiment, but if it was it failed at the third test as well. I have now implemented Mark Pilgrim's trivial PHP fix (which serves the correct Content-Type to user agents that include application/xhtml+xml in their HTTP-ACCEPT header). This is no small step to take - serving XHTML with the correct Content-Type causes Gecko based browsers to attempt to parse it using a real XML parser, and should it turn out to be well formed they will refuse to render the site and die with an error message. Since I use Phoenix myself and almost certainly visit this site more than anyone else I'm hoping I'll spot and fix any errors before anyone else runs in to them. Talk about living on a knife edge!"
967-0,passage: AndyEd on the Mozilla gestures project:
967-1,"passage:
We're actually on the cusp of a huge new release with awesome customization features including complete customization of rocker (mouse button) mappings.
"
967-2,passage: Sweet. Gestures is still the first thing I install when I set up Mozilla or Phoenix. Hopefully the configuration options in the new release will work with the latest nightly FireBird builds.
968-0,"passage: I still plan to go ahead with a CSS tutorial series, as promised. I'm delaying the start, partly to give myself time to work out a good structure for the series, but mainly because I have a shed load of coursework due in a week today that desperately needs my full attention."
969-0,"passage: This is something we've needed for a long time. The CSS Zen Garden demonstrates CSS as used by graphic designers, and is a truly beautiful sight to behold. It currently showcases 5 radically different designs all using exactly the same markup, and invites further contributions from other designers. Finally, a proper demonstration that standards compliant, accessible, CSS driven web sites do not have to be boring or ugly."
970-0,"passage: I'm all courseworked out. After 4 hours sleep on Saturday night, I got up at 8am, headed in to Uni and spent the next consecutive 57 hours in the Library doing coursework (grabbing a total of about two hours sleep during that time). It was, with hindsight, a very stupid thing to do but I take heart in the fact that I was not alone: At least 20 other people from my course were there for almost the same amount of time I was (see Richard and Andy)."
970-1,"passage: Anyway, I've spent the last 2 days catching up on sleep. I also took delivery of Grand Theft Auto: Vice City for PC this morning, a day before the official release date (thanks to Gameplay.co.uk). Unfortunately it refuses point blank to install on my aging PC, complaining of a CRC error. It works fine on my house mate Paul's though. Considering I still have a couple of small courseworks to go (not to mention exams) it's probably a good thing that I haven't got it working."
970-2,"passage: It would be easy to write this off as critical lazyness, but I've actually been working extremely hard on coursework for the past four weeks. The main problem was that one of our two grou courseworks involved implementing a personal organiser (calendar / todo list / notebook / address book) in PHP - just the kind of project that can take as long as you let it if your requirements are overly ambitious. As it was we didn't quite implement everything we wanted to, but the resulting system is good enough for me to have already started using it to organise myself a bit better. Ironically the first thing I used it for was co-ordinating the rest of my coursework."
971-0,passage: I guess what I'm trying to say is that over the past few weeks I've really learnt to appreciate the importance of accepting and studying a wide range of different languages and programming techniques. Just because anything can be written in a language (which should be true of any language that is Turing complete) doesn't mean there aren't more effective ways of solving a problem available if you look elsewhere.
971-1,"passage: One of the things I liked most about SICP was its constant theme that no one language is perfect for any one job, and there is no harm in defining new languages to fit new problem spaces. The Lisp / Scheme / Functional style of programming seems to revolve around building the language up towards the problem, rather than hacking at the problem until it has been expressed in the language."
971-2,"passage: This simple message is exactly the point put across in the classic text book Structure and Interpretation of Computer Programs, which I had to review as part of a recent coursework assignment on the Scheme programming language. The pragmatic programmers article goes on to discuss how todays most popular languages, C++ and Java, do a very bad job of helping to build abstractions: Typing public static void main (String[] args) is hardly the most intuitive way of defining the entry point of a program!"
971-3,passage: Abstraction is the key to success in designing and programming computer systems. Your favorite programming language should allow you to easily map an abstract problem domain onto the more constrained solution domain of data structures and logic.
971-4,"passage: Via the comments on Robert C. Martin's One per Pixel, I came across Sturgeon's Law from the Pragmatic Programmers: Ninety percent of everything is crap. The article has the following to say about software development:"
972-0,"passage: If you decide to have a play with PyMeld you may run in to the limitation that, because class is a reserved word in Python, you can't set the class of an element using the standard page.someElementID.class = ""something"" syntax. You can however achieve the same thing using Python's setattr built in function: setattr(page.someElementID, 'class', 'something'). That tip comes courtesy of the module's author who sorted it out for me within about 10 minutes of my email query."
972-1,passage: PyMeld is a concrete implementation of something I've been thinking about for months: A template system that takes an XHTML page as a template and manipulates it based on cloning and modifying elements within the template identified using their ID attribute. It's a very elegant solution that makes good use of Python's object overloading support to make manipulating templates as intuitive as possible. Maybe the same thing will be possible in PHP once the new overloading functions become part of the standard package.
973-0,"passage: No one appeared to notice, but the CSS2 Recommendation had its five year birthday on Monday the 12th of May. Maybe now people will stop writing it off as a new and unproven technology and start looking in to the benefits it can bring instead. Speaking of which, I've decided on the format for my CSS tutorial series and hope to kick things off with the first in the series tomorrow."
974-0,"passage: To start my series of tutorials, I'm going to go over some of the basics of CSS. This is the boring bit: if you already know the difference between rules, properties and selectors you may want to skip this entry."
974-1,"passage: The next most common selectors are those based on classes and IDs. A class is any string of numbers and letters, starting with a letter - for example, ""blogentry"", ""nav"", ""codeSample"", ""row2"". Classes can be assigned to any element within an HTML document using the class attribute. Multiple classes can be assigned to an element by placing a list of classes in the class attribute separated by spaces. For example:"
974-2,"passage: Classes can then be used as part of a selector, by appending a full-stop on to the front of the class name:"
974-3,"passage: Class selectors can include an element name as well, to limit the application of the rules to specific elements with the specified class:"
974-4,"passage: The above piece of CSS will change the colour of <div class=""blogentry"">, but will not affect <h3 class=""blogentry"">."
974-5,"passage: ID selectors affect elements with a specific id attribute. IDs are like classes in that they can be applied to any element, but unlike classes any specific ID can only be used once within any single document. Classes can be used as many times as you like. As a result, IDs should be used on page items that occur only once, such as a company logo that appears in the top left hand corner of a page. ID selectors consist of the ID with a # sign preprended on to it:"
974-6,"passage: The above example would position any element with id=""logo"" at the top left of the page, using absolute positioning (which I will cover in detail later in the course)."
974-7,"passage: As with class selectors, you can include the element name before the hash sign. This may seem unnecessary since only one item on any page can have a specific ID, but I find doing so helps make the resulting stylesheet more readable as it reminds me what type of element the ID is attached to."
974-8,"passage: With the basic selectors out of the way, the next most useful selector is the descendant selector. This consists of two or more selectors separated by spaces, and has the effect of matching things that match each of the selectors, going from first to last. For example, div#main a matches all links that occur inside <div id=""main"">, while div#nav ul.plain li would match all <li>s occuring inside a <ul class=""plain""> that itself occurs inside <div id=""nav"">. Descendant selectors are extremely powerful, and can often be used in place of a large number of class attributes. In general, if you find yourself using a class attribute on every one of a whole bunch of similar elements you may be able to replace them all with a class attribute on a containing element accompanied by a descendant selector in the stylesheet."
974-9,"passage: Now that you know what goes in a stylesheet, you need to know how to attach rules to an HTML document. There are two options: internal stylesheets, where the CSS is included at the top of the page, and external stylesheets, where the stylesheet is a separate file. External stylesheets are generally a better bet as they allow a single stylesheet to be shared across multiple pages (dramatically improving download times as the stylesheet can be downloaded once and then cached by the browser), but I will describe both methods here. Here is the code for an internal stylesheet:"
974-10,"passage: The CSS rules are placed within a <style> element within the head section of the document. The type=""text/css"" attribute specifies the stylesheet language being used (on the offchance that another stylesheet language is created some time in the future)."
974-11,"passage: For an external stylesheet, the CSS rules are saved in a file with a .css extension (the file extension is not ompulsory but the file should be served with a text/css content type header, and most web servers are configured to serve .css files using that content type). The HTML to link in an external stylesheet, again placed in the head section, is as follows:"
974-12,"passage: That's all the basic CSS I plan to cover; my next article will start on the core material of the course, which will be a set of case studies showing how existing sites using legacy markup can be dramatically improved through the addition of a little careful CSS."
974-13,"passage: The most basic form of selector, demonstrated above, is the element or type selector. It is written as the tag name of an HTML element and matches all elements of that type."
974-14,"passage: The selector part of a rule specifies which parts of the associated document the rule should be applied to. Selectors are always positioned at the start of a rule before the open curly brace. More than one selector can be specified for a single rule, in which case the selectors must be separated by commas:"
974-15,"passage: There are over 100 properties defined by the CSS2 specification, but they are generally quite straight forward and can be picked up as you go along. Selectors are also straight forward but their importance is often underestimated: in my opinion, understanding them thoroughly is critical to learning to use CSS effectively."
974-16,"passage: The meanings of the two declarations should be relatively self evident: color: navy (note the American spelling of ""color"") sets the colour of the text to navy blue, while border-bottom: 1px solid black; adds a 1 pixel wide solid black border to the bottom of the element. In fact, this is an example of a shorthand property which allows several properties to be set at once."
974-17,"passage: In the above, h1 is the selector; it specifies the parts of the HTML document that the rule should be applied to. In this case, it means ""all <h1> elements"". The curly braces mark the declaration block, with the two declarations separated by semi-colons. I've placed the declarations on different lines but this is purely a coding style thing: CSS ignores whitespace as a general rule."
974-18,passage: Here is an example of a rule:
974-19,"passage: The basic building block of a stylesheet is the rule. A rule is a statement applying one or more properties to one or more elements. The declaration of a rule is split in to two parts; the selector and the declaration block, which itself consists of declarations. Each declaration consists of a property and a value. Confused by the terminology yet? Don't worry, that's about as complicated as it gets, and I'll be providing a summary of definitions later on."
974-20,"passage: The above is the HTML for a div that has both ""blogentry"" and ""first"" as classes."
975-0,"passage: If you were curious enough to dig around the source code of yesterday's CSS tutorial, you may have noticed a couple of classes that didn't appear to be doing anything:"
975-1,"passage: Unfortunately, it relies on the non-standards compliant innerHTML property which causes it not to work in Mozilla in XML mode, so I can't deploy it on my blog at the moment. Due to the way the regular expressions work I'm not entirely sure how I can rectify this using standard DOM methods, so I'm leaving it as it is for the moment."
975-2,"passage: I added the classes in the hope that they would be useful some time in the future. This afternoon, the Internet connection in the University library stopped working so I decided to take the time to play with an idea I've been tossing around for a few weeks. The result: Javascript Syntax Highlighting. The concept is pretty simple - it grabs the code samples with css or html as the class, then uses regular expressions (along with some crafty callback functions) to add <span> elements to specific bits of code to allow them to be highlighted. It works in Firebird / Mozilla but fails pitifully in IE 5, which appears not to support callbacks from the string.replace() function. I haven't tried it in IE 6 yet."
976-0,"passage: There's a new nightly build of the Mozilla mouse gestures plugin which supports Firebird 0.6 and has a preferences panel, complete with options for setting up custom gestures. I missed the customise button at first (Tools -> Options -> Extensions -> Mouse Gestures -> Settings -> Edit Mappings) but it's very powerful, if slightly confusing. It's nice to be able to change gestures to the right mouse button without digging in to about:config as well."
977-0,passage: That's exactly why I find ezPyCrypto such an attractive class.
977-1,"passage: Low surface to volume ratio: Objects with complex interfaces that conceal few of their internals are hard to understand and reuse. Therefore, Design objects with low surface to volume ratios, that is, objects with small external interfaces, or surface areas, that encapsulate a large volume of internal complexity."
977-2,passage: The Selfish Class provides a set of related patterns to help design software objects that encourage reuse. They seem to make a lot of sense; I've only read a smal part of the paper and I'm already spotting things that are reflected in software I've found reusable in the past. Key example:
978-0,"passage: We're nearly finished - all that's left to do now is the permalinks at the end of each paragraph. We will use FIR again, but this time the background image we are using is far smaller than the # sign it is replacing so we can take a slightly different approach:"
978-1,"passage: That's the header finished - now for the paragraphs. The first thing to notice is that they are indented approximately 15 pixels on the left hand side. This can be easily emulated in CSS using either a margin or padding - I'll use padding, but margin would work just fine as well."
978-2,passage: And here's the result.
978-3,"passage: But what about the image? Here's where things get tricky. We're going to use a technique called the Fahrner Image Replacement. This is what the extra spans are for - we can apply a background image to the a element, then make the contents of the span invisible using display: none."
978-4,"passage: See the result here. So far, so good - but what about the funky permalink? It's an image, and it appears over on the right. Normally this would be a sign that we need a table, but we can achieve the same effect in CSS using the float property. Floats are actually one of the hardest properties to fully understand, but if you've ever used the align attribute on an image you should have a good idea of what they do. We will use float: right on the permalink to cause it to shfit as far right as possible, appearing next to the main header text."
978-5,"passage: Now let's concentrate on the header. The date header on Scripting.com has a black background with white text. The text is bold, and is displayed at the same size as the body text of the rest of the site. In CSS, relative sizes can be specified using the em unit. 1em means 1 times the current text size, so we'll set the font-size to 1em. Finally, the header is padded with about 3 pixels on every side. Here's the CSS:"
978-6,"passage: Now let's style it with some CSS. First up, Scripting.com's main layout table is 400 pixels wide. We can emulate that by applying a width to our <div>:"
978-7,"passage: Final note: this entry comes with apologies to Dave Winer of scripting.com, who has not been consulted prior to the publication of the article."
978-8,"passage: A few notes about the above. First, I've wrapped the whole entry in a div with the class ""entry"". This means I can use descendant selectors to style the other elements in the block qithout needing to add additional classes. The only classes I've added are the permalink classes on the various permalinks - these will be used in a moment. Note also that the '#' signs in the permalinks have a span tag around them. The reason for this will become apparent in a moment. The table used for the header has been replaced with a structural h2 tag. Header tags should be applied in order, with the most important header on the page using h1 and the other headers being used for sub headers, sub-sub headers and so on. I'm assuming that h1 would be used for the site title (or logo) so I'm using h2 in this example."
978-9,"passage: First, let's reduce the above to the equivalent structural HTML, removing all of the presentational tags and adding in a few that might be useful. We're also going to remove the images - they'll still be there in the final version, but by using background images defined in the CSS we can save quite a lot of code."
978-10,"passage: I've added some extra line breaks to fit all of the code in the space available, but other than that it's unmodified."
978-11,passage: The HTML behind the above screenshot is as follows:
978-12,passage: Scripting.com presents the main blog entries as a series of paragraphs under a single header for each day. Here is a screenshot from today's edition of the site:
978-13,"passage: One of the aims of this course is to show how relatively simple CSS can be used to make dramatic improvements to existing sites. Today, I'll show how CSS can be used to reduce the amount of code needed for a small part of the design of Scripting.com."
978-14,passage: The unstyled HTML can be seen here.
978-15,"passage: The end result can be seen here - viewed in a standards compliant browser (I tried it in Firebird, IE 5 and Opera 7) I think you'll agree it's an almost exact replica of the original, but with a great deal less markup. Times that saving by several dozen entries on a page and it really starts to add up."
978-16,passage: This time the permalink is made invisible using the visiblility property rather than being removed entirely - that way we don't have to worry about adding a width or height to the link. The background image is placed using a shorthand property which allows all of the background properties to be specified at once - it should be relatively clear what the property does.
979-0,passage: Here's what our redesign looks like now.
979-1,"passage: And finally, apologies to jwz for borrowing without asking. I hope I haven't caused offence."
979-2,"passage: For the next installment, I will be stepping back from hacks and unpleasantries and looking at CSS being used in a much simpler light: to visually enhance semantically structured page elements. I also have another case study planned which will make much lighter reading than this one. As always, comments are welcome."
979-3,"passage: In this tutorial I've tried to roll up my sleeves and get stuck in to the dirtier side of CSS development. I've demonstrated some hacks, and I've shown how there can be more to practical CSS than meets the eye. It may seem like an awful lot of work, but in fact the initial jwz remake took me just over half an hour thanks to my previous experience with IE5 bugs."
979-4,"passage: While most designs can be achieved in CSS, some are harder than others. This is not the fault of CSS; it is more a problem with faulty browser implementations of CSS. When people call IE5/Windows the ""new Netscape 4"", they are doing so with good reason! However, IE5's deficiencies are well understood with the CSS community and workarounds exist which, while initially tricky, for the most part work very well. With a bit of insider knowledge the beast can be tamed."
979-5,"passage: Which brings us to our final result: JWZ's blog entries in pure CSS. It took quite a bit of work, but I think the results speak for themselves."
979-6,"passage: Not quite. Like most text properties (such as the font-size property we were playing with earlier) text-align is inherited. If we center the text in our body, we end up centering it in all of our other elements as well. Luckily we can use text-align: left on the other elements in our document to prevent this from happening. Combine these three CSS tricks and you get the following method for centering elements in an IE5 friendly way:"
979-7,"passage: As luck would have it, we can now use another IE5 bug to our advantage. The text-align: center declaration, as you might expect, aligns text in the center of the element. IE5 incorrectly also applies the property to block level elements, which include our troublesome div. So we can set text-align: center on our body element and all is well...?"
979-8,"passage: The standard way of centering a block level element (for example a div or a paragraph) in CSS is to set the left and right margins of the paragraph to ""auto"". This can be achieved using the shorthand property explained above: margin: 0 auto;. Were it not for IE5, our troubles would be over. Unfortunately, IE5 fails to recognise this method."
979-9,passage: We're nearly there! All that remains is to center the div on the page. This is the point where our second IE5/Windows bug rears it's ugly head...
979-10,"passage: Note that both paragraphs have a margin explicitly set - this is important as we need to over-ride the margin set on all paragraphs within div.entry earlier on. This is also related to the reason the full div.entry p.comments selector is used instead of just p.comments - if you want to know the full reason for this, look up the CSS specificity rules which are outside the scope of this article."
979-11,"passage: The styles for the comments section at the bottom (complete with dark green background) and the music section at the top of the entry should be pretty self explanatory, so I'll provide them here without further analysis:"
979-12,"passage: Here we are using another CSS shorthand. Both padding and margin properties can be set with one, two, three or four properties. If only one is provided, it is applied to all four sides. If two are provided (as in this example) the first is applied to top and bottom and the second to left and right. If four are provided, they apply to Top, Right, Bottom, Left respectively (a good mnemonic for this is TRouBLe, which I picked up from Eric Meyer). Behaviour for three properties is defined but it's quite complicated so I recommend avoiding it entirely. The upshot of all this is that the above rule adds a 1em margin to the top and bottom of each paragraph and 5 pixels to either side. You'd be forgiven for thinking that this means margins would be spaced 2 ems apart, but in fact the margins on elements on top of each other collapse to fill the space of just one. I'll talk about this more when I cover the box model in detail."
979-13,passage: That's quite a substantial reduction in markup. Here's what it looks like. The challenge now is to make it look like it does in the picture.
979-14,"passage: That's three tables for every entry on the page. If we trim it down to basic structural HTML, we get the following:"
979-15,passage: And here's the original HTML (I've added some newlines but other than that it's as seen on the page):
979-16,"passage: Here's the ""before"" screenshot:"
979-17,"passage: Today's CSS case study will be Jamie Zawinski's LiveJournal. OK, I admit that he's something of a tempting target after his widely publicised CSS rant last month (which was the main inspiration for this course), but there are a number of sensible reasons his site makes a good case study as well. The theme for today is ""bugs in IE5 for Windows"", and jwz's site offers two classic examples that fit this theme nicely. The first is the fact that the design is centered on the page, and the second is his choice of Verdana, a font which requires some trickery to get working well in IE5. In addition, the design of the entries seems to be a natural fit for a table based layout, so demonstrating how much simpler the code can be in CSS will hopefully turn a few heads."
979-18,"passage: Space between the border and the text can be added in a number of ways: as padding within the entry, as a margin on the paragraphs or as padding on the paragraphs. Since we have set a width on the entry it's a good idea to avoid adding padding to this as this can result in IE5 misbehaving (a box model problem, which could be solved by the box model hack but why hack when you can possibly avoid it?). Instead we will set a margin on the paragraphs:"
979-19,"passage: We are using a:link as the selector rather than just a on its own, because a will match all <a> elements including those that are just being used as a link target. There aren't any on the page, but it's a good idea to get in to the practise of using a:link to style links anyway. a:visited applies styles to visited links. The :something syntax is called a pseudo-selector. It's also worth noting an accessibility point here: it's generally a very bad idea to set links apart from normal text by colour alone, so text-decoration: none should be discouraged unless some other non-colour based visual indicator is also specified. I'm ignoring that for this example in order to comply with the original design."
979-20,"passage: There are two glaring problems with what we now have. Firstly, there is no space between the borders and the text. Secondly, the link colours aren't as they should be. We can lift the link colours straight from the attributefs on the body tag in the original site:"
979-21,passage: I've specified the background-color again because it is good practise to always set a background colour at the same time as you set the colour of an element. This helps ensure you never accidentally end up with unreadable text that is the same colour as its background.
979-22,"passage: The date for each entry appears alongside the title, on the right hand side. As we saw last time, this can be achieved with a float. I'll also set the font size to 0.85em (again found using trial and error) and add some padding to ensure the date appears inline with the heading:"
979-23,"passage: The entry title is a critical part of the design. We have used an h2, but we need to style this with a green background and correctly sized black text. Headers always come with a default margin above and below the header, but since we are using the background colour of the element as part of the design we need to eliminate this by specifically setting the margins around the element to 0. We also need some padding to give the text inside the element some space - trial and error leads us to set this at 5 pixels:"
979-24,"passage: Now that text sizing is out of the way, we can get on with styling the entry itself. First, let's look at the div surrounding each entry. Firstly, it needs to be 600 pixels wide to match the width of the table in the original. The original design has a 2 pixel wide line around the edge of the table, and we can replicate this using a CSS border. Borders in CSS can be applied to the top, left, right and/or bottom of an element in any colour, any thickness and a number of different styles: they are a very powerful tool. In this case we just need a 2 pixel wide green border around the whole div. Here's the CSS:"
979-25,"passage: Ugly, isn't it? The way it works is explained elsewhere, but believe it or not the above code will kick IE5 in to line with the rest of the mainstream browsing world. Here's how it looks. Let's move on."
979-26,"passage: The hack I shall be using here is the famous Box Model Hack by Tantek Celik. Originally devised to get around a serious flaw in IE's implementation of the box model (to be covered later in the course), the box model hack allows a CSS author to feed one value to IE5 and another to better, more standards compliant browsers. We want to give IE5 x-small and everything else small, and here's the code we are going to use:"
979-27,"passage: Hacks are something of a controversial issue within the CSS community. Some people see them as an anathema to everything that CSS is meant to represent, while others (myself included) see them as a slightly unpleasant tool that can help achieve a practical end. Since the focus of this tutorial is on the practical applications of CSS, I'll leave discussions of the validity of hacks to the css-discuss wiki."
979-28,"passage: This is where the IE5 bug comes in. Most browsers (including IE6 in standards mode, all Gecko engine browsers and Opera 7) display Verdana at the size I prefer if you specify font-size: small. IE5 for Windows on the other hand requires font-size: x-small. Since IE5 still has a relatively large market share, it's important to get things looking good in that browser, no matter how irritating it's support of CSS. It's time to apply a hack..."
979-29,"passage: No matter which font sizing technique you use, it is widely recognised that the best way of dealing with font sizes is to set a single basic font size on the body and then size other text on the page relative to that initial size using ems (described briefly last tutorial) or percentages. Personally, I like to use a font such as Georgia which looks good at the default browser size setting and avoid the whole issue of setting an initial size, but as we have already discussed if you are using Verdana this is pretty much out of the question. When forced to resize the default font, my favoured method is to use the font-size keywords small and x-small."
979-30,"passage: CSS provides a truly huge range of font sizing options, and each and every one of them carries its own set of flaws and limitations thanks to differences in implementation between the many CSS supporting browsers. A good resource for understanding the scope of this problem is Owen Brigg's excellent Text Sizing article, which includes 274 screenshots of different font sizing techniques in different environments. To cut a long story short, the only reliable cross browser sizing method is to specify the size of the font in pixels. This comes with one massive drawback: doing so will prevent IE users from resizing the text in their browsers. If you care at all about accessibility you'll know why this is a bad idea."
979-31,"passage: Now it's time to tackle our first IE5/Windows specific bug. Verdana is an extremely popular font among web designers, but suffers from the unfortunate problem that it is sinfully ugly when displayed at the browser's default text size. Knock it down just one size and it becomes a great deal pretty, while remaining completely readable. As a result, if we want to use Verdana we really need to make it smaller."
979-32,"passage: Note that while the original site uses #000000 and #00FF00 as hexadecimal colour attributes on the body tag, I have used #000 and
#0f0. Since many common colours can be represented using three pairs of hexadecimal digits, CSS allows you to use three instead of six and will ""double"" each digit in its place. color: #00ff00; would have exactly the same effect."
979-33,"passage: First, let's set a few basic rules. JWZ's site has green text on a black background, both of which should be set as rules on the document body (they could be set on individual elements but since they apply to the whole document it's best to define them higher up):"
980-0,passage: Here's the relevant CSS:
980-1,"passage: The padding is applied to the <div> rather than the <blockquote> because the <div> needs to stretch the entire width of the <blockquote> in order for the background image to appear in the right place. The images are 38 pixels wide, so a padding is applied to the left and right hand sides of the <div> to allow space for the images and give an extra 10 pixels of whitespace."
980-2,"passage: You can see the technique being used on this sample page, or over on Nick's weblog."
980-3,passage: Here's the HTML:
980-4,"passage: Today's tutorial is going to be short one, as I'm working on one last piece of coursework. This time I'm going to explain a clever CSS trick borrowed from Nick Boalch. Here's a screenshot:"
980-5,passage: The <div> in the above code is a slight sticking point: it has no structural value but is required for the technique to work. This is a trade off between 100% structural purity and presentational effects but I think it is one that is worth making.
980-6,"passage: There's a simple trick at work here. CSS backgrounds are extremely powerful but in CSS2 only one background can be applied to any single element. The blockquote effect requires two background images, one for the quote mark on the left hand side and one for the one on the right. The additional nested <div> allows us to do this, by applying one background image to the <blockquote> and one to the <div>."
980-7,"passage: Incidentally, I've been getting some absolutely fantastic feedback on this series on the comments attached to each entry - please keep it coming! The feedback has included a number of suggested improvements and other worthwhile tips. Rather than editing the original articles I plan to use tomorrow's update to revisit the previous day's articles and update them based on suggestions from the comments."
980-8,"passage: One final note: while it's tempting to add font-style: italic to blockquotes, doing so may cause a horizontal scrollbar to appear in IE6/Windows. Strange but true."
981-0,"passage: Programming by Contract seems to be a sister technique to unit testing - instead of (or as well as) writing a set of tests for a piece of code you write a set of pre- and post-conditions for the data being processed which are then checked whenever the program is run in debugging mode. Contracts for Python discusses the technique, providing a reference implementation and a PEP suggesting inclusion of support for the technique in the core language. Programming by contract was first demonstrated in the Eiffel language, and there's a good introduction to it in Eiffel.com as well."
982-0,"passage: If the 309 buttons at Steal these buttons aren't enough for you, you can now generate your own thanks to a clever PHP script on Minimal Verbosity. Bill Zeller has made the source code available as well."
983-0,"passage: Mark Lutz has announced that he is working on a second edition of Learning Python. The first edition of Learning Python is probably the best learn-programming-language-X title I have ever read. It's nice and short, but covers the whole core Python language comprehensively with excellent examples and a well targetted learning curve. I've lent my copy to several people, all of whom found it very helpful and one of whom went on to buy a copy themselves. I'll probably be buying a copy of the second edition just so I can use it on my constant mission to get more people on my course to give Python a go."
984-0,"passage: I've decided it's time to start actively pushing for the browser makers to fix some really annoying CSS bugs. In day-to-day development, I find myself continually creating clumsy workarounds because a browser doesn't support five-year-old standards. Already I've filed some with Opera, and Mozilla, and am now pushing on Internet Explorer.
"
984-1,"passage: Craig includes the 5 key problems with Internet Explorer 6's CSS support and suggests you join him in submitting feedback to Microsoft requesting they hurry up and add them. The sooner they fix them the better, as it'll probably be another few years from then before IE 5 and 6 lose enough market share for these features to be usable in the wild."
984-2,passage: Craig Saila: Browser bug swatting:
985-0,"passage: My CSS tutorial series has been getting some fantastic feedback, both in this blog's comments system and elsewhere. This entry will summarise the most useful feedback, acting as a kind of errata to the previous entries. Thanks to everyone who commented, there are too many to credit individually but you can see most of the points in their original format by browsing the comments attached to each entry."
985-1,"passage: This entry drew the greatest criticism for its extensive use of the Fahrner Image Replacement technique, which can cause accessibility problems and also has some browser compatibility problems. In particular, the purple permalink icons were not showing up in IE5/Mac, probably because the technique was being applied to an inline rather than a block-level element. I have prepared two alternative examples of the Scripting.com remake, one using a permalink image and one that uses CSS to style the '#' sign to appear small and purple: Scripting.com with inline image permalinks, Scripting.com with styled purple hashes."
985-2,"passage: Most of the comments here involved alternative ways of applying the selectors, all of which are worth reading about but none of which are practical due to poor browser support. I recommend reading them anyway, as they give a good indication of how much cleaner CSS will be once Microsoft get their act together."
986-0,"passage: As you can see from the diagram, the box model deals with the width, margin, padding and border around an element. You can specify a width using the width property; width can be specified in pixels, ems or percentages (and other units as well but these are the most common) and applies to the area on the diagram labelled ""content area"". It should be noted that the overall width of the box up to the borders (the dark grey area on the diagram) is actually the width, plus the left padding, plus the right padding, plus the width of the left and right borders."
986-1,"passage: Before discussing the box model, it is important to understand the difference between inline and block level elements. Inline elements are things like links, <em>s and <span>s - any element that appears ""inline"" in a piece of text without inserting any newlines. Block level elements on the other hand always start on a new line and cause any content following them to start on a new line as well. They include things like <p>, <div> and the various header tags. Block level elements can contain both block level and inline elements, but inline elements can only contain other inline elements. An inline element can be ""promoted"" to behave like a block level element using the display: block; property, and the reverse can be achieved using display: inline; - note however that doing this does not change the rules about what kind of elements something can contain. The box model principally applies to block level elements (although some of it works with inline elements as well)."
986-2,"passage: An important thing to understand is the difference between margin and padding. Obviously padding occurs inside the border and margin outside, but surely this means that either can be used to the same effect if no border is required. This is more or less true, but comes with a few caveats. Firstly, the area treated by elements nested within an element as the ""width"" of the element is the content area plus the padding - this becomes important later on when we start to look at positioning. Secondly, top and bottom margins have a special effect applied to them called margin collapse. Put simply, when two elements are positioned above and below each other the gap between them is the size of the largest margin, NOT the size of the combined margins. This becomes important when considering margins on paragraphs, where specifying a margin of 1em means you get a 1em gap between each paragraph, rather than 2ems due to the margins being added together."
986-3,"passage: Margins, borders and padding can be set separately for each side, or set all at once using shorthand properties."
986-4,"passage: It is here that IE5 gets things wrong: in IE5, the width property applies to the width AND the padding AND the border. There are two solutions to this problem. The first is to use Tantek's box model hack to feed alternative width values to IE5 (we have used this previously to improve IE5's rendering of Verdana). The second is to avoid setting any padding or thick borders on blocks that have a width declared, instead relying on the margin of elements contained within that block to add the illusion of padding. Which technique you use it up to you."
986-5,"passage: Today's tutorial is going to be all theory. The box model is an inevitable part of CSS, and understanding it is critical if you want to do anything remotely interesting. Like most of CSS, it's a lot simpler than it sounds. Here it is:"
987-0,"passage: How about horizontal navigation? That can be achieved in a similar fashion, using the float property to position the links next to each other:"
987-1,"passage: Yesterday we talked about the box model. Today we're going to put a small part of it to work, by investigating ways of styling links. Before getting stuck in, we need to talk a bit about pseudo-selectors (also known as pseudo classes). The CSS specification defines pseudo classes as ""characteristics that cannot be deduced from the document tree"", but in practise the only widely implemented psuedo selectors are those that apply to links. The key psuedo selectors for links are:"
987-2,"passage: Check out the result here. Now that the links are floated it is important they have an explicit width assigned to them. A margin-right is used to place a gap between the links. There is one caveat to this method: It is important that any following element (preferably one that spans the whole page) as clear: both; applied to it, or any text in that element will flow around the menu rather than appearing below it. This is one of the most common upsets caused by using floats, and exactly the thing the clear property is designed to solve."
987-3,passage: There is one problem with the technique described so far: accessibility. If you run the above examples through any accessibility checker they will flag up a warning that the links in the examples are seperated only by whitespace. Try disabling CSS or viewing the examples in a non-CSS browser and you'll see that this could definitely cause confusion - the links are displayed on a single line with only a single space between each one. A solution is at hand in the form of the humble <span> element accompanied by the display: none property:
987-4,passage: Here's a demonstration of the above. Note that it's identical to the previous example in CSS browsers; the separating pipes only show up when the CSS is not applied.
987-5,"passage: After yesterday's discussion of the box model, it seems we would be able to achieve a lot more with this effect if links were block level elements. We can use the display: block; property to ""promote"" a link to block level status, which allows us to achieve all kinds of groovy effects. Consider the following HTML:"
987-6,"passage: Left to its own devices, this would display as a rather uninteresting line of links. Add some CSS and we can make it look much more interesting:"
987-7,"passage: A few things to note. Most importantly, the links inside the div are set to display: block. This causes them to ""stack up"" on top of each other, and also causes them to expand to be as wide as their containing box (which is why we have restricted its width to 5 ems). The menu border is set to 1px all the way round, but then the bottom border is turned off. This means that when we set a bottom border on the links themselves the very bottom link does not end up with a double border. The result of the above can be seen here."
987-8,"passage: It is the last of these that we shall be focusing on. One of the first and most popular effects that emerged when Javascript became popular was the image rollover, where an image (generally used as part of a site's navigation) would change when the mouse was positioned over it. a:hover allows us to achieve a similar effect using just CSS. The most striking change is to alter the background colour, as shown in this example."
988-0,"passage: Golden Mean is Doug Bowman's first contribution to the CSS Zen Garden, and it's a very nice piece of work. Even better is the fact that Doug has provided extensive coverage of the design process (including technical CSS details) on his blog."
989-0,passage: My infrequent updates can be blamed on two things: revision for exams (three next week) and Grand Theft Auto: Vice City. One of these two has been taking up far more time than it should...
990-0,"passage: My mouse stopped working a couple of days ago. This hasn't ben as big a problem as you might have thought, mainly because Vice City refuses to install on my PC so I've been playing it on a housemates instead ;) Surfing the 'net mouseless has however given me an interesting insight in to a number of accessibility issues."
990-1,"passage: Incidentally, HTML Techniques for Web Content Accessibility Guidelines 1.0, despite being something of a mouthful, is a fantastic document if you are at all interested in web accessibility. It's full of useful tips for making content more accessible, including code examples for the impatient. As with all W3C documents you need to scroll past the extensive preamble and table of contents before you get to the juicy bits."
990-2,"passage: If more than one link on a page shares the same link text, all those links should point to the same resource. Such consistency will help page design as well as accessibility."
990-3,"passage: Finally, Typeahead Find in Mozilla and Firebird is an absolute God-send. With it I can surf keyboardless at pretty much the same speed as I can with a mouse, provided of course I don't run in to any Flash. The only time it slips up a bit is on sites that use the same text for multiple links (for example the Comments links on this site), but even then it's easy enough to cycle through them using F3. This is supported by this tip from the WAI:"
990-4,"passage: Secondly, Windows is a lot more obviously accessible to keyboard users than Gnome on Linux, thanks mainly to the Windows key providing access to the start menu. If anyone can tell me a way of accessing the launch menus in Gnome using only the keyboard I would be very grateful."
990-5,"passage: Firstly, Flash just isn't accessible! I haven't found a single Flash site that I could even start to use without a mouse (most of the time I got stuck at a splash screen). Maybe if sites were built with Flash MX and used the much touted accessibility features I would have been able to navigate them, but as it was anything in Flash became utterly inaccessible to me."
991-0,"passage: Tom Gilder: ""I did this in HTML, how do I do it in CSS?"". A collection of tips for replicating visual formatting effects in old-style HTML with their CSS equivalents. A good resource for people just getting started with CSS."
992-0,"passage: Now give them a go. They're all useful, but by far the most useful for learning CSS are test styles and edit styles. test styles opens a popup window in which you can type CSS rules that will be applied instantly to the page you are viewing, while edit styles does the same thing but pre-populates the window with the style sheets of the current site, allowing you to edit them in place. ancestors is also useful; it shows the element hierarchy of the element your mouse is currently over, which can help you see what selector you need to use to modify that element's style. I cannot emphasize enough how powerful this is for working with CSS; using test styles I was able to redesign this site entirely in less than half an hour!"
992-1,"passage: All of the above bookmarklets were written by Jesse Ruderman. Jesse has many more bookmarklets, all of which are available on his site. The bookmarklets listed above are from his Web Development collection (which includes further descriptions of these and many others). Jesse's bookmarklets have saved me countless hours of development time, and I hope they can do the same for you."
992-2,"passage: I'm in the middle of a whole bunch of exams at the moment, but here's a quick tip that should make experimenting with and learning CSS a great deal easier. It involves bookmarklets. If you haven't seen them before, bookmarklets are bookmarks that embed javascript; when you click the bookmark, the javascript is executed in the context of the currently loaded page. What that means is that in a suitably advanced browser bookmarklets can be used to modify pages, analyse their structure and do a whole host of other useful things."
992-3,"passage: A fair number of bookmarklets work in both IE and Gecko engine browsers, but the really interesting ones (at least as far as learning CSS is concerned) tend to be Gecko only. If you're serious about learning CSS it's well worth getting a Gecko browser at any rate - Gecko's CSS support is more standards compliant than anything else currently available, so I recommend designing for the standards with Gecko and tweaking to support IE afterwards. Some people advocate designing for IE because it has buggier support, but once you've seen the tools available for Gecko I think you'll agree it really is a superb development platform. If you don't have access to a Gecko engine browser (that means Mozilla, Netscape 7, Camino, or Phoenix/Firebird) go and grab Firebird - it's only a 6 MB download and is available for most major platforms."
992-4,"passage: Now that you're tooled up with a good browser, drag the following links on to your links toolbar or add them as bookmarks:"
993-0,"passage: Exams are all over and I've had a few days of doing nothing to recuperate. I've also made a couple of small improvements to my blog. Firstly I've finally updated the comment system (after numerous vocal complaints) to provide a preview option and redisplay the form in the case of invalid markup. I've also changed the monthly archive pages to display the titles of all of the posts from that month instead of just showing which days had entries. In my experience date based navigation is the least useful way of finding old content in a blog (search, categories and related reading are far more valuable) but the new way of presenting monthly archives at least gives an overall view of the topics I was posting about over a particular time period."
994-0,"passage: Authenticating users through a third party POP3 server (Python sample code provided) is a really interesting idea, but one that I don't think could ever be used in the wild. Firstly, I haven't the slightest idea what my POP3 password is as I tend to save it in my mail application and forget about it. Secondly (and more importantly) is trust: how many web sites do I trust enough to give them my email password whenever I log in?"
994-1,"passage: That said, the author of the code snippet lists these and other weaknesses and seems to be suggesting that it would be best used in an intranet style environment, where it would allow web applications to authenticate using the company mail server thus avoiding administrators having to maintain multiple databases of user accounts."
995-0,"passage: The interview site makes interesting use of a style switcher combined with the Fahrner Image Replacement technique to provide an alternative ""image free"" version."
995-1,"passage: Under the Iron is a series of interviews with interesting people. The most recent three include one with Mark Pilgrim, which talks in part about Mark's reasons for creating diveintoaccessibility:"
995-2,"passage:
I laugh when I hear people say ""I can't retrofit my web site, it's too expensive!"" Hey, you want retrofitting? People are tearing down walls and excavating and so forth to provide ramps, and wider aisles, and all sorts of other concessions to people with disabilities out in the real world. Don't tell me you can't afford to add a few extra tags. I mean, they're tags! Not even difficult ones. Here, I'll show you...
"
996-0,"passage: Eric Meyer has released a new selection of designs over on Meyerweb. The designs are inspiring, and Eric's CSS is well worth perusing for style tips and insights in to reliable methods of creating relatively complex layouts."
997-0,"passage: Peter Van Djick: The structure of content and metadata, a glossary style overview of important concepts in structured content and website metadata. Peter also links to Victor Lombardi's excellent Metadata Glossary."
998-0,"passage: Mark Pilgrim highlights the severe security issues introduced by RSS aggregators that display potentially unsafe HTML, often executing it in the ""secure zone"" generally reserved for trusted local documents. Mark suggests a number of dangerous tags and attributes that should be removed before display. Unsurprisingly, regular expressions have cropped up in the comments as the suggested solution. Jamie Zawinsky famously once posted the following to comp.lang.emacs:"
998-1,"passage: At any rate, the parser you use had better be as foriving as IE or it could miss out on damaging code. The easiest option is to strip HTML entirely, but doing so means greatly reducing the usefulness of the content that comes in through the aggregator. Alternatively, strip all but the bare essentials and use some heavy handed techniques to eliminate anything that could possibly be damaging. The latter approach could conceivably be achieved using regular expressions but would require some serious testing to stop up any leaks."
998-2,"passage:
Some people, when confronted with a problem, think ""I know, I'll use regular expressions."" Now they have two problems.
"
998-3,"passage: In this case, the above quote is particularly relevant. Parsing simple HTML with regular expressions is unpleasant but possible, but attempting to securely filter potentially malicious HTML (while trying to keep the useful tags) can only lead to more problems. There are just too many possible combinations, thanks mainly to the huge flexibility provided by modern browsers. Attributes can be left unquoted, tags can be left unclosed, characters can be incorrectly escaped; it all adds up to far more variables than even the most comprehensive regexps can hope to match. Combine this with the fact that Internet Explorer for Windows has not only the most forgiving parser but also the most unpatched security holes and you're looking at a very big problem."
998-4,passage: The solution is to use a real HTML parser. Python users have the excellent sgmllib (although I'm not sure how robust it is when faced with truly unpleasant HTML) but other developers are not so lucky - I'm sure CPAN has some good solutions for Perl but if you're stuck with PHP your best bet is probably something based on REX.
999-0,"passage: If these sites were being put together on a shoe string I could almost forgive the laughable browser support and terrible interfaces, but it's obvious from the scale of the films that these are not low budget projects. It's nice to know that there are some competent firms like Happy Cog involved in the industry, but they seem to be few and far between."
999-1,"passage: Why do official film sites almost always suck? www.x2-movie.com is a prime example: 100% Flash, ridiculous loading times (and I'm on broadband), totally unintuitive interface, tedious, unnecessary animations every time you click on anything and when you finally get to the content (all I could find was the ""Mutant Database"") it gives you hardly any information above what you get by watching the film! It looks pretty (pretty expensive at any rate) but really is nothing more than a glorified trailer."
999-2,"passage: I was going to cite starwars.com as an example of a film site done right, but then I discovered they've redesigned it to be more graphics heavy and less easy to navigate. The content is still a hundred times better than comparable sites though."
999-3,"passage: For a real laugh though, take a look at the official site for The Matrix. My attempt to view the ""lite"" version was met with ""The Lite version of the site is not fully supported by Netscape 4.7 or other older browsers"" (this is using the latest version of Firebird). Dodgy browser detection aside, the main navigation in both high and low bandwidth versions consists of a number of small TV monitors with a mouseover effect that results in the screen becoming blurry. A TV screen the other side of the screen indicates where each link will take you, but on my first visit to the site I struggled with the navigation for quite a while before resorting to trial and error, having missed the screen with the link information. Once you find the content it's pretty good (though generally quite out of date) but it's almost entirely obscured by the dreadful navigation system."
1000-0,"passage: Today marks the first anniversary of the start of my blog (and, by a slightly contrived coincidence, my thousandth blog entry). It's been a fun year. Here are my highlights - if you can't stand lengthy self-congratulatory bullet points, stop reading now."
1000-1,"passage: I've gained a huge amount from the last year, thanks almost entirely to the many excellent bloggers who have inspired me along the way (most of whom are listed on my blogroll). Here's to another exciting year."
1001-0,"passage: On the plus side, at least this will give developers who haven't yet cottoned on to the benefits of web standards time to catch up. On the minus side, once they do catch up they'll have to endure the same pains that the rest of us are putting up with now."
1001-1,"passage: Personally I can't wait for Firebird 1.0, which I plan to distribute to everyone I know with a Windows PC. I know it won't make the slightest bit of difference in the big picture, but at least it will help dissipate some of the frustration."
1001-2,passage: Better analysis than mine:
1001-3,"passage: The real stinker though is the revelation that Microsoft are abandoning development of the stand along version of Internet Explorer for Windows. IE 6 is all we're getting - if you want a better version of Microsoft's browser you'll need to upgrade your operating system, as future browser versions will be an integral part of the OS. When you consider the number of people still using Windows 98 (for example, every PC in the Library at my University) it's likely to take upwards of 5 years from the release of a new Windows OS for it to achieve a significant market share. The upside of this is that we're stuck with IE6 for the best part of the decade."
1001-4,"passage: I wasn't planning to cover the recent AOL and Microsoft announcements as they've been covered to death elsewhere by people with far more insight than myself, but this third piece of news seems to bring things to a head: Microsoft have announced the end of development of Internet Explorer for the Mac. I've never really had access to this browser but I've read enough to know that it was the first full browser release to take web standards seriously, and as such plays a very important part in the history of the web standards movement. It's sad to see it come to an end, but it also raises yet more questions about the direction Microsoft is taking with regards to the web."
1001-5,"passage: In case you haven't heard, Microsoft paid off AOL a few weeks ago to the tune of $750,000,000. In return, they got rid of the ongoing lawsuit concerning their illegal use of their desktop monopoly to crush Netscape, and more importantly gave AOL the ""right"" to use IE as the browser for the AOL software for the next 7 years. Seeing as AOL own Netscape and most Mozilla development is still carried out by full time Netscape engineers, this has raised doubts about how long AOL will continue to fund development of everyone else's favourite browser."
1001-6,"passage: This is incredibly bad news. IE's support for modern standards, while verging on adequate, is still severely lacking. It's not just niceties such as alpha-transparent PNGs and position: fixed; the browser is littered with bugs that make writing complex CSS for it a minefield, and has a number of well documented flaws (such as the inability to enlarage pixel sized fonts) that consistently require workarounds. It doesn't even support the <abbr> tag!"
1002-0,"passage: The decision not to use entry titles turned out to be a costly mistake, which I eventually fixed back in April. The problem with the date headers was far more subtle: over the past few months, I've found myself frequently struggling to rush out an entry before midnight in a bid to keep up the ""daily"" nature of the site. This bizzare compulsion was spurred on by the glaring hole left in my front page if I missed a day."
1002-1,"passage: I've changed from using the day as the principle heading on the front page to using the title of each post instead. This is quite a minor alteration, but I expect it to have a relatively large impact on my blogging habits. For the past year I have treated my blog as a daily endeavour, thanks almost entirely to the way the site was layed out. This was intentional; when I orginally launched blog I made the decision to keep each entry as part of an ongoing narrative, with no individual entry titles and permalinks to entries in the context of the day they were posted."
1002-2,"passage: By removing the day headers entirely, I hope to shift the focus of this blog from religious daily updates to entries with a little more substance. I think the psychology of a blog's design is easily under-rated; I've already noticed that my blog entries have been getting longer since I started adding entry titles. At any rate, with this latest design tweak I certainly won't be rushing out poor quality entries before midnight any more."
1003-0,"passage: Rather than write my own function for this, I have reused the one written by Natalie Downe for her own blog, which she launched a few days ago. She has described its workings in some detail in her most recent entry."
1003-1,"passage: I've changed the date heading for each post to display the relative time since the entry was posted, rather than absolute the date and time. My main reason for doing this is that it solves the timezone problem; all times on this site are in GMT, but the majority of the site's visitors are likely to be in different timezones. Showing the time elapsed since the entry was posted serves everyone regardless of their location."
1004-0,"passage: Via EdTechDev, this report on the important characteristics of course management systems makes very interesting reading. I've been considering doing something along these lines for my final year project at University, but I hadn't realised how much work had already been done in this field. It still looks like an area with a lot of space for improvement though."
1005-0,passage: Read the rest of the post for more insightful thoughts on where XHTML is headed and why it makes sense to get stuck in to it as soon as possible.
1005-1,"passage:
HTML will die. Today's internet is obsolete, and anyone still coding in HTML 4 is planning the obsolescence of their own code. The big picture says that if, and this is a big if, but if we can move to an XML-based internet, then revisions to markup languages, existing and new, don't require browser updates. Once we have user agents that fully support an eXtensible Markup Language, and the style sheets used to format it, then it doesn't matter anymore if we lose the <cite> tag, or if <img> gets dropped. We create our own damn subsets that include them, and everyone else can use our subsets without downloading a new agent! Wouldn't that have been convenient 5 years ago...
"
1005-2,passage: Dave Shea: The Way Forward:
1006-0,"passage: The CSS Zen Garden is growing at a pretty impressive rate, with another three submissions since I last checked it a few days ago: Friendly Beaches, Calm & Smooth and Viridity. Also added recently is What Lies Beneath, which is unique in being the first horizontally rather than vertically oriented layout. It's a shame there's no automated way of tracking the garden (an RSS feed of new submissions for example) as I keep on forgetting to check back for new material."
1007-0,passage: Phil Ringnalda writes about Firebird extensions:
1007-1,"passage:
Don't get me wrong: Firebird by itself is a wonderful browser. Just the standard tabbed browsing, so you can easily switch between several different web pages without the distracting context switch of changing entire windows, and ""Bookmark all tabs in a folder"" plus ""Open in tabs"" in bookmark groups will make a huge difference in the way you use the web. But adding extensions (which is as simple as clicking a link, then an OK button or three, and restarting the browser) gives you the added features that not everyone needs, but that will save tons of aggrevation for people like us who live on the web.
"
1007-2,"passage: Phil goes on to describe a number of useful extensions for power browsers, some of which I am already using and some of which I'm about to install. Like Phil, I wish the documentation for creating extensions for both Firebird and Mozilla was more readily available; I'd love to mess around with extensions but I just don't have the time to dig through the many pieces of out-of-date documentation."
1008-0,"passage: One of the side-effects of switching my blog to serving pages as application/xhtml+xml to browsers that support it (mainly Gecko engine browsers) was that my blockquote citations script simply stopped working in those browsers. The reason this happened is touched upon by Mark Pilgrim in The Road to XHTML 2.0: MIME Types: essentially, when dealing with XML documents Gecko needs you to use document.createElementNS in place of document.createElement when manipulating the DOM."
1008-1,"passage: I fixed this by replacing all occurrences of document.createElement(elementName) with document.createElementNS('http://www.w3.org/1999/xhtml', elementName), thinking this would be an end to the problem. Unfortunately, this broke the script in IE 6, a problem which I didn't notice for several weeks as I very rarely use that browser."
1008-2,"passage: I began to receieve repeated reports of a scripting error in IE, so the other day I finally got round to looking in to it and realised it was failing on the call to document.createElementNS. Once I'd figured that out, the solution to the problem was a little bit of object detection:"
1008-3,"passage: By replacing my calls to document.createElementNS with a call to my new createElement function, I finally got the script working in both browsers. It should work in other modern DOM supporting browsers as well."
1009-0,"passage: Well that explains an awful lot. I was getting a huge number of complaints about lost comments when people were told off by my comment HTML checker, so it's nice to know that the problem wasn't entirely my fault! I fixed the problem (and dramatically improved the usability of the system as a whole) a few days ago by adding a proper preview / re-serve the form ability to the comments system."
1010-0,"passage: What a fantastic idea. I'd love to do this for css-discuss, but the archive is a completely separate entity from the mailing list (it's actually just a script listening to an address that's subscribed to the list). Something like this would need to be built in to the actual mailing list software. That could be an interesting project for a rainy day."
1010-1,"passage:
Why don't emails in mailing lists with public archives have a URL in the footer to the archived version of that particular email?
"
1010-2,passage: Peter Van Djick:
1011-0,"passage: D. Keith Robinson recently launched the redesigned website for the Washington State Drowning Prevention Network. He has written a fascinating account of the development process used for the site, which validates as XHTML 1.0 Transitional and uses CSS for layout. The following extract in particular caught my eye:"
1011-1,"passage: These major changes and layout tweaks were done in under an hour. Because I'd built the site with Web standards they were easy. Really easy. The actual content changes were a snap because the code was so stripped down and clean and all the layout changes were done within the CSS file. Without that the layout changes alone would have easily taken half a day even using sketchy ""find and replace"" methods on the 34 pages of the site."
1011-2,"passage: The stakeholders were ecstatic, I was relieved and the site launched on time. A Web standards success story, and that is just the beginning. Wait until the next time this site needs a major rework. It will be a piece of cake and I'll look like a superstar. And that's what it's all about, isn't it?"
1012-0,"passage: My good friend Andy is soliciting applications to be his other half via his blog. He's a lovely guy, so go sign up! More importantly, the stylesheet for his romance test includes this gem:"
1012-1,"passage: I'm a huge fan of the greatly under-rated <label> element, but I've always worried about it's low discoverability. I'd never thought of using CSS to change the mouse pointer. I've added that to my stylesheet and I'll definitely be using it in the future."
1013-0,"passage: I love it when bloggers stick to their word. The other day, while describing a quick Perl hack that really impressed a major client a few years ago, Tim Bray mentioned the following:"
1013-1,"passage:
Then I turned on Microsoft's search engine, at that time called Index Server, now I believe called Index Services, which is a pretty nice tool (we don't have the equivalent in the Open Source world, more on that another time).
"
1013-2,"passage: And sure enough, he's just posted the first in a series of essays on full-text search. Go read it: it's really interesting stuff. Tim's conclusion is:"
1013-3,"passage:
What we need is for Apache to come out-of-the-box with a built-in search capability that you just push a button and it works, and it's fast, and doesn't need much care and feeding, and it's internationalized, and it has the right API for when you want to get fancy.
"
1013-4,"passage: Until that happens, I will happily recommend MySQL's built in fulltext search indexing for quickly adding a relatively powerful search facility to a site. I use it on this blog and my only real criticism is that it insists on search words of at least 4 letters, which is less than ideal when most of your entries include TLAs. Hopefully they'll provide a way around this limitation in a future release."
1014-0,"passage: Unless Apple can prove without question that it can handle any Web site with its final release of Safari, users should start to get very nervous and hope Opera and Mozilla developers take charge."
1014-1,"passage: In addition, the horrid state of IE makes life without it seem a rather pleasant concept. Who needs a rectangle with no tools when add-blocking, fast, feature-rich options like Safari and Opera exist?"
1014-2,passage: [...]
1014-3,"passage: Had Apple worked with inspired vigor since January to improve Safari, users might feel safe without IE. This hasn't happened. Plenty of improvements have been made, but Safari still lacks the widespread Web site compatibility needed to be the sole browser of choice."
1014-4,passage: The Register's coverage of the end of development for IE on the Mac makes some worrying conclusions:
1014-5,"passage: And finally, if you develop sites yourself learn to code to the standards instead of coding for a specific browser. A one-browser web would be a very boring place indeed."
1014-6,"passage: Incidentally, the only way this problem is going to get any better is through persistant advocacy to the many sites that have broken HTML. If a site doesn't work in a modern standards compliant browser, tell them! The best way to do it is over the 'phone (if they list a number on the site) as that will cost them more in terms of customer service expenses, but a polite email to the right address is almost as good. If you don't get a favourable response, the Mozilla Tech Evangelism team may be able to back you up (especially if the problem is with a major site) - see this page for details of their procedures."
1014-7,passage: What worried me is that a publication with more technical awareness than most could misunderstand the issues this much.
1014-8,"passage: Safari's most important feature (at least according to Steve Jobs) is its speed. This speed is achieved mainly thanks to a highly optimised rendering engine. If they were to add in enough code to completely emulate IE's broken behaviour, the speed advantage would be gone."
1014-9,"passage: This misses the point entirely. The problem isn't the quality of the browser, it's the quality of the web sites themselves. IE for Windows has a ridiculously loose HTML parser that will interpret and display just about any garbage you care to throw at it. Since its market share is so high (more than 90% for many commercial web sites) lazy web developers write for IE rather than writing standards compliant markup. The only way a competing browser could render those sites in exactly the same way as IE would be for it to reverse engineer the IE rendering engine in its entirety, which kind of eliminates the point of having a different browser in the first place."
1014-10,"passage: Sadly, Apple users do."
1015-0,"passage: By its recent actions, Microsoft seems to believe that if consumers want the Internet, they will use the next version of Widows to access Microsoft-based web services and MSN content, and to download XBox patches. And some consumers will do just that. But consumers have a choice."
1015-1,"passage: Yet regardless of Microsoft's intentions, those standards did make it into all recent browsers and the availability of browsers that commonly support CSS1, XHTML, some of CSS2, and the DOM is changing the way designers and developers create websites. And that will not stop. So long as we design with standards, we and the end-users on whose behalf we toil will continue to have a choice."
1015-2,"passage: By coincidence, Jeffrey Zeldman just posted something in a similar vein to my previous rant, looking at things from a different angle:"
1015-3,"passage: By its recent actions, Microsoft has also made dupes of its employees who contributed to web standards. In light of recent news, it appears the company tolerated these employees' activities because they pacified the developer community."
1016-0,"passage: Evangelism is WAR is a fascinating account (actually, the first chapter of an upcoming book) of the principles behind Technical Evangelism at Microsoft and the methods they use to establish their platforms as the dominant players. It's author is James Plamondon, who worked at Microsoft as a Technical Evangelist for 8 years. It's a great read, and it's also entertaining to see developers and customers referred to as ""pawns"" throughout. Found via a link on the Mozilla Tech Evangelism site."
1017-0,passage: Fantastic! Tom Watson has now been joined by Richard Allan (Liberal Democrat MP for Sheffield Hallam) in the ranks of MPs with their own weblog. It looks like it's going to be really good; Richard is something of a geek (he runs RedHat 8.0 at home) and in one of his first entries he takes advantage of his position as an MP to extract information from Tiscali about broadband pricing issues in the UK.
1017-1,"passage: Update: Further reading reveals that he is the Liberal Democrat spokesman on information technology, and a member of a number of technology related government groups."
1018-0,"passage: Accesskeys: Unlocking Hidden Navigation is the first new technical article on A List Apart in months. I didn't think there was much that could be said about accesskeys, but the tutorial has some nice ideas to help make them more obvious without being too intrusive. I think the approach demonstrated by the The Ontario Ministry of Energy site is the most appealing, with single letters corresponding to accesskeys underlined as they are in application menus."
1019-0,"passage:
The motivation behind iterators is twofold. Working with data as sequences is often the most straightforward approach, and a sequence that is processed in linear order often does not need to actually exist all at once.
"
1019-1,"passage: I've read several articles on Python generators now, and I had almost got my head around them, but then I read this: Iterators and Databases by Andy Todd, which demonstrates a simple but intuitive way of using generators to iterate through rows from a database query without having to load all of the rows in to a list in memory first. Brilliant."
1019-2,passage: Andy links to this article which includes a nice one line summary of why generators exist (generators return iterators):
1019-3,passage: More on generators:
1020-0,"passage: Via Jarno Virtanen, a comp.lang.python post explaining the origin of the term ""list comprehension"", Python's clever alternative syntax for filtering lists (see this chapter of Dive Into Python). The term comes from set theory; it's nice to know that stuff was worth learning after all ;)"
1021-0,"passage:
I got a new machine today... It was pretty fun how I did it. I stayed on the #mobitopia IRC channel via my telephone while I was wandering around the stores - I would type in the make/model/specs and the price and ask the guys online to see what they could find in terms of comparitive prices and to get their opinions.
"
1021-1,"passage: Russell Beattie has posted an enthusiastic description of a new IRC application for his mobile phone. It looks really neat, but what got me really interested was his post today about his new laptop:"
1021-2,"passage: Russell has been documenting the new mobile phone revolution on his blog for several months now, and it's well worth reading regularly if you are at all interested in mobile technology."
1022-0,passage: Lawrence Lessig explains why the proposed Eldred Act does not go further in its aims to reclaim the public domain.
1023-0,"passage: Yup, Gecko engine based browsers appear to be more common than Internet Explorer, at least for this small corner of the web."
1023-1,passage: I haven't looked at the statistics for this site in a few months. It turns out I was in for a pleasant surprise:
1024-0,"passage: Incidentally, although the default style for a definition list is to have the definitions indented to the right of the terms, this can be easily modified by setting the margin and padding for the elements explicitly using CSS."
1024-1,"passage: Definition Lists are the third type of list present in HTML, after the far more common ordered and unordered list types. They're an interesting if slightly odd concept: although their obvious use is to provide a list of definitions, the HTML specification seems to indicate that they can also be used to indicate a logical connection between two items of text; one a label for the other. This slight confusion is caused by the examples provided in the specification, which use a definition list both for separating the different sections of a recipe and for extending a set of key marketing features for an imaginary product."
1024-2,"passage: Ben Meadowcroft has a new tutorial up showing how definition lists can be used in semantic markup for lists of definitions, such as glossaries."
1025-0,"passage: This associates the text inside the <error> element (in this case the single exclamation mark) with the ""name"" field."
1025-1,passage: Let's talk about form validation. Here's what I would class as the ideal validation system for a form in a web application:
1025-2,"passage: Incidentally, I haven't mentioned javascript in the above in an attempt to keep things simple. I know client side validation is a great addition to stuff like this (provided it's backed up by solid server side logic) and one of my longer term aims is to dynamically add the necessary javascript to the form during the processing phase, thus skipping the need to write any boring validation code by hand."
1025-3,"passage: The code is still under very heavy development. At the moment it's messy, has several minor bugs (and possibly some major ones I haven't yet uncovered), isn't fully tested and is almost certainly not ready for deployment. Never-the-less, you can play with a demo form that uses it or grab the code here:"
1025-4,"passage: So far, all I've done is add a bunch of invalid markup to an otherwise valid chunk of XHTML. The key is how this markup is processed. FormML (for want of a better name) is never passed to the browser; instead it is processed by my PHP FormProcessor class before being displayed. This class strips out all of the FormML tags, and also applies logic to the rest of the form based on the information from the tags. Because the whole thing is XHTML, this can be relatively easily achieved using PHP's built in XML parser. The XML is modified on the fly to create the XHTML that is sent to the browser. In the above example, the contents of the <error> element would only be displayed if the form was being redisplayed and the user had not filled in their name correctly. In addition, the class populates the value attribute of each input element with the previously entered data and adds an ""invalid"" class to the element to allow it to be styled appropriately."
1025-5,"passage: The next problem is to display a list of descriptive error messages describing the problem. This took slightly longer to work out: I needed a way of setting an error message for each potential problem (remember there are several ways a field can be invalid: it could have been left unfilled, or it could have failed a regular expression check, or it could have failed a callback function), and I also needed some way of indicating how these errors should be displayed. My eventual solution was to introduce a new <errormsg> element for specifying error messages, and a simple templating system (based on a few more custom tags) for indicating where these errors should be displayed. I'm not entirely happy with the way this works at the moment, but here's what I'm using:"
1025-6,"passage: The <errormsg> elements can be placed anywhere in the markup, and will be removed before display. The <errorlist> fragment defines the template for the list of error messages, with the <erroritem> element enclosing the ""template"" for each error and the <message> element showing where the actual error message (as defined elsewhere) should be displayed. Note that the <errormsg> elements specify the field and the test that they relate to. It is not necessary to provide custom error messages for every possible field/test combination; the system generates moderately intelligent error messages in the event that one has not been provided."
1025-7,"passage: That's a lot of custom markup to define the behaviour of a form. The good news is that the actual PHP used to display, validate and redisplay the form is incredibly simple. Here it is:"
1025-8,passage: And that's all there is to it.
1025-9,"passage: I've been trying to figure out an elegant way of automating as much of this code as possible on and off for more than two years. I've tried systems that generate the whole form based on a bunch of criteria (too inflexible), systems that describe the validation rules (fine but they don't help with the redisplay logic) and I've looked at solutions available in other language (such as ASP.NET), all to no avail. Over the past couple of days I've been working on the problem again, and for the first time I think I'm actually getting somewhere."
1025-10,"passage: My latest attempt (sparked by this article on Evolt) involves embedding validation and redisplay rules in the markup of the form itself. The form is written in XHTML, but with a number of additional tags and elements. Any form field elements can have a number of additional attributes which specify the validation rules of the form. For example:"
1025-11,"passage: Writing this once in PHP is trivial, but takes quite a bit of very dull code. Writing this for more than one form quickly becomes a tedious nightmare of duplicating and slightly editing code, which is why so few forms bother."
1025-12,"passage: The yellow highlighting in the above line marks the additional elements. In this case, they mean that the field is compulsory, must contain only letters, and should be checked for final validity by calling the user defined uniqueName() function."
1025-13,"passage: There are a few other validation attributes, but the above gives a good idea of how the system works. The second problem is how to display errors. Part of the solution here is my custom <error> element, which can be used to associate an error message with an error in a particular field. In my tests I've been using this to display an exclamation mark next to invalid fields:"
1026-0,"passage: I've been planning a follow-up to my basic link styling tutorial for over a week now, but it's going to be a lot shorter now thanks to Al Sparber's excellent Uberlink CSS Rollover tutorial, which covers a lot of useful concepts and ends up with a truly gorgeous looking result. Thoroughly recommended."
1027-0,"passage: The Matrix Reloaded: The Abridged Script, by Rod Hilton (via teeb!). Do NOT read this if you haven't seen the film yet; you won't get the jokes and it's full of spoilers. It's the best/funniest analysis of Reloaded I've seen yet."
1028-0,"passage: I've been pretty unexcited by Thunderbird so far: I'm pretty picky about my mail clients (so far Evolution is the only client I've really liked) and Mozilla's never really lived up to my expectiations. I'm preparing to change my mind now that Thunderbird supports extensions. Firebird's extensive collection of extensions is one of its strongest advantages, and the idea of a mail client that can be customised in a whole bunch of different ways by adding new extensions is pretty inspiring. I might even have to try and learn to write some myself."
1029-0,"passage: SitePoint: Storing Hierarchical Data in a Database, by Gijs Van Tulder. The article first shows how the easy way of storing hierarchies in a database, using parent fields and a recursive PHP function to iterate up the tree. It then goes on to talk about a far more interesting alternative called ""Modified Preorder Tree Traversal"" where trees are first ""flattened"" in to a heap-like structure, then each node is stored with a pair of numbers representing that node's position in the tree. I'd seen this somewhere before but Gijs Van Tulder's explanation is far clearer, and comes with some good examples showing how this unconventional storage method can retrieve all of the eventual children of a node in a single query. He also talks about ways of updating the tree structure when new items are added."
1030-0,"passage: Via Web Graphics, ScriptyGoddess' Get ALT Info bookmarklet, which displays a list of all of the images on a page along with their alt attributes; great for testing a page to make sure you haven't missed any."
1031-0,"passage: My personal favourite approach to search design is the one advocated by Steve Krug in his excellent book on web usability ""Don't Make Me Think!"": Have a text field and a button. If the overall thing is labelled ""Search"" then the button should say ""Go"", otherwise the button should say ""Search"". Any additional wording will just slow people down. I use the label ""Search Site"" on this site partly to make it even clearer what will be searched but mainly because the slightly longer label provides more visual balance within the context of my navigation bar."
1031-1,"passage: Tim Bray's series on full-text search has got to the meaty bit: how search engines actually work, including an overview of the kind of data structures they use (presented in XML format for readability). The basics are a lot simpler than you might think. Tim has also posted some thoughts on how people actually use search, of which the most interesting point is that advanced search is hardly ever touched."
1031-2,"passage: Meanwhile, Julie Albertson has a four part series that concentrates on the design of the interface for a search tool (aimed principally at online news sites):"
1032-0,"passage: Tim: Well, er, actually, no standards organization has actually blessed
RSS.
But lots of Internet technology comes up from the grassroots like this, you
know."
1032-1,passage: Tim Bray explains RSS to an imaginary bank manager:
1032-2,"passage: Tim: Well, actually, there are at least two competing versions of RSS, but
we seem to interoperate OK."
1032-3,"passage: Mr Safe: Yes, and I suppose the people behind them are working together
constructively to bring order to the landscape."
1032-4,"passage: Tim: Well, actually, the dialogue tends to devolve into
childish name-calling. But the stuff does still seem to work really well."
1032-5,passage: It's pretty much RSS in a nut-shell :)
1032-6,"passage: Mr Safe: Yes, you kids have a phrase, don't you: ""Rough consensus
and running code,"" wasn't that it?
I have to admire the way you engineers work together to get things done."
1032-7,"passage: Mr Safe: Well, I've learned that sometimes we have to take little
risks on these Internet standards, and they pay off.
RSS is an Internet Standard, right?"
1033-0,"passage: In Jython Is Just Too Useful, Joey Gibson shows how Jython can be used to quickly demonstrate Java class libraries interactively, including using Python's dir() builtin to inspect available methods of Java classes. I used Jython last year while learning Swing for a piece of University coursework and found that being able to interactively create and manipulate Swing components (and see them appear on the screen as I typed) sped up the learning process a great deal."
1034-0,"passage: D. Keith Robinson's Gorilla Web Tips: News and Featured Content, the first in a series of columns."
1035-0,"passage: Keith is thinking about caching. He's drawn up a pretty interesting set of thoughts and requirements, such as support for conditional GET and fine-grained cache length control, and support for caching most of a page while leaving some small parts dynamic."
1035-1,"passage: Personally, I'm considering moving away from dynamically generated content for the most part on this site and going with a page generation scheme something like Moveable Type (or giving funky caching a go). My justification for generating everything dynamically when I built the software originally was that I'd never get a huge amount of traffic so PHP and MySQL would be more than capable of keeping up with demand. While that's still true, traffic to this site has risen to the point where it's a little less certain that everything will hold together (I get failed database connection emails a few times a day). I'm already caching the front page once a minute and caching some internal things such as related entries, so moving to a full caching system for the next generation of the system seems like a logical progression. Besides, there's not much point in dynamically generating hits to archived entries from last year."
1036-0,"passage: PHP Kitchen have compiled a list of PEAR tutorials, covering a number of useful PEAR modules. This is an especially important resource considering that PEAR's module documentation is probably the weakest part of the project. Most modules have some documentation available in the PEAR Manual but much of this is incomplete and crucially there are no links from the package directory entries to the documentation for each package. It's a shame because PEAR has a great deal of excellent code that many developers are completely unaware of."
1037-0,"passage: Via Keith, PXSL, the Parsimonious XML Shorthand Language provides a shorthand way of writing and maintaining XML documents. It's based around the idea that a lot of XML formats contain more markup than actual text, thus by reversing the way the syntax is formatted and using meaningful indentation to express hierarchies markup heavy XML can be greatly simplified."
1038-0,"passage: If you're still wondering what RDF is actually for, Ben Hammersley's Sporting Gentleman's Guide
to the Semantic Web includes a perfect example of triples (even if it get's a bit less obvious after that)."
1039-0,"passage: That said, a discussion with friends at Uni a while back made me reconsider my position on Flash to a certain extent. I was arguing that full Flash-based sites practically always make textual content slower and/or harder to access, and (with the notable exceptions of online cartoons and interactive graphical information) are thus a bad choice for practically any site containing textual information. I was then confronted with something I hadn't really considered: some people use the internet to look at pretty things and be entertained rather than just to find information. Over the past few years I have become reliant on the internet as a tool for finding information, so the idea of information being ""hidden"" behind a layer of eye candy lost its appeal a long time ago. I had never really considered that there are many people who log on to the 'net for half an hour every few evenings with the soul aim of entertainment rather than information retrieval."
1039-1,"passage: Michael Pick has kicked off an interesting discussion on the usefulness of Flash, which is continued on mezzoblue. The key idea under discussion is that while Flash has its uses it remains a fundamentally bad choice for serving up text based content. I couldn't agree more. It's nice to see that some Flash designers think the same way."
1039-2,"passage: With that in mind, maybe the X2 Movie site wasn't quite as bad as I thought it was. It was just aimed at a completely different audience."
1039-3,passage: This does nothing to change my overall opinion of Flash as a tool for serving textual content. I'll believe Flash is a good choice for textual content when I can access that content using Lynx.
1039-4,"passage: N.B. An issue I haven't touched upon at all is Flash as a tool for serving up ""Rich Media Applications"", aka web-based GUIs that provide proper interaction as opposed to the current click-wait-reload cycle provided by HTML forms. I agree that Flash has huge potential here, although I have yet to see an application that really uses this capability to an advantage over more accessible HTML. And I won't believe Flash is truly accessible until I can use Flash based web apps from a command line. I'm hard to please like that."
1040-0,"passage: Oh, and Richard finally got himself a RISC PC. I think he likes it."
1040-1,"passage: My friend Tristan has got his blosxom powered blog up and running again. He's also set up an experimental public aggregator of feeds from a small group of friends from Uni, using blosxom's companion aggregator blagg. I think public aggregators are going to become a popular end point for RSS in the near future: they're a great way of creating an instant community from existing weblogs. The Python Programmer Weblogs page is a great example of this in action."
1041-0,"passage: One of the things I find that's remarkable about Python is that it has a very even learning curve. Maybe it's not even a curve, It's kind of a straight line. Learning Python has a zen-like quality, because Python doesn't try to make the world something else. The designers of Java wanted to make the entire world look like a Java virtual machine and the Java libraries. In addition, Java's designers decided that the C++ approach of allowing functions and global variables in addition to classes is bad. So everything in Java has to be declared in a class. For that reason, Utah Valley State College stopped using Java as an introductory language. They actually teach C++ as a first language, because they found it a lot easier."
1041-1,"passage: Python would make an even better first language to teach programming. It's such a gentle learning curve. You can start with scripts, and of course some people dismiss Python as a scripting language, because you can script with it. You start teaching scripts. You can teach functions. Then later you can add classes. Then you can go onto things like metaclasses. Python has many more of these powerful constructs that you can learn when you're ready. And I think that's very impressive, because it doesn't say you should only be an object-oriented programmer."
1041-2,passage: From the latest Artima interview:
1042-0,passage: Here's a great quote from Rasmus Lerdorf (the creator of PHP) for people who have become disheartened with PHP's lack of elegance when compared to other languages such as Python:
1042-1,"passage: Incidentally, Rasmus' comment comes as part of a thread about the bundling of the full SQLite database engine with PHP5. I've talked about SQLite before: it's a remarkably powerful (and fast) relational database engine designed for embedding in other applications. See Sterling's blog for more links relating to the conversation."
1042-2,"passage: I've seen this point of view a few times before, but I've never seen it summarised in quite such a concise way. For me, it brings a lot of common PHP development issues in to perspective."
1042-3,"passage:
PHP has never been just a scripting engine with some
cool add-ons. PHP has always been the solution to the Web problem with
even more bonus add-ons. And as I have said so many times, PHP is not
about purity in CS principles or architecture, it is about solving the
ugly web problem with an admittedly ugly, but extremely functional and
convenient solution. If you are looking for purity you are in the wrong
boat. Get out now before you get hit by a wet cat!
"
1043-0,"passage: Adrian Holovaty has the scoop on the BBC's new RSS feeds, one for every news index page of their site. Adrian has also written a bookmarklet to find the feed for any section of the BBC site."
1044-0,"passage: Accessify: RNIB redesign does not go far enough examines the RNIB's much hyped new accessible web site and finds it sorely lacking. While it includes basic accessibility features such as alt attributes and skip-navigation links it suffers hugely from out-dated development practises and unnecessary markup bloat. Here's a prime example, taken from the left hand column of the front page of the site:"
1044-1,"passage: It may also be responsible for the strange addition of the word "" body"" to the end of every page title bar the front page of the site."
1044-2,"passage: All of this isn't to say the site is bad: the design is nice enough, the accessibility features are way in advance of most commercial web sites and the site content is generally well laid out and well presented. My grips is that it could have been so much more. The RNIB had a chance to lead by example, following or even helping to establish industry best practises and proving to the world that a site can be accessible, standards compliant and look gorgeous to boot. As it is they've hit one out of three."
1044-3,"passage: Ironically, the Good Design page with advice on designing accessible products is pickled with broken links in any browser other than IE thanks to \ being used in place of / in the URLs."
1044-4,"passage: The content management system has some odd side effects as well, such as the bizzare metadata appended to the top of each page:"
1044-5,"passage: On further analysis, the front page contains 19 tables, 54 font tags and even an image without an alt attribute. Using tables for layout is not necessarily a barrier to accessibiliy, but I can't imagine navigating through a maze of 19 tables (many of them heavily nested) is much fun for users of specialist software. Forcing the site through the W3C validator (it doesn't provide a doctype so I tried using HTML 4 Transitional) produces 84 errors, hinting at a truly flawed underlying site structure."
1045-0,"passage: Tom Gilder has finally started his blog properly, powered by Moveable Type. Nice design too (be sure to view source to figure out how he achieved the drop shadows). He's already covered the RNIB site and has some refreshing thoughts on the IE/Windows situation."
1046-0,"passage: It took less time to write the PHP than it did to decide on the elements to use in the feed in the first place. I've been following RSS for a while so I was in a position to guide her through the quagmire, but I can't imagine it would have been much fun working it out without a guide."
1046-1,"passage: I helped my girlfriend set up an RSS feed for her (home brewed) weblog last night. Explaining what RSS was was easy. Explaining what she needed to put in her feed took a little bit longer. All she needed to do was provide a feed of entries, each with a title, the full body of the entry, the date it was posted and a permalink to the archived entry. In working out how to do this, we identified the following steps:"
1046-2,passage: I support the Road map for a new format. Another format may seem like the last thing we need but the current situation is pretty much untenable and forward motion has got to be a good thing. The few concerns I had have been answered by Tim Bray in his latest essay on the subject.
1047-0,"passage: Dave Shea is advocating moving forward from Internet Explorer, enhancing pages for more advanced browsers (Mozilla, Opera, Safari) using additional style rules that are hidden from IE by using selectors it doesn't understand. Essentially it means adapting the approach we've been taking to Netscape 4 for the past few years to work around flaws in the current browser generation's backwards cousin."
1047-1,"passage: It's a fun idea, and one I've seen quietly taking off over the past few months in various corners of the web. Naturally, the trick is to only use it for enhancements that would not be missed by the IE using masses. Sticking to standards compliant enhancements (such as the hover pseudo selector on non-links) is a good idea as well (no matter how tempting Mozilla's curved border support is) as it means that when IE catches up in 2005 or so its users can enjoy the enhancements as well."
1048-0,"passage: One of the golden rules of web site development is ""never launch a new feature on Friday"", because it's almost certain to break over the weekend while you're not around to fix it. I've just extended my hacked together caching system to cover entries as well as the front page in a bid to reduce the load on the database a bit, and since I'm off to Glastonbury tomorrow morning it will have a whole four days in which to collapse in to a smoking hole in the ground. What's the point of golden rules if you don't break them once in a while?"
1049-0,"passage: I chose to hide the CSS entirely from Netscape 4 using the @import method, as I don't have that browser to hand for testing at the moment. A more comprehensive redesign could include simple style rules to make the site look vaguely interesting in Netscape 4 while more modern browsers got the full layout as the site is meant to look."
1049-1,passage: The demo uses valid HTML 4.01 Strict and CSS 2.
1049-2,"passage: I was forced to use a single layout table for the three news items next to each other. I tried several ways of doing this part of the layout using CSS floats, but unfortunately each of them caused a different problem in IE6 thanks to bugs in its float implementation. It's probably possible to do this with pure CSS and still have it work in IE6 but for the moment the table works fine and does nothing to detract from the overall accessibility of the site."
1049-3,"passage: Just to show it can be done, here's the new RNIB site design (as mentioned earlier) re-done with a CSS layout. It's something of a first draft - I've only tested it in IE6 and Firebird on Windows and it still has a few glitches here and there, but as a proof of concept it works pretty well. Here are a few notes on the implementation:"
1049-4,passage: The demo actually works better in Mozilla than the real thing does - several gaps in the design are closed up giving a result that is visually closer to the original as displayed in IE.
1049-5,passage: The demo uses 10 KB of HTML and 4 KB of CSS. Compare this to the 47 KB of HTML in the original page and the main advantage of CSS becomes readily apparent. The demo also uses a few less images as some of the image effects in the original were replaced with CSS borders.
1049-6,passage: All text and images in the demo belong to the RNIB. My markup and CSS are in the public domain. Should the RNIB ever decide to move to CSS in the future they are more than welcome to use some or all of my work as a starting point.
1049-7,"passage: The background colour in the left and right hand areas does not extend the full length of the document. One potential fix for this is to apply a tiled left background image of a coloured ""stripe"" to the document body for the right hand area, then apply the same kind of thing to a container div that wraps around the left hand area and the main content div."
1049-8,"passage: While I've at least ensured that the demo uses labels in all the right places (unlike the real thing), there's plenty of room for improvement on the accessibility front. Tab index and accesskey support would both be worthwhile additions."
1050-0,passage: I'm off to the Glastonbury music festival. Back Monday.
1051-0,"passage: This is pretty cool: Scott's taken Nat's time-since function and added it to Feedster, giving a quick indication of how long ago an item was posted."
1052-0,"passage: Artima.com keeps getting better and better. In addition to the world's most interesting collection of technical bloggers, Bill Venners has just added Artima Technology Buzz, a collection of community based public aggregators. They work a bit like the Python Programmer Weblogs page, but covering a wider range of topics and with the important difference that you can add your RSS feed up to the relevant community yourself. I've just added some of my category feeds to the relevant sections - you can add your own site using the links in each section, but you need to register a user account on Artima first."
1053-0,"passage: There's been a flurry of blogger activity concerning the RNIB redesign over the weekend. isolani created an XHTML/CSS redesign independantly of mine, while Tom Gilder took mine as a starting point and made several improvements. Ben Meadowcroft has posted an open letter summarising the concerns felt by him and others over the way the redesign has been implemented. Meanwhile, Julie Howell (the RNIB's Good Web Design campaign co-ordinator and a well respected member of the Web Accessibility community) has replied on Tom Gilder's blog promising to collate feedback and pass it on to the web team (Julie herself was not involved in the redesign). It's good to see they're listening, but I really wish they would hurry up and fix their broken links!"
1054-0,passage: Here's a nice example of a simple Python script which can be bound to the right-click menu in Windows and used to quickly upload files to a specific FTP server.
1055-0,passage: To that end I've proposed a small alteration to Echo to remove redundant author information from entries. If you are following the development of Echo I encourage you to take a look.
1055-1,"passage: On a related note, this Java blogger has some interesting thoughts on the WikiNature (or lack there-of) of the Echo Wiki."
1055-2,"passage: Sam Ruby has called for people to start experimenting with the current (very early) Echo example feeds, and the response has been pretty impressive; check out these feeds from Joel Spolsky, Phil Ringnalda and Mark Pilgrim. Now that Echo has progressed to a stage where there are concrete feeds to examine, I have some serious concerns over the verbosity of the format. As they stand, Echo feeds contain a lot of duplicated information. Considering that the default behaviour of aggregators is to poll a feed for updates once an hour, any unnecessary information in the feed itself is going to have a very real monetary cost in terms of burnt bandwidth."
1055-3,"passage: I've posted some further thoughts on this subject in Sam Ruby's comments, but I think the Echo development community need to spare some thought for the size of the feed. I've seen the justification before that requiring elements rather than making them optional makes it easier to write Echo implementations and I agree that this is a worthwhile consideration, but I think the trade-off in terms of additional bandwidth costs needs to be given a higher priority."
1056-0,passage: This is pretty impressive: A Timeline of knowledge-representation that starts at the dawn of the Universe and continues through the whole of human history right up to the present day.
1058-0,"passage: I've talked about unobtrusive DHTML before, and here's a superb example of it in practise from Chris Casciano. His zeitgeist is enhanced by some clever javascript which hides and reveals tables of data when certain page elements are clicked. View source, and you'll see that the document contains only structural HTML, with no embedded javascript at all. The special behaviour is added by an external Javascript file which adds the necessary event handlers when it loads, based on the structure of the existing document. This approach maintains the usability of the information in a non-javascript supporting environment, while seriously enhancing the maintainaility of the page as new structural elements can be added to the HTML which will pick up the special behaviour without any further modification to the javascript needed."
1059-0,"passage: Congratulations Hixie on his new job at Opera software, in sunny Norway. That's a pretty exciting opportunity. Does this mean he'll be contributing less to the Mozilla project? (Dave Hyatt has managed to keep working on it despite his move to Apple)."
1060-0,"passage: If you're still struggling to get to grips with what RDF is actually for, you could do worse than read this guide to Parsing FOAF with PHP. It shows how the FOAF flavour of RDF can be processed using the PHP RAP library, and in doing so demonstrates how RDF documents are built from collections of triples anmd how these triples can be queried to extract useful information. If you've ever used Prolog, RDF is actually a very similar concept."
1061-0,passage: Some useful tips from Scribbling.net:
1061-1,passage: I also really like the subtle visual effect in that site's header where the tail of the 'g' overlaps the sub-heading.
1062-0,"passage: I'm completely stuck on this one. When serving XHTML documents to Mozilla as application/xml+xhtml, the available DOM is for an XML document rather than an HTML document. This means it's missing the document.cookie object normally used to access cookies from Javascript. I can't figure out how you access cookies without it (I've searched Bugzilla to no avail). Anyone got any ideas? I sure wish the Mozilla project provided better documentation on this stuff."
1063-0,"passage: I maintain a strong focus on usability in all of my web projects, but I almost always consider usability from the point of view of an expert user. Figuring out how to deal with people who have very little experience of the web can be a lot harder."
1063-1,passage: D. Keith Robinson:
1063-2,"passage: This is something that can be extremely difficult to remember; by default, anyone involved in web development is themselves an expert web user. Watching less experienced people using the web can be incredibly enlightening (especially the things that look like real howlers, like the first time you see someone typing a URL in to a search engine because they haven't figured out the difference between that and the browser address bar)."
1063-3,"passage:
I feel that all to often those of us who spend every day working, surfing, reading and thinking about the Web lose sight of the fact that it's still a new medium and there are lots of folks out there who don't spend every day working, surfing, reading and thinking about the Web. This could be newbies, your clients and stakeholders or any number of people who might have a vested interest in understanding what makes the Web tick.
"
1064-0,"passage: Moshe Zadka: Networking for non-programmers (and a follow up), via Hans Nowak. A nice gently introduction to sockets, with example code using Python's socket library."
1065-0,"passage: Information on Border Slants (via Paul Hammond). Border slants are the effect whereby diagonal lines can be created using pure CSS, by taking advantage of the fact that thick borders around a box meet at an angle. This article describes the effect in detail and shows how it can be used to achieve a number of interesting shapes, then goes on to show off with an impressive Valentine's Day Heart. See also Tantek's awesome pentagon site map and A Study of Regular Polygons."
1066-0,"passage: Fredrik Lundh: Unofficial XML-RPC Errata, a work in progress. It's good to see that the unicode limitation has finally been cleaned up. What would be really useful is if someone could work out a list of all of the older implementations that only support ASCII strings."
1067-0,"passage: HTML logic is quite simple, and the markup quickly makes sense to writers and editors, in particular -- because the language is set up much the way you have to think to put one word in front of another competently."
1067-1,"passage: Knowing HTML is understanding document structure: That return to the roots of the language means you can focus your HTML learning on the tags and styles that explain document structure -- paragraphs, lists, headings, sections, images, captions. You know, the content types you work with every day."
1067-2,"passage: Jay Small: Reintroduce yourself to HTML. A call to web authors everywhere to go back to their roots and realise that HTML is not something that should be avoided. He makes some great points, such as the following:"
1067-3,"passage: From a site called Small Initiatives, which I'd never seen before but I will definitely be revisiting. Lots of great content under the banner of ""Sensible Internet Design""."
1068-0,"passage: Rafe Colburn slams Marc Andreessen for his recent comments regarding browser innovation. Marc thinks browser innovation has been dead for the last five years. To make a statement like that he must have missed out on Mozilla, Firebird, Safari, Opera and all the other Gecko variants. Which leads to the worrying conclusion that he's either still using Netscape 4 or (even worse) he browses with IE!"
1069-0,"passage: Dynamic XML conversion using the SAX parser and a stack is the best new article I've seen on PHPBuilder in a very long time. It introduces several interesting ideas. The first is something I've been thinking about for a while now: using PHP's output buffering to implement a kind of templating system so that all of the scripts in a system just have to generate an intermediate content type, then the output buffering function adds on the HTML framework and finalises the page. The second idea is ingenious: invent XML elements to represent specific behaviours, then handle them with a SAX before the page is displayed. Here's some example code from the article:"
1069-1,"passage: The tutorial describes a full implementation to make use of the custom tags demonstrated above. It's advocating a full CMS where pages are described using a custom XML format, but the idea could be used in a whole load of different ways. I touched on this approach with my Form Validation prototype but this really shows how much further the concept can be taken. Best of all, the performance hit should be pretty minimal due to the absurd speed of PHP's XML functions."
1070-0,"passage: The internet is shit. Food for thought, via Ben Hammersley."
1071-0,"passage: For several months this Google search
would turn up a UserLand page as the number one hit. Today it's not in
the first ten pages. Must be a bug. Or do they play games with their
search engine? Straight question. It's really hard to believe it just
fell off the Web in the last few days. And while I'm at it, I don't
like it that they label my older specs as deprecated (in caps no less). [...]
"
1071-1,"passage: It is pretty strange that the RSS 2.0 specification isn't listed on the first page. There's an interesting thread on WebMasterWorld at the moment about recent strange behaviour in Google's ranking algorithms, with a number of guesses as to the cause. As to the second complaint, google's descriptions of pagse are generall pulled from the Open Directory. Sure enough, take a look at this page listing RSS specifications, currently maintained by Ben Hammersley currently seeking a new editor (see this comment)."
1071-2,passage: Dave Winer:
1072-0,"passage: I've never really played with the CSS overflow property, partly because I don't trust it to work in a decent number of browsers. Haiko Hebig's Title Pictures show off a clever use for the property to display varying amounts of an image depending on the user's browser size; what's more, I've tested it and it works in Gecko, Opera 7 and IE6 (no IE5 to test on at the moment)."
1073-0,"passage: The simple solution to this is put something behind the DIV(s) that are causing the problem. When the DIV(s) have something behind them IE appears to change the way in which it renders them as the page scrolls. Now IE will re-render the entire DIV as the page scrolls, less efficient but it guarantees the entire DIV is displayed correctly. [...]"
1073-1,passage: Mike Golding offers a solution to the slightly odd IE bug whereby divs in CSS layout sites suffer glitches as the page is scrolled (from December 2002):
1073-2,passage: The problem is in the way that Internet Explorer 6 renders its layered elements. A DIV that has nothing behind it on the page is rendered bit by bit (for efficiency) as the page scrolls. If the scrolling is anything other than 100% smooth the rendering fails leaving the sorts of glitches shown above.
1074-0,passage: From Scripting.com:
1074-1,"passage:
Some news: John Robb is leaving UserLand. This is part of a bigger transition, one that we're not ready to talk about yet. It should be, net-net, good news for Manila and Radio users, and for the weblog community. We weren't ready to announce, John surprised us by writing about his departure on his weblog. He's a surprising guy.
"
1074-2,"passage: John's weblog seems to be offline at the moment, but you can see his parting note in the Feedster cache. It seems he's going to be dedicating some time to the Weblog Network, described here (another cached entry). Interesting stuff."
1075-0,passage: I could have really done with this a few months ago: Making Sense of Java's Dates.
1076-0,passage: Simon Brunning has a great selection of online Java resources. I should really give it its own category.
1077-0,"passage: Linux creator an open source, an interesting interview with Linus Torvalds covering the IBM/SCO case, leaving Transmeta and his opinions of Silicon Valley."
1078-0,"passage: Via Joe Grossberg, Chris Rathman's collection of mugshots of the creators of a large number of important programming languages. There's actually a surprisingly low beard quotient (although it's nice to see Unix/C gurus Ken Thompson, Dennis M. Ritchie and Brian Kernigan all sport a decent amount of facial hair). On a related note, I recently came across 99 Bottles of Beer, a simple program implemented in 571 different languages. Fascinating stuff."
1079-0,"passage: Textile 2 is now available for testing, courtesy of Dean Allen. Textile is one of the more popular structured-text style markup languages, which translate a simple markup language in to HTML. What made the original Textile special was that it concentrated squarely on structural markup, providing intuitive shortcuts for most structural XHTML elements. Textile 2 takes this further, but also introduces a number of presentational effects such as block alignment. Beta PHP code is available in addition to the demo."
1079-1,"passage: That said, the killer feature of Textile 2 in my opinion is the fact that it has been developed as a collaborative effort between Dean Allen and Brad Choate. Brad created a Perl port of the original Textile (Mark Pilgrim did the same thing for Python) but this time round they have been working together to define the format. If they are successful, Textile could become a useful mini-standard for authoring structural markup. At any rate, since Textile is intended to be a shorthand technique to complement HTML rather than replace it it is well worth a look."
1080-0,"passage: If AOL add another million blogs that don't carry information of interest to me, that's fine; I probably won't even notice. Not until one of them posts something interesting, and one of the 70+ blogs I read points me in their direction."
1080-1,"passage: Burningbird starts a discussion on how much harm the addition of AOL users will cause to the blogging eco-system. She compares this development to the chaos caused when AOL users were first introduced to Usenet. I don't see that there's a problem. To my mind, the thing that separates blogging from the many other forms of internet discussion (forums, Usenet, mailing lists etc) is that it comes with its own built in filtering mechanisms. I'll take myself as an example. While I don't use an aggregator, I do use my blogroll to keep track of roughly 70 bloggers who have a very high signal to noise ratio. Through them, I am frequently directed to other bloggers of a similar calibre. I've seen it claimed that there are over half a million blogs on the 'net, but the social network I maintain through my blogroll means that while I only see a fraction of those, that fraction tracks most of the information of interest to me."
1081-0,"passage: Yet another groovy CSS demo: Drop shadow effects using only two nested divs and an alpha-transparent PNG. They look passable in IE as well. Another gem from Paul Hammond's link blog. Incidentally, Paul has written up some interesting observations on how a previous item from his link blog spread itself around the 'net after I linked to it a few days ago."
1082-0,"passage:
I wonder if netscape came up with the Really Simple Syndication when they hijacked the name for what they called rss1.0.
"
1082-1,"passage: Despite questionable understanding of the situation, Adam is taking a stand by promising to spread $10,000 around in payments to aggregator authors to include him as a default feed, but only if they omit support for (N)Echo. As Rafe Colburn points out, even if you assume a complete understanding of the issues behind the creation of (N)Echo, this simply doesn't make sense."
1082-2,"passage: Anyone who's been following RSS even a little bit should know that Netscape had absolutely nothing to do with RSS 1.0 - they defined RSS 0.91 and that was it. Netscape certainly didn't hijack the name, and it was Dave Winer who came up with ""Really Simple Syndication""."
1082-3,"passage: Adam Curry is a dangerous man: He's throwing $10,000 at a problem he clearly doesn't understand. Quote from June 29th:"
1083-0,"passage:
Less markup. Less scripting. Fewer navigation elements. Fewer colors. Fewer graphics. Omit needless words. This is how you make a good web site. I know this for a fact."
1083-1,"passage: Daring Fireball: Independent Days. A sprawling essay that covers web design principles, corporate vs. independent sites, Mac punditry and the justification for adding Google Ads to a weblog. Well worth a read. I particularly liked this quote, although it was more of a side-point than a key point of the article:"
1083-2,"passage: Such design goals, however worthy, are notoriously difficult to sell to clients. A good web site costs a lot of money, and for a lot of money, most clients want a lot of web site. Lots of scripts. Lots of graphics. Lots of needless words."
1084-0,"passage: This is excellent: Marketing for Geeks, a series of articles (three at the moment) by Eric Sink. I've never really been interested in marketing but Eric got me hooked with geek friendly examples such as Paint Shop Pro and CityDesk and I ended up learning a great deal. The writing style is similar to that of Joel Spolsky, so if you enjoy Joel on Software you'll certainly enjoy this."
1085-0,"passage: Via Martin Spernau, two useful resources on writing text editors. The Craft of Text Editing appears to be the definitive work on the subject, and is a whole book made available online with permission from the publishers as it is no longer available in print. Writing a Simple Word Processor (PDF) is a more recent paper with excellent overviews of the data structures and algorithms used in modern editing widgets."
1086-0,"passage: Doug Bowman and Adaptive Path have launched the redesign of the Adaptive Path site. It's well worth exploring: the site looks gorgeous, and is a great example of best practise structural markup, CSS and web standards compliance. Doug has an overview of the highlights of the new design, which includes a brief explanation of the brilliant CSS double rollover effects used for the team photos on the home page."
1087-0,passage: [...]
1087-1,"passage: So, I signed up for an AOL Instant Messenger account today. While it was relatively painless, I did get a chuckle out of the terms of use attached to the Instant Messenger installer:"
1087-2,"passage:
2. Restrictions on Use. You may not create or use any software other than the Software provided by AOL to enter your screen name and password or to access the Service, without the express written authorization of AOL. You may not modify, reverse engineer, decompile or disassemble the Software or otherwise attempt to derive its source code, or in any way ascertain, decipher, or obtain the communications protocol for accessing the Service."
1087-3,"passage: You may not block, disable or otherwise affect any advertising, advertisement banner window, links to other sites and services, or other features that constitute an integral part of the Software and the Service. You may not incorporate, integrate or otherwise include the Software or any portion thereof (including the communications protocols) into any software, program or product that communicates, accesses, or otherwise connects with the Service or any other instant messaging, Internet, or online service."
1087-4,"passage: I guess that not only outlaws Trillian, Gaim and so on but it also bans browsers with built in pop-up blockers, such as Mozilla, Firebird... and AOL's own widely advertised AOL 8 software."
1088-0,"passage: Tim Bray has cooked up a RelaxNG schema for the 0.1 Necho/Pie/Fecho/!Echo snapshot (they really need to hurry up and decide on a name). I had never looked at RelaxNG before, although I had vaguely picked up that it was a lot nicer than the W3C's XML Schema format. Tim has used RelaxNG Compact, a shorthand method of writing schemas that uses a curly-braces style language instead of XML. It's suddenly got me very interested - the compact format is instantly readable and looks a lot more efficient to use than DTDs or an XML schema language. Best of all, there are tools to instantly convert compact syntax in to a full RelaxNG XML schema, and then convert that in to XML Schema (should you want to do so). The Compact Syntax tutorial gives a good overview of how the compact syntax works. Now if only there was a Relax NG validation tool in PHP..."
1090-0,"passage:
Brian Aker, fresh on his new job as Senior Architect at MySQL, shocked the world (or, at least, me) when he announced that he'd embedded Perl in MySQL and was using it for stored procedures a couple of years ago. Of course, it did segfault rather often. Fortunately, it's highly mature now. In his talk on ""Making MySQL Do More"", Brian showed the embedded function API. You can write new functions for MySQL in Perl, Python, PHP, and Java.
"
1090-1,"passage: Via Sam Buchanan, it looks like MySQL might get stored procedure support soon in a big way:"
1091-0,"passage: DevShed have a new article on Date Arithmetic With MySQL, which acts as a kind of missing manual for MySQL's powerful date arithmetic functions. It reminded me of something I've been meaning to write about for some time: my thoughts on storing dates in a PHP application that uses a MySQL backend"
1091-1,passage: Here's a sample select query:
1091-2,"passage: MySQL comes with a full featured API for handling dates, and several column types for use with the date and time functions. Unfortuantely, none of the available column types map directly to PHP's internal format for handling dates, the Unix timestamp (an integer value recording the seconds since midnight on January 1st, 1970). I have seen many PHP applications where people have used a MySQL integer field to store date information as a Unix timestamp. While this works, it is inadvisable as it prevents you from using any of MySQLs powerful built in date handling abilities."
1091-3,"passage: Instead, you can use MySQL's UNIX_TIMESTAMP() and FROM_UNIXTIME() functions to convert Unix timestamps to MySQL date types as part of your SQL queries. This allows you to use MySQL's internal date manipulation features without having to manually convert MySQL dates to PHP timestamps in your PHP applications. I usually use DATETIME fields to store timestamps, but the conversion functions work for any of MySQL's date storage types."
1091-4,"passage: Assuming added is a DATETIME column, this adds an additional field to each returned row called 'unixtime', containing an integer that can be passed straight to PHP's handy date() function for formatting. Going the other way:"
1091-5,"passage: Doing this increases consistency as it means that should you ever have a setup with multiple web servers talking to a single database server the database server's time will be used as the standard, rather than potentially introducing errors from differing clocks on the server machines."
1091-6,"passage: The second example is less useful, but at least demonstrates the function. Incidentally, when inserting things in to a MySQL database with the current time it's generally a good idea to use MySQL's NOW() function to set the time, like this:"
1092-0,"passage: Here's one for budding RSS historians: Ken MacLeod's RSS Links is a collection of links relevant to the development of RSS between March 15, 1999 and August 14, 2000. Ken also provides a distilled list of the more important discussion points. Combine that with Mark Pilgrim's History of the RSS Fork (covering July 2000 to November 2000) and you've got more knowledge about RSS history than anyone could possible want to know."
1093-0,passage: [...]
1093-1,passage: I find de-publishing far more unethical and detrimental to the blogosphere (especially when it comes from such a prominent blogger as Winer) than what Mark Pilgrim is doing.
1093-2,"passage:
Am I the only person here who finds the Winer Watcher a fascinating look into the mind of a popular and experienced weblogger as he writes his posts? I read it compulsively, and find myself thinking ""What changed there? Why did he rephrase that particular statement? How is the new phrasing better than the old?"".
"
1093-3,"passage:
""there's never a concept of a final posting"""
1093-4,"passage: If Winer Watcher was available as a standalone tool, I would use it. As a public resource, it does feel a little below the belt."
1093-5,passage: http://www.oreillynet.com/meerkat/?c=584&t=ALL http://newsisfree.com/sources/info/336/
1093-6,"passage: Not true. 10PM is the final, that's when the people who subscribe via email get their copy of Scripting."
1093-7,"passage: BTW, I've deleted a few paragraphs as I'm writing this post. Think about it. Did I do something wrong? That's how ridiculous this discussion is."
1093-8,passage: 1. Diff-like highlighting of changes within posts is an incredibly useful feature that all news aggregators should support.
1093-9,"passage: 2. Dave's bandwidth claim is bogus. Winer Watcher uses a system of distributed mirrors and never touches scripting.com directly. If WW ceased to exist, Dave's bandwidth bill would change by precisely zero."
1093-10,passage: 3. Dave's copyright claim is bogus. Winer Watcher is no more infringing than these existing syndication services:
1093-11,"passage: Dave: you're free to delete anything you want and do whatever you want on your blog. It's not wrong, it's just a pain in the ass for your regular readers. I might read in the morning and revisit by afternoon to a completely different page, one who's mood and tone have changed thoroughly. I personally don't like that because I'm hardly confident in my previous recollection -- it's unsettling."
1093-12,"passage:
Regardless of the legality, though, it seems particularly ill-timed. If the Echo Project is going to move anyone beyond the intractable political fights over RSS, it's counterproductive to find novel new ways to piss each other off.
"
1093-13,"passage: """""" There's more to the story, in re Mark's control of the RSS validator. It seems people who accuse me of controlling RSS may have missed that Mark and Sam have actually been exerting silent control by changing key aspects of the validator, without telling anyone they were doing it. Mark's flaming in this thread, which caught the attention of quite a few people as being extrordinarily mean, even for Mark, was in exactly the area he wouldn't want you to look in the validator. I want to disclaim that I control RSS, folks, because since the RSS 2.0 spec was frozen, it was Mark and Sam that controlled it, not me. Ironically, no one knew. """""""
1093-14,"passage: For the record, Winer Watcher was started because Dave wrote a series of posts totally lashing out at Blogger, Movable Type, Google, Tim Bray, and myself, and then edited them within hours to erase all traces of his own slanderous flaming. This kind of slander is NOT ACCEPTABLE UNDER ANY CIRCUMSTANCES, and the fact that he seems to know this at some level and edits/deletes it later only makes it worse. WW tracks this kind of Orwellian rewriting of history and displays it. It would be more useful if it could distinguish between a relevant edit and a typo correction, but sometimes even a single word is relevant, so I don't know how it could tell."
1093-15,"passage: For the record, here is a Scripting News post he posted on July 8 2003 and subsequently deleted (but Winer Watcher caught it):"
1093-16,"passage:
IMO Mark is acting like a school-yard bully, picking on someone he feels will make him look big. Hrrmphf! (Surely Mark has every right to dislike Dave - or anyone else for that matter - but constantly picking on people is just plain nasty and can have terrible psychological effects on even the strongest people.)
"
1093-17,"passage:
There's editing posts and then there's what I call ""de-publishing."" http://www.tenreasonswhy.com/weblog/archives/2003/07/10/the_ethics_of_depublishing.html"
1093-18,"passage: I've been using Technorati to follow the discussion, but the real action is in the comments attached to this entry by Don Park. To save you having to read all 80+ comments, here are some highlights (I've tried to pick out entries which represent the different opinions on display). Please note that by the very nature of this post I am quoting these people out of context. If that makes you uncomfortable, read the whole thread."
1093-19,"passage: Today's hot topic is the Winer Watcher, Mark Pilgrim's new tool that tracks and highlights edits made to Dave Winer's Scripting News. The blogosphere is pretty much evenly split on this: some people think it is a blatant attack on Dave Winer, tantamount o blogger bullying, while others see it as a neat technical solution to a very real problem."
1093-20,"passage: The thread then devolves in to an argument about whether Mark's tool is a copyright infringment or is protected by ""fair use"", at which point I tuned out (there are good arguments either way on that one)."
1093-21,"passage: De-publishing is when an author deletes or substantively changes a post without any sort of retraction or notice that the change has taken place. Note that I'm talking about *substantive* changes -- not fixing grammer or spelling or text formatting, but changes that affect the meaning or impact of the post."
1093-22,"passage: Having thought things over, I love the functionality of the tool (Dave's edits have caught me out on more than one occasion) but I am uncomfortable with the way it is being used to attack Dave's personality. Point 4 of Rebecca Blood's guide to weblog ethics is worth reading here: editing entries is best avoided, and when they are edited they should be accompanied by an addendum. Weblogs are a personal medium, but that does not absolve people from responsibility for what they have written. My own policy is to clearly mark any alterations I make to posts (with the exception of spelling mistakes), and I usually avoid making any edits at all. Dave's policy is to edit his blog ""live"" until 10pm. when the day's entries become frozen. It is not so much this policy that is under fire as the scale of Dave's edits, and the nature of the material he later deletes."
1093-23,"passage: Winer regularly writes something inflammatory and then later tries to ""erase"" it from existence by de-publishing it. I disapprove of that because with publishing should come accountability."
1093-24,"passage: Mark Pilgrim is using Winer's RSS feeds to track the ""virtual paper trail"" to reveal the kind of de-publishing that takes place on Scripting News."
1094-0,"passage: I've fixed a small but vital bug in the Incutio XML-RPC library. The library was causing errors when certain unicode characters were used in strings. This is because I was using PHP's htmlentities() function to encode strings before transmission. This escapes all of the characters that need escaping (<, >, &, "" and ') but also escapes a number of other characters that have an HTML entity equivalent. The problem is that these additional entities are defined in HTML but not in XML, so XML parsers were choking on them when they tried to parse the resulting message. I've fixed the bug now by switching to using htmlspecialchars() instead. Thanks to the several people who reported this one (it took me a while to figure out) and to Marc Logemann who's blog entry finally helped me crack it."
1095-0,passage: I'm in Germany for a week. Updates may be sparse.
1096-0,"passage: Now more than ever, the web standards movement needs to make itself heard. With Netscape dead, less enlightened web developers may be tempted to drop all pretences at cross browser compatibility and go back to targeting Internet Explorer. This would be a folly: even without Netscape, the browser ecosystem is thriving now more than any time before in the history of the web. The browser wars are dead and gone, and with due attention to standards they need never come back. Let's hope this truth is not lost in the media barrage we can expect over the next few weeks."
1096-1,"passage: Chances are you've heard this already, but Netscape is no more. MozillaZine are reporting that AOL has cut or will cut the remaining team working on Mozilla in a mass firing and are dismantling what was left of Netscape (they've even pulled the logos off the buildings). Today is a truly sad day."
1096-2,"passage: Thankfully the Mozilla project will continue under the wings of the Mozilla Foundation, a new non-profit organisation headed up by the leaders of the current Mozilla project. The press release has the details: AOL have pledged $2,000,000 over the next two years, Mitch Kapor (of the OSAF) has donated $300,000 and Red Hat and Sun Microsystems are planning to follow suit. The foundation have a new site, which is mirrored on Mozilla.org (and surprisingly still uses a layout table)."
1097-0,"passage: If you've never seen ColdFusion before, it's a server side scripting language/application server from Macromedia (who obtained it when they bought Allaire). MX is the latest version of the language, which sees it completely rewritten in Java to allow it to integrate with Java application servers and existing Java servlet applications. This is shrewd marketing on the part of Macromedia, and I've already seen them advertising it as something to make your existing Java web deployments easier to customise."
1097-1,"passage: I've been reading up on ColdFusion MX recently, and I have to admit it looks like a really nice piece of technology. I'd previously written ColdFusion off as being too simplistic and primitive, but having seen how much its capable of I'm reconsidering my position."
1097-2,"passage: With a bit more development, something like this could be a useful tool for quick-and-dirty PHP scripts that simply pull data out of MySQL and display it as HTML. I still prefer PHP, but ColdFusion has a lot of good ideas which are well worth knowing about."
1097-3,"passage: Here's the same in PHP, assuming $db contains a connection to a MySQL database."
1097-4,"passage: It's less typing, but only by a bit. Where CF gets really clever though is with its handling of SQL. Here's the code to run a SQL query and loop through outputting the results to a simple table:"
1097-5,"passage: ColdFusion is not without its problems: it comes with a price tag, and it encourages mixing application logic with presentation code (although as with PHP this can be avoided through discipline and careful application design). Never the less, I found it interesting enough that last night I spent a few hours putting together a PHP implementation of a couple of ColdFusion concepts. As with many of the experiments I post here this is very much experimental code - I won't be supporting it and I would not recommend using it for anything more than casual experimentation. Anyway, here it is:"
1097-6,passage: The ColdFusion example achieves the same effect but with less complicated code.
1097-7,"passage: The thing that most surprised me about ColdFusion is that although the above syntax looks pretty verbose, it is actually designed in a way that means you can do an awful lot with very little code. The above in PHP would look like this:"
1097-8,"passage: The thing that put me off ColdFusion originally is that it is a tag-based scripting language, specifically designed to make it easy for HTML developers with little or no previous programming experience to pick up. Here's an example of a chunk of CF syntax:"
1098-0,"passage: What's in it for Google? Anil suggests built in hooks to Google's services and APIs, evolving in to a fully fledged microcontent client. I think the biggest advantage is the huge boost a well promoted alternative browser would give to the overall health of the internet. Without competition to drive it forward IE has stagnated, and the web has stopped moving forward. Introduce ""Firebird, Google edition"" to the mix and things suddenly get interesting again."
1098-1,"passage:
Firebird is, finally, a usable browser, and damn close to the being the best in the world, if it isn't already. Google's shown the ability to get an installable client onto millions of desktops around the world. And they have a user experience focus that would nicely shore up the critical weakness that's dogged Mozilla from day one. If the goal is now organizing and presenting information instead of just being the best search engine, then a browser client focused on information retrieval, search, and management is a great first step. And I'd give them better than even odds at being able to grow that application into a full microcontent client if they were so inclined.
"
1098-2,"passage: Anil Dash suggests Google should start sponsoring the Mozilla project, and use it as a basis for releasing their own browser. He makes a very good case:"
1098-3,"passage: The Google toolbar is a runaway success, but could a Google browser be nearly as popular? Google seem to be in the ideal position to launch a browser: they are one of the most popular and trusted brands on the internet, and have a reputation for usability which fits brilliantly with the focus of the Firebird browsers. Mozilla advocates such as myself have long bemoaned the fact that far better browsers exist which the IE using public are completley unaware of. Google have the marketing coverage and the influence to help them discover the alternatives."
1098-4,"passage: Oh, and just think of the cool things Google could do with XUL."
1098-5,"passage: With Microsoft's recent announcements that they plan to compete seriously with Google in the search market, this idea becomes even more relevant. Microsoft have a history of using the dominance in one area to win market share in another (they are after all a convicted monopoly). If they're planning a big push on Microsoft Search you can bet they'll use Internet Explorer to help them get it - it already defaults to searching MSN if you enter words straight in to the location bar. If IE retains its market dominance, Google will be competing on Microsoft's turf, and MS don't have a very good history of playing fair. With their own cross-platform browser, Google will be in a far stronger tactical position."
1099-0,passage: Warning: I'm back from Germany with a back-log of blog postings as long as my arm.
1100-0,"passage: I finally got my exam results for this semester through today. The exam results are great (three 73%s and a 76% for Graphics, which was my weakest subject!) but my average is pulled down quite a bit by my coursework marks, which include a hugely disappointing 50% for the big group software project. I ended up averaging 69.8% for the whole of the second year, which is 0.2% off a First. Hopefully I can do that tiny bit better in the final year."
1101-0,passage: Eric Raymond's Art of Unix Programming is due for publication in August 2003. From skimming the online manuscript it looks like it could establish itself as a classic text book. It's also going to be long - there's no way I can stomach reading it from a screen so I guess I'll have to wait until the dead tree version arrives.
1102-0,passage: Rob Hudson is publishing a series of short Python tutorials explaining language features and standard modules as he teaches himself the language. Articles so far cover Sockets and making cryptograms using the random module.
1103-0,"passage: The Python-UNO bridge for Open Office 1.1 allows you to script OO using Python. At first glance, it seems to work a bit like Windows COM, which can be accessed from Python using Mark Hammond's excellent Win32 extensions."
1104-0,"passage: I'd love to see Python taught at Bath, where I am convinced that the hassle involved in writing and executing simple Java programs is putting many students off developing their programming skills."
1104-1,"passage: The Ideal Programmer on Bruce's weblog is also worth a read; it touches upon the idea that 5% of programmers are 20 times productive than the rest, and asks how disinterested programmers can be encouraged to write better code."
1104-2,"passage: Bruce Eckel is turning in to the world's number one Python advocate. He explains his views on Python on his Weblog in Python Answers, elaborates further on the Python productivity boost in the fourth part of his Artima.com conversation, and discusses Python (amongst other topics) in an interview on the Borland Developer Network. In the latter, he has this to say about Python in education:"
1104-3,"passage:
For me, I find it's more powerful to understand concepts than particular languages. Of course, you do have to understand languages in order to have implementations, but if I were designing a computer curriculum, I would teach Python first so that people could easily acquire depth in concepts, and then much later introduce languages like Java, C++ and C#, after they had reached the point of not getting confused by details. I think students could acquire the important skills much more quickly that way, and it would make a better use of their time. I'm not alone in this idea; there are more than a few college professors who feel the same way.
"
1105-0,"passage: Delimiter is Scott Andrew's new TypePad blog. Unlike his primary blog which mostly talks about his adventures as a musician, Delimiter promises to cover fun and interesting Web stuff. Should be good. Congratulations to Scott for his new job at Amazon as well."
1105-1,"passage: Despite still officially being in beta, I've seen quite a few links to TypePad blogs cropping up. Thanks to blo.gs, you can get a list of all of them(?) by searching for typepad."
1106-0,"passage: That way, changing the @define block at the top of the sheet would change the colour of any element referring to a constant. I'm sure there are much better alternatives for the syntax, but the above should at least make the concept clear."
1106-1,"passage: A nice addition for CSS 3 would be the ability to define ""constants"" for colours (and maybe for other types as well, although I can't think of any that need them off the top of my head). It would be extremely convenient to define a bunch of colour constants at the top of a stylesheet and then refer to them elsewhere. For example:"
1106-2,"passage: One of the niggles I have with CSS 2 is that I frequently have to define colours multiple times. Consider this blog: I use orange in several places (as a background to the header, a border around the sidebar and a background to the sidebar h3 elements). Should I decide to change the shade of orange, or change it to another colour, I would have to alter my stylesheet in several places."
1106-3,passage: Update: It has been pointed out in the comments that this has been discussed before on the www-style mailing list but rejected for a number of reasons (see this thread). Aah well.
1107-0,"passage: As seen on Blogzilla and Ordinary Life, BuyMusic are content to exist as a sharecropper. It looks like the restriction is due to their use of Windows Media as the format for their DRM protected files (BuyMusic is the Windows poor relative to Apple's iTunes). Unfortunately, this could become common place in the next few years as the music industry tries to find ways of surviving in the digital age. After all, with more than 90% of PCs running Windows there's no doubting that's where most of the money is. I guess the music industry are happy to be sharecroppers, and anyone who choses non-Microsoft software will have to get used to being treated as second-class citizens."
1108-0,"passage: And if the signature idea doesn't win any favour, the idea of having a bookmarklet to fill in your name and URL in blog comment forms is one I've been meaning to share for some time."
1108-1,"passage: As you can see, it's a relatively complicated system. The comment authors must have a custom bookmarklet and add a tag to their home page indicating their authenticating web service URL. Note that they do not need to host the authentication web service themselves - they can instead point to one run by someone else who they trust (trust here is essential as the web service must know the user's private key). Meanwhile, the blogging system needs to be able to perform HTTP requests."
1108-2,"passage: The key advantage of my system is that, being based on MD5, it is relatively easy to implement (as opposed to a system based on something like PGP). Provided no one points out any immediate flaws, I would happily construct a prototype in PHP. I'm sure a Perl implementation for Moveable Type users would not prove much of a challenge to any talented plugin author."
1108-3,"passage: Adrian Holovaty has implemented reserved comment names in his blog, a feature that prevents anyone apart from him from using the names ""Adrian"", ""Adrian H."" or ""Adrian Holovaty"" when posting a comment. François Nonnenmacher suggests extending the idea to allow people to ""confirm"" their authorship of comments on any blog using a TrackBack sent to their site that in turn causes them to be sent an alert email, which they can then use to confirm their comment. I like his idea of authentication based on URLs (email addresses are no good; they should not be publically displayed for fear of spam harvesters) but I think I've come up with an alternative authentication scheme that removes the need for the user to manually confirm authorship. This is pretty complicated, so bare with me."
1108-4,"passage: Security wise, it strikes me that the weakest link is the client side bookmarklet which comment authors would need to use. However, comment signing is not the most critical security application in the world and comment authors could easily change their password by updating their bookmarklet and alerting their signature web-service provider (which could even be themselves) of the change."
1109-0,passage: John Robb: NEVER (under any circumstances) publish a weblog to a domain that you don't control. Nice to see he's back.
1110-0,"passage: Mozilla 1.5 alpha is now available for download from Mozilla.org. Changenotes here (it looks like mostly improvements to Composer, but the ability to jump from the javascript debugger straight to the view source line in question could be handy). Asa is promising a new Firebird release soon:"
1110-1,"passage:
We're planning on doing a Firebird release based on the Mozilla 1.5a branch. This isn't going to be Firebird 0.7 since we haven't met our goals for features and fixes but we think it's important to get the autocomplete crash fix (and a few other fixes) into the hands of all the people currently using 0.6.
"
1110-2,passage: Some of the comments attached to Asa's post argue against releasing a new build based on the 1.5a Mozilla code. Personally I'm looking forward to the autocomplete crash fix in an official build as opposed to just the nightlies.
1111-0,passage: I've built a prototype of the comment signature system discussed earlier. The prototype consists of an authentication server which anyone can register with and support on this blog for verifying signatures. So far it seems to work.
1111-1,"passage: Incidentally, this isn't the first time this problem has been tackled. See here and here for details of a system that uses PGP to sign and verify comments."
1111-2,"passage: The system is decentralised, so if you want to host your own authentication server rather than relying on mine feel free to grab the PHP code (warning: it's a bit of a mess) and use it as a starting point."
1111-3,"passage: This is more of a proof of concept than anything else, so feedback and suggestions would be very welcome."
1111-4,passage: To add support for comment authentication to your own blog (assuming it uses PHP):
1111-5,passage: To gain the ability to sign comments:
1112-0,"passage: So, Mailinator (via Joel). It's a brilliant concept; whenever a site you don't trust insists on you giving them an email address you invent something-random@mailinator.com and give them that instead. Then you go to the Mailinator site, enter the something-random and see the emails recently sent to that address."
1112-1,"passage: As someone who dislikes having to tell sites my email address I love it. As someone who has run sites which insist on an email address I'm not so sure. Forced email registrations are frequently abused for harvesting emails for unwanted mail-outs, but they serve a very valuable purpose in protecting sites from abuse. If user's have to provide a ""real"" email address to sign up, you've got something concrete with which to ban them should they abuse your service. Sure, these days many people have a multititude of addresses but it's still a very useful deterrent against abuse. As services like Mailinator become more widespread, I can see web application maintainers needing to fight a constant battle to ban specific email providers from being used to sign up for accounts. It's that, or move to manually vetting every account which adds delays and seriously reduces people's motivation for signing up in the first place."
1113-0,"passage: apple fruit - lots of stuff about Apples, the fruit"
1113-1,passage: apple - lots of stuff about Apple computers
1113-2,"passage: These are not even advanced search techniques. It's a basic rule of searching: if your first set of results aren't what you are looking for, enter more specific terms and try again."
1113-3,"passage:
So, when you're doing research online, Google is implicitly pushing you toward information stored in articles and away from information stored in books. Assuming this practice continues, and assuming that Google continues to grow in influence, we may find ourselves in a world where, if you want to get an idea into circulation, you're better off publishing a PDF file on the Web than landing a book deal.
"
1113-4,"passage:
Type in the make and model of a new DVD player, and you'll get dozens of online electronic stores in the top results, all of them eager to sell you the item. But you have to burrow through the results to find an impartial product review that doesn't appear in an online catalog.
"
1113-5,"passage: There are a lot of legitimate concerns about Google relating to its size and massive influence over the web's traffic, but concerns about skewed results are often the fault of the user rather than the tool. Learn to search!"
1113-6,"passage:
Search for ""apple"" on Google, and you have to troll through a couple pages of results before you get anything not directly related to Apple Computer - and it's a page promoting a public TV show called Newton's Apple. After that it's all Mac-related links until Fiona Apple's home page. You have to sift through 50 results before you reach a link that deals with apples that grow on trees: the home page for the Washington State Apple Growers Association.
"
1113-7,passage: sony DVP-S550D review - review sites come out top
1113-8,passage: sony DVP-S550D - shopping sites come out top
1113-9,"passage: I'd say that day has already come (but replace PDF with HTML), but I'm not sure I understand how this is a bad thing. Surely information is more valuable if it is searchable? Books are not going to die out because of the internet (how many people prefer reading from a screen?) but if you have an idea to share the internet is obviously a better medium - you reach millions more people for a fraction of the cost of traditional publishing."
1113-10,passage: Slate: Digging for Googleholes:
1115-0,"passage: The work is all done by the % vars bit at the end of the line. Since vars is a dictionary, Python substitutes the named items in the dictionary for their corresponding %(varname)s tokens in the string loaded from the template file. More information on string formatting operations can be found in the manual."
1115-1,"passage: A long, long time ago I wrote my first ever PHP templating system. It was pretty simple; it consisted of a function that took two arguments: the name of a template file, and an associative array of replacements to make on that file."
1115-2,"passage: As templating systems go, it's far from the most useful or complete solution. It does however show that a little Python can go quite a long way."
1115-3,"passage: I've finally got around to playing with Python CGIs for web development recently, and decided I needed a similar system. Thanks to Python's powerful string formatting operator, it ended up as a one-liner:"
1115-4,"passage: Presuming you've set templatedir at the top of the script, the above function lets you load a template and make some simple replacements on it with a single function call. For example:"
1115-5,"passage: With the above saved in the template directory as ""entry.tpl"", the template function above can be used thus:"
1116-0,"passage: Adam Kalsey has kicked off Simplified, a new series on web usability, with some thoughts on creating usable web forms. The conversation continues on Paul Scrivens' blog, and covers a lot of interesting ground. D. Keith Robinson also has some tips on better form design in his latest Gorilla Web Tip."
1117-0,"passage: Tom Gilder has started a series of posts looking ahead to CSS3. In his first installment, he describes the awesomely powerful ::outside pseudo-element. Using this, CSS3 authors can apply multiple backgrounds and borders to single elements (at the moment doing so requires fussing around with nested divs). If you don't instantly see the importance of this, take a look at some of the attempts to render rounded box corners using CSS. All of them require the addition of extra presentational elements, none of which would be needed if we could use the ::outside selector instead."
1118-0,"passage: This looks like it could be really useful: an XPath implementation in pure PHP (no extra modules required), via More Like This."
1119-0,"passage: Steve Clay's Private Validator is a really handy tool for people who working on intranet sites who want to be able to run them through the W3C's validator. It's a PHP script which you install on a server behind the firewall that has access to both the intranet and the outside world. It comes with a bookmarklet which activates the script. When the script is activated, it grabs the indicated page, then uploads it to the external validator and grabs the result. It's pretty neat, but even neater would be some kind of desktop application that did the same thing. I can almost feel a Python script coming on."
1120-0,"passage: It's hosted as a guest demo over on Position is Everything, which now has four excellent layout demos."
1120-1,"passage: I'm not sure how I missed this one. Holly Bergevin's Perched Upon a Lily Pad is a CSS demo that shows off a 3 column layout with a flexible header, full length columns, horizontal navigation bar and complete descriptions of exactly how it all works contained within the page. It's very educational (I've learnt a trick or two just by reading it) and a great example of solid, cross-browser CSS design."
1121-0,"passage: Nathan's reply on the same page is worth reading. I agree with him; while hackable URLs as an additional navigation aid add very little value to the vast majority of surfers, they are a powerful indicator of the quality of a site's navigational structure. They also tend to be a by-product of a well thought out URLs system, meaning if you are already following best practise for URLs you can often gain hackability for a very low extra cost."
1121-1,passage: Nathan Ashby-Kuhlman is devoting this week on his blog to discussion and analysis of news site's URLs.Nathan's 5 attributes for a good URL are worth repeating here as they succintly describe my own opinions:
1121-2,"passage: I'm something of a fascist when it comes to URLs; they are one of my first considerations when initially designing a site and for personal projects I refuse to compromise on them. Nathan's series is now on day two, and true to his word he has been dissecting a number of large and not-so-large news sites and grading each one on the quality of their article URLs."
1121-3,"passage: Steven Jarvis plays devil's advocate in the comments, asking a very interesting question about the value of ""hackable"" URLs:"
1121-4,"passage:
I've got a devil's advocate question for you: why do URLs need to be hackable? My wife (who is remarkably non-websavvy) would never in a thousand year think about hacking an URL. I'd say the same is true for at least 90% (and probably much higher than that) of the audience of news websites. *I* like hackable URLs, and I agree in general that they should be hierarchical, if only because I like at least the appearance (such as that given by liberal use of mod_rewrite) of a well-organized site. Isn't hacking an URL really just a fall-back point when the site's navigation fails you?
"
1122-0,passage: ssl - the Windows installer now incorporates SSL support. (New in 2.3a2: timeouts set on the underlying socket are now handled correctly.)
1122-1,passage: That's pretty sweet; with 2.3 we can deploy Windows applications that securely communicate over the internet out-of-the-box. Combined with web services and server-side content management systems that ability could be very useful indeed.
1122-2,"passage: After numerous alphas and betas, Python 2.3 has been released. Python.org has highlights of the release, while A.M. Kuchling's What's New in Python 2.3 goes in to a bit more detail. There's some great new stuff, but the feature that particularly caught my eye is this:"
1122-3,"passage: Incidentally, since today is the 29th of June this release means that 2.3 has met the August 1st deadline for inclusion in the next version of Mac OS X. Owning a Mac is looking more and more attractive."
1123-0,"passage: Tim Bray's series On Search now has a table of contents page linking to each of the previous entries. The most recent article covers metadata, and includes some insightful commentary on the huge problem of gathering metadata from users in the first place."
1124-0,"passage: Shelley Powers: RDF: Ready for Prime Time gives an overview of the many applications and services already deployed that use RDF in some way. Via that article, RDF in Mozilla Docs and RDF in fifty words or less, both published by the Mozilla project."
1125-0,"passage: I always thought you had to be an idiot savant to be able to state the day of the week for any date in history, but it turns out there's a reasonably simple trick to it. The Doomsday Algorithm was first invented by Dr John Conway, also famous for creating the game of life. Rudy Limeback's detailed explanation provides everything you need to know about the algorithm, how it works and how to memorise it."
1126-0,"passage: It resizes the current page to be 500 pixels wide, which for most flexible designs makes the text much easier to read. It's only tested on Firebird. I also find Verdana to be the most readable of the web fonts, so I've created the following bookmarklet which alters the default text style for the page - ideal for reading Slashdot ;)"
1126-1,passage: Narrow
1126-2,"passage: I've long been a proponent of flexible web pages rather than restricting sites to a hard coded width in pixels, but now that I've started surfing at 1280x1024 I'm beginning to realise how true the statements about an optimum width for readable text really are. The simple solution would be to surf with my browser window resized to a sensible size, but old habits die hard. Instead, I made myself the following bookmarklet:"
1126-3,passage: Verdana
1126-4,"passage: Both bookmarklets are extremely simple, but I have been using them all day and have found them very useful."
1127-0,"passage: While I'm all for marketing Firebird, there is a pretty big fly in the ointment. If you take a look at the negative reviews on Downloads.com (there are positive ones as well) it seems an awful lot of new users have had their fingers burnt by issues that I've never even noticed. If we've learnt anything from the original launch of Netscape 6 it should be that a poor first impression lasts, so it's not worth pushing Firebird at anyone who is likely to write it off the first time it crashes on them. That said, I haven't had 0.6.1 crash once since I installed it, but it's still an issue that's worth baring in mind."
1127-1,"passage: Blake Ross has published a page on Marketing Firebird. He makes an interesting comparison between Firebird and Kazaa, pointing out that Kazaa has over 3.1 million downloads a week with promotion only via word-of-mouth:"
1127-2,"passage: Kazaa is spreading like wildfire because it offers a killer app - music sharing - and everyone knows it. I have friends that can't turn on their computer without help, but you'd better believe they're on there getting songs. I see people coming up with all kinds of clever taglines to promote Firebird (""if you're not using Firebird, you're not surfing the web - you're suffering it"") and that's great, but the fact is that 100 million users find Internet Explorer ""good enough."" The promise of an improved overall experience, without identifying how it improves on a working model, just isn't going to grab people."
1127-3,"passage: Blake also sets a challenge: Make it your goal to convert five friends, coworkers, family members or other acquaintances to Firebird. I'm happy to say I've done that already, but I don't see it as any reason to stop. I've also joined the Mozilla marketing mailing list, which is pretty low traffic at the moment but will hopefully pick up as word about it gets out."
1128-0,"passage:
XHTML is, at it's most basic, much simpler and easier to learn that traditional HTML 4.0. With a simple style guide, standard markup and CSS styles you can accomplish almost all the formatting a content author would need, just by knowing a handful of markup tags. Instead of trusting the CMS to sort out code from Word, for example, you can hand a content owner a cheat sheet with the basic tags outlined and trust that they can code their own content. I mean, really, how hard is is to learn 10 or so tags? Team this technique with a tool like Contribute and you've got a nice, simple and cheap process that, while doesn't store you content in a database, keeps it in a clean, standard form you can repurpose down the road.
"
1128-1,"passage: As for ensuring entered XHTML is valid, I think this site's comment system does a pretty good job of showing how that can be achieved with only a small amount of server side effort."
1128-2,"passage: Don Park questions the benefits of emitting XHTML. In one sense, Don is right; publishing a whole site using XHTML in this day and age brings very little benefit and can cause a great deal of grief. But just because XHTML doesn't provide advantages when publishing whole sites does not mean it should be written off entirely. As I've said on this blog many times before, XHTML offers an excellent format for future-proofing site content, especially chunks of content kept in a database. Keith D. Robinson makes some excellent points along the same lines in his latest essay, Standards, Semantic Markup, Distributed Authorship and Knowledge Management:"
1129-0,passage: HarryF's PHP5: Coming Soon to a Webserver Near You is the most detailed overview of the features we can expect from the next major PHP release that I've seen yet.
1130-0,passage: I plan to have another go at the signing prototype and fix some of the bugs in the current version some time next week.
1130-1,"passage: I should have made these a long time ago: thanks Nat for reminding me ;) Comments no longer require an email address, and provide a proper error page with the comment intact if you forget to enter your name. They also now add http:// on to your site URL for you if you forget to enter it yourself. I added the last feature in the code that displays the comments, so it should fix all of the older comments with invalid URLs as well."
1131-0,"passage: Over on Kryogenix, Stuart has solved the CSS image replacement problem with some clever application of the overflow: hidden; property. The Fahrner Image Replacement technique is often used to replace a heading with a background image (see most of the designs in the CSS Zen Garden for examples), but has the disadvantages that it requires an additional <span> tag to be added to the code and that some screen readers which follow the display: none; directive skip straight over the replaced text without reading it. Stuart's new technique solves both problems, and works in modern browsers from IE 5/Win upwards."
1132-0,passage: Clearing out another several days worth of tabs. Some day I'm gonna get me a link-roll.
1133-0,"passage: Here's one of the neatest tips for clean URLs I've seen yet, from Thijs van der Vossen. He's come up with a mod_rewrite rule that checks to see if the requested file exists if you add .html on to the end of it, and serves it up if that's the case. I'm posting the full code snippet here because it's just too good to risk losing to link-rot in the distant future:"
1134-0,passage: Ever time I see something like this I'm reminded of how truly irritating the internet would be if I hadn't switched to Firebird.
1135-0,passage: Danny O'Brien compares Perl with Python. Best observation: Python code just doesn't have much personality compared to Perl.
1136-0,passage: Update (12th August 10:40am): I've changed the above to take in to account a bug report from Hixie in the comments.
1136-1,passage: Self contained data: URI kitchen
1136-2,"passage: I couldn't resist this. Hixie has released a new version of his data: URI kitchen, to celebrate the addition of data: URI support to the latest Opera beta. In the spirit of recursion, I present this reformulation of the data: URI kitchen that uses client side Javascript. What better way to deliver such a thing than as a data URI?"
1137-0,passage: IE 5 was released in September 1998. A popular browser statistics site (insert usual disclaimer as to the reliability of any stats but your own here) show IE 4's market share to be in the region of 1%. Even Netscape 4 has more users than that!
1137-1,passage: I've lost count of the number of Javascript scripts I've seen floating around that include the equivalent of the following code snippet:
1137-2,"passage: document.all was introduced in Internet Explorer 4, because the W3C DOM hadn't yet standardised a way of grabbing references to elements using their ID. By the time IE 5 came out, document.getElementById() had been standardised and as a result, IE 5 included support for it."
1137-3,passage: Don't use document.all. document.getElementById() is supported by every Javascript supporting browser released since 1998.
1138-0,"passage: Kevin Davis has set up an impressive demonstration of the power of Moveable Type templates when combined with browser-side XSLT transformations. He's set up MT to output an XML document containing just his entries (similar to an RSS feed), along with a link to an XSLT stylesheet that causes Mozilla and IE 6 to transform the entry and render it as XHTML."
1139-0,"passage: I get one or two emails a week about my FormProcessor class, making it the most popular of all of the code experiments I've posted on this site. Each time I'm asked if I plan to update it soon, and each time I reply that while I'd love to go back to it, I can't promise I'll ever get the time to take it further. The great news is that Peter Bowyer of Maple Design has been working with my code and has made a number of huge improvements to it. If you liked my version, you'll love his evolution of it: it adds support for radio buttons, checkboxes and select fields and he's got a number of other interesting ideas up his sleeve for the future."
1140-0,"passage: In another silly Python/Windows hack, Hans Nowak shows how a simple Python script to move a file up to its parent directory can be added to the contextual menu for all Windows files. I can think of all kinds of useful tricks that can be enabled using this tool: instant uploading of a file to an online Photo Gallery for example."
1141-0,"passage: The concept is great, but the execution has a some subtle flaws - the most important of which is that browsers with Javascript support turned off (but CSS turned on) will not be able to use the form. The culprit is the use of a style=""display: none;"" attribute on the two divs that should initially be hidden. CSS supporting browsers will follow this rule blindly, even if Javascript is disabled and they will thus be unable to later reveal the hidden page content. The solution is to have all of the elements visible initially, then hide them with a piece of Javascript that executes when the page has loaded."
1141-1,"passage: Andy Arikawa has a nice demonstration showing how multi page forms can be served up as a single page using some simple Javascript, resulting in a clearer form without loading times in between each page."
1141-2,"passage: Taking the above points in to account, here's a reworked version of Andy's demonstration that should work just fine in browsers with Javascript support disabled."
1141-3,"passage: My other small gripe is the use of javascript: in the href part of the links to activate the toggle function. Dive Into Accessibility has the skinny on why this is a bad idea. Since the toggle links lead to other sections of the form, it makes sense to use the IDs of those sections as the link so that browsers without javascript will still ""jump"" to the section that is linked to. The Javascript itself can be placed in an onclick attribute (and duplicated in an onkeypress attribute for improved accessibility)."
1142-0,passage: Jesse Ruderman (of indispensible bookmarklets fame) now has a blog. It's off to a good start: here's a useful summary of the different chrome URLs available in Firebird and Mozilla.
1143-0,"passage: I'm addicted to tabs. Several times a day, I scan down my blogroll looking for blogs that have updated since I last checked, then middle click each one to open it up in a new tab in the background. I then work my way through each one, reading the earlier ones while the later ones are still loading (tabbed browsing makes being stuck on a modem a lot less painful). If I see anything interesting linked to from a blog entry I'm reading, I'll middle click that as well. Within a few short minutes I'll have so many tabs open I'll be running out of space in my tab bar."
1143-1,"passage: Often I'll leave anything even remotely interesting open all day, but if I'm in the mood to reduce the clutter I'll load up Notepad and start pasting URLs of interesting pages in to a document there as I close each tab in turn. These pasted URLs later form the basis of blog entries, which I always write in Notepad for fear of losing them to browser crashes. Eventually, I'll either write up an entry and transfer it to my blog, or delete the URL from consideration. If I'm really behind, I'll blog a whole bunch of links at once in a big list."
1143-2,"passage: This technique works pretty well for me, except for one thing. Because I'm constantly opening links in new tabs, the back button in my browser no longer returns me to the page that I found the link on. I open dozens of links during a day and often leave them open for hours (if not days) before blogging them, during which time I frequently completely forget which blog I first saw the link on. For interesting items that aren't being blogged in dozens of places at once I like to provide a ""finders fee"" by linking back to the person on who's blog I saw the item, but I am often unable to do that due to the loss of the back button."
1143-3,"passage: Thank goodness then for Jesse Ruderman's ""go to referrer"" bookmarklet, which I just found while exploring his Miscellaneous category. It sends you back to the page you came from, even for new windows or tabs in which the back button has stopped functioning. My biggest problem with tabbed browsing is a problem no more."
1144-0,"passage: Personally though, I hope this development strikes a killing blow to the whole diamond industry. See Anil Dash for a good summary of why the world would be better off without it."
1144-1,"passage: Wired: The New Diamond Age. Two companies in the US have perfected techniques for creating cheap artificial diamonds, virtually indistinguishable from the real thing. The story of how they got there is riveting - retired army generals purchasing cold war soviet technology, veiled death threats to scientists at conferences and best of all, a very real threat to the De Beers diamond cartel / monopoly."
1144-2,"passage: Interestingly, the most important application for the tecnology looks likely to be semi conductors. Diamonds can handle far higher temperatures than silicon, meaning chips so fast that silicon would just melt under the strain."
1145-0,passage: 10 Python pitfalls by Hans Novak (via Simon Brunning) is essential reading for anyone with more than a passing interest in Python. Python never copies implicitly. If only that were true of PHP.
1146-0,"passage: When writing an XML parsing class in PHP, don't forget the ampersands in the following code snippet:"
1146-1,"passage: Failure to include them can lead to two days of debugging, frustration and hair loss. Solution found thanks to Keith's PHP rant (which itself reads like the result of several days of hell). Roll on PHP 5, where objects are passed by reference by default."
1147-0,"passage: Kellan Elliott-McCrea (author of the popular Magpie RSS parser): A Few Tips for Writing Useful Libraries in PHP. Kellan makes the interesting observation that PHP encourages a culture in which most development occurs in the context of either full applications or C extensions, with few people devoting themselves to releasing libraries."
1148-0,"passage: This is the only part of the current specification that I, as a PHP developer, have a problem with. To my knowledge, there is no way of directly accessing non-standard HTTP headers from within a PHP script. As such, it would be impossible for a PHP Atom API application to support Atom authentication. This is a serious barrier to adoption of the standard, especially as PHP is by far the most popular open source web scripting technology."
1148-1,"passage: Mark Pilgrim has posted an extensively documented demonstration of the current draft of the Atom API, a REST style web service interface for posting to and editing weblogs. It looks like it will be a fun standard to implement; the basic idea (as with all REST services) is to obtain as much leverage as possible out of the HTTP standard, using lesser known methods such as PUT and DELETE in addition to the more common GET and POST. The authentication mechanism is particularly interesting: since Apache's support for digest authentication requires an additional module that many hosts may not provide, the Atom guys have created their own based around new Atom-Authenticate HTTP headers."
1149-0,"passage: In a recent issue of the Sitepoint Tech Times newsletter, Kevin Yank explains (in detail, with pictures) the recurring problem in CSS of trying to create a three column layout with columns of equal height and a footer spanning all three. If you don't yet understand the problem, you will once you've read his article. Kevin suggests a javascript fix for the problem, but fails to mention that by using floats instead of absolutely positioned divs for the side columns a three column layout with a full width footer can be achieved without resorting to javascript. Pixy's 3 columns, no hacks demonstrates this technique in action. In addition, the CSS-Discuss Wiki has a comprehensive list of 3 column layouts that demonstrate a number of other techniques for solving the same problem."
1150-0,"passage: Mozillazine are carrying a preview of the next release of the excellent Firebird browser, with the most exciting new feature being the new support for Mozilla style sidebars (previously known as web panels). I'm looking forward to being able to browse with my blo.gs powered blogroll in a side panel again."
1151-0,"passage: If you've been wondering why the site has been so quiet for the past few days, here's the reason: I've moved to the States! To cut a long story short, I'm here in sunny Lawrence for a couple of weeks preparing for a year long industrial placement at the Lawrence Journal-World, which should start for real in October (depending on my Visa application). To call this an exciting opportunity would be an understatement. The team I'm working with have won a ton of awards, and have a fearsome reputation within the industry. I'm joining Adrian Holovaty (recently interviewed on zlog) as a web developer working on KUSports, LJWorld and the excellent Lawrence.com. The company itself is remarkably forward thinking, especially in its approach to the web (no need to support Netscape 4) - there's a good overview of what makes the Journal World special here, which includes a video interview with my boss, Rob Curley."
1151-1,"passage: As part of my new role, I'm knee deep in PostgreSQL, Python, mod_python, Red Hat and Apache so expect plenty of blogging on those subjects over the next few days. It's all good."
1152-0,"passage: From a link on the mailing list edition of comp.lang.python, this talk on strong typing (in the form of heavily annotated slides) is an explanation of the ML type system and why it really doesn't suck. From the same thread, Felix is a new high level C++ style language with an ML style type system which looks like it could be worth experimenting with."
1153-0,"passage: I recently read my way through The Pragmatic Programmer and found it easily lived up to my epectations based on reviews I've seen on the web. Dave Thomas, one of the book's authors, has an excellent weblog on which he has been posting a series of programming exercises called Kata. Some are programming problems while some are more related to software design, but each one provides an interesting thought exercise with no instantly obvious solution."
1154-0,"passage: Jesse Ruderman's Blogidate bookmarklets cycle through all of the textareas on the current page and submit their contents for validation. I suggested an alternative approach, and to my great delight has has followed it up with the essential Blogidate XML well-formedness. One click, and each textarea on the page will be checked to see if it contains valid XHTML. If it does, the background goes green - if not, it goes red. Hopefully I'll never post another invalid entry (my previous solution broke when I switched to application/xml+xhtml)."
1155-0,"passage: Congratulations to Eric Meyer on the launch of his new consultancy business, Complex Spiral Consulting (named after his famous css/edge demo). The new company's tag line is ""Helping clients improve the bottom line through the use of Web standards"", so it looks like the theme of standards advocacy is continued from his role at Netscape. Eric has also promised a series of occasional articles/tutorials, the first of which explains some useful techniques for using floats as part of CSS designs."
1156-0,"passage: Advocating web standards is a phenomenally difficult task, for a number of reasons:"
1156-1,"passage: Ian Lloyd: Designing for the future, and the training gap. Ian highlights the frustrations faced by all web standards advocates when trying to encourage their less web-enthused co-workers to take the leap. I've been incredibly lucky in that both Incutio and LJ-World have a remarkably forward thinking approach to web standards, but I can still identify with the spirit of Ian's article."
1156-2,"passage: People who develop with web standards are currently riding well ahead of the curve. We know it's the right way to do things, but telling people to do it because it's right won't get us anywhere. Demonstrate the benefits and the theory can sneak in by the back door."
1156-3,"passage: Faced with those hurdles, what can we do? Jeffrey Zeldman put it best: Show, don't sell. Redesigning a site to use CSS can slash more than 50% off the size of the page. When I was first learning CSS I rebuilt a numver of popular sites using it, and each time the resulting page was well under half the size, with less images to boot. Structural markup (in particular properly used header tags) boosts your search engine ratings. A single global CSS file allows the design of an entire site to be tweaked by altering a single file. Accessible markup opens your site up to visitors (aka customers) who could not visit it before."
1157-0,"passage: Russell Beattie has an ingenious solution to the problem caused by weblog un-savvy Google users turning up on old entries and posting comments on them, without properly understanding the nature of the site. He simply displays the page without a comments form if he spots Google in the user's referrer. I'd be tempted to do the same thing on this site if I didn't find the comments on my ancient MSN Messenger rant so amusing."
1158-0,"passage: I've started browsing the web at 1600x1200, because I have a nice big monitor and a tendency to browse with my font size set to large. At this resolution you really begin to appreciate the argument put forward by fixed-width site design advocates that liquid designs can end up plain unreadable on some setups. I could just reduce the size of my browser window, but I'm lazy. Instead I'll point out that the Rocky Mountain Harley-Davidson dealership is a liquid site that manages to look great even at ludicrously high resolutions. It's got some very decent CSS and structural markup under the hood as well."
1159-0,"passage: I'm not about to disagree, and there's not much I can add to what's already been said. Instead, I'm going to be picky about terminology. In my opinion, HTML is far more a structural language than a semantic one. The word semantic suggests meaning. Sure, marking something up as a paragraph or header is more meaningful than leaving it in a semantically uninteresting div or span, but to be truely semantic the markup would need to tell us what the element actually is - a headline, or the author of an article, or a list of navigation options for the page. That kind of information is the realm of XML. Semantic HTML elements add a small amount of meaning, but a great amount of structure - a fact that becomes particularly important when you start applying CSS. Try to derive real meaning from the simple elements provided by HTML and you'll quickly run in to a brick wall."
1159-1,"passage: Semantic markup is getting a lot of blog coverage at the moment, following a starter post by Jason Kottke. There's some great content flowing around (Dave Shea, Doug Bowman and Paul Scrivens in particular devote whole essays to the topic) but the central point is the same: just because a page validates doesn't mean it's good HTML; semantic markup is equally if not more important for building good pages."
1160-0,passage: Tom Gilder is right on target with his latest rant about sites that add accessiblity features without thinking about their consequences. Accessibility frequently involves adding new markup but you can definitely have too much of a good thing.
1161-0,"passage: Nothing though can beat a good set of examples, and the URL Rewriting Guide by the module's original author provides those in abundance."
1161-1,"passage: I think I've finally cracked mod_rewrite, thanks mainly to SitePoint. Key resources:"
1162-0,"passage: You can write your own handlers for the various parts of the Apache request. So far I've only been playing with the handler that serves up content, but it's possible to do things like create a handler for the ""Authentication"" phase that authenticates users in some special way."
1162-1,"passage: My biggest worry at the moment concerns the relative lack of documentation for mod_python on the web - the manual is pretty good, but other than that there's precious little to get your teeth in to. Luckily the module has a reasonably high traffic mailing list which has so far answered all of the questions I've thrown at it promptly and in great detail. I hope to write more about mod_python as I become more comfortable with it. If anyone has any tips, I'd love to hear them."
1162-2,"passage: So, I'm getting stuck in to mod_python in a pretty big way at the moment. I've never even used mod_perl before, so coming from PHP this is turning out to be a real eye opener."
1162-3,"passage: The key thing to realise about mod_python is that it gives you full control over the whole Apache request. Unlike PHP, you're not writing scripts that just happen to use Apache as a go between - mod_python exposes a pretty big chunk of Apache's internal API, and you are expected to hook straight in to it and start doing things. This certainly takes a while to get used to, but comes with some pretty big benefits. For one thing, your code is loaded once (well, once by each Apache process) and stays in memory. This means that global variables within your scripts persist between requests! Unfortunately, each Apache process (of which there are usually quite a few) has its own copy of the code so you can't use this persistence ability for things like sessions, but it's great for pooling database connections and keeping unchanging data such as templates in memory."
1163-0,"passage: Paul Graham's essays on fighting spam are generally excellent; it was Paul who sparked the recent flurry of activity surrounding Bayesian statistical filters and inspired the creation of some of the best tools for fighting spam yet. Paul's latest suggestion, Filters that fight back, seems to me to miss the mark in a big way. Paul suggests email servers should ""follow"" links in any email received. This would turn the tables on spam, as suddenly sending out a million spams would result in a million useless hits to the site being promoted, quickly brining it to its knees. It's a great concept, until some malicious script kiddie realises that they've been handed a tool to run massive distributed denial-of-service attacks on any domain they care to target. Not to mention that such a feature would make many legitimate mass email tools prohibitively expensive to run."
1163-1,"passage: Update: It turns out that this issue has already been discussed in the FAQ attached to the essay. The suggested solution is to use a blacklist, with servers only hitting sites that are linked to from an email and listed on the blacklist."
1164-0,"passage: My new favourite toy is SQLObject, an object-relational mapper which makes heavy use of Python's special method names to create objects which can be used to transparently access and modify data in a relational database. I tried to write something like this in PHP once before and failed miserably, but SQLObject has such an elegant design that I'm just annoyed I didn't find out about it sooner. Here's some example code, adapted from the SQLOBject site:"
1164-1,"passage: SQLObject has plenty more tricks up its sleeve: it can create class definitions by introspecting a database table, handle one to many and many to many joins, and generate complicated SELECT statements on the fly using simple, database independant syntax. It comes with support for MySQL, Postgres and SQLite. Postgres support uses the psycopg module, but we use pyPgSQL so I wrote a simple connection wrapper to support that module which I've submitted to the SQLObject mailing list."
1165-0,"passage: In the style of Mark Pilgrim, Googling for fun and profit."
1166-0,"passage: The W3C Validator team are seeking help with the latest version of their validator, dubbed the ""Zeldman Made Us Do It!"" release. They want people to play with the beta and submit suggestions for error messages that would make more sense to the average user. They also have a new feature called ""fussy mode"" which acts a bit like a lint tool for checking code, highlighting problems that aren't necessarily illegal markup but may not be best practise techniques."
1166-1,"passage: Anyone who's managed to fix up a page using the validator before will know that errors frequently cascade: one missing tag can cause a dozen or so related errors on the page, which all vanish when the initial missing tag is re-added. Further, a lot of errors boil down to exactly the same concept. If a designer has forgotten to escape the &s in the URLs on a page it could add a hundred or so extra errors to the validation results. They only need to be told once. If the validator came back with a condensed list of 6 or 7 errors along with human explanation and a note that the error occurred X times on the page it would be far less likely to send people recoiling in horror from information overload. Such a condensed report would not need to be the only interface to the validator, although I would recommend it as the default interface simply because advanced users can work out where the ""verbose"" option is themselves; it's the newbies who need a helping hand and a condensed, easily understood report."
1166-2,"passage: It's great to see improvements to error messages being made (a classic example is the head-scratch-inducing ""NET-enabling start-tag requires SHORTTAG YES"", which means you used <br /> or <img /> in a normal HTML document) but in my opinion the best thing the validator could possible do is display less errors. Let's take CNN.com as a classic example of an invalid page. Feed it through the new validator and you get a list of 206 errors that scrolls for pages and pages. The average non-standards clued up web designer is going to take one look at that list and give up on the spot: the site works in all the browsers they have tested, and fixing 206 errors is just going to be a waste of their time. I can distinctly remember thinking that exact thing the first time I tried the validator, and consequentially ignoring it for well over a year afterwards."
1166-3,"passage: I submitted this suggestion to the validator mailing list a few days ago, but as I haven't had any replies there I thought I'd throw it open to the blogging community to see what people think."
1167-0,"passage: If you start using a similar system, drop me a line and I will start using your blacklist as well (note that I will not merge it with my own public list). If I find you have been blacklisting innocent domains I will cancel my subscription to your blacklist. In this way, I hope to build a decentralised web of trust whereby other people's recommendations help my system combat spam better."
1167-1,"passage: I'm fed up with comment spam. From now on, any comment I judge to be spam will be deleted, and the domains linked to from that comment will be blacklisted. Any future comments that contain links to those domains will be refused. My blacklist will be made available as a simple text file, one domain per line, at blacklist.txt. You are welcome to grab a copy of that file once every 24 hours and use it as part of your own comment spam prevention system. I will manually approve all domains that are added to it to ensure only domains of a dubious nature end up blacklisted."
1168-0,passage: Russ Weakley's Listamatic borrows a whole bunch of fun CSS list effects from around the web and shows how they can be applied to the same markup to produce a large range of different results.
1169-0,passage: Techno Weenie has a detailed guide to setting up PySQLite on boxes you don't have root access to. SQLite looks ideal for small to medium sized applications so I can see this being really useful should I ever write something that uses it.
1170-0,"passage: Three really useful looking Python modules: ClientForm, ClientTable and ClientCookie. ClientForm looks like it provides similar functionality to the form handling part of the WWW::Mechanize perl module, discussed previously. It essentially provides a very simple interface for loading an HTML page, parsing out the form information then filling in the form and submitting it back to the server. The author recommends it for automated testing (I've always had trouble figuring out how to link unit testing in to web applications) but I'm sure it could be useful for screen scraping tools as well. ClientTable is an early beta of a powerful looking table parser, and ClientCookie sits on top of the standard urllib library and transparently persists cookies in between requests."
1171-0,passage: An example Britishness test based on proposals by the home office for a written test for immigrants applying for citizenship. I got 3 out of 10! (via Simon Brunning).
1172-0,passage: Thunderbird has to have the most deceiving version numbers of any software I've ever used. I avoided version 0.1 for ages because I incorrectly assumed that a 0.1 release shouldn't be trusted with my email. I've just upgraded from 0.1 to the new 0.2 and a good product has got even better - it's noticably faster and more responsive and they've knocked 1.5MB off the size of installer. I love the new direction the Mozilla organisation have been taking with their focus on separate applications; I wonder if we'll be seeing a spin off of Composer any time soon.
1173-0,"passage: Cory Doctorow has a new book of short stories coming out, and has released six out of nine of them under a creative commons license following the success of Down and Out in the Magic Kingdom. I just finished reading Craphound and I thoroughly enjoyed it."
1174-0,"passage: I've always wondered how fonts work. I now have a much better understanding of the technology involved thanks to Microsoft's excellent Typography site, in particular this Introduction to hinting from 1997 (via )."
1175-0,"passage: Too excellent articles on Object Oriented Design: Why extends is evil and Why getter and setter methods are evil. Ignore the inflammatory titles: the subheading of the second article, ""Make your code more maintainable by avoiding accessors"", is a much better indication of their content. I picked up some great tips on proper use of OOP from reading them. In particular, the section on CRC cards made something click which hadn't clicked when I looked at them earlier this year for my ill fated University software project."
1176-0,passage: My friend Andy's design skills have been recognised by the CSS Zen Garden. Congratulations! He's number 42.
1177-0,"passage: I've talked about image rollovers on this site before, but I've never seen a technique I like half as much as Pixy's Fast rollovers, no preload needed. Like all good techniques, it's so simple I'm surprised no one has thought of it before. The trick is that a single image is loaded containing the different rollover states, then positioned as the background of a fixed pixel size link element in such a way that only one of the states is shown. The :hover style simply changes the offset of the background, revealing the secondary (or even tertiary) state."
1178-0,"passage: Via the pgsql-performance mailing list, a great guide to Tuning PostgreSQL for performance, accompanied by a huge table of annotated configuration options."
1179-0,"passage: Retro games, 80s music. Awesome. Via NTK."
1180-0,"passage: The most interesting thing to come out of this whole Eolas disaster could well turn out to be Ray Ozzie's description of how Lotus Notes was demonstrating many of the funamental abilities of today's browsers, including dynamic application embedding remarkably similar to that covered back in the patent, way back in 1993. The patent was filed in 1994. Prior art? We can only hope."
1181-0,"passage: The results confirm the initial concern: All three leading screen readers (JAWS, Window Eyes and IBM Home Page Reader) fail to read out text that is hidden using either display: none or visibility: hidden, even when those styles are served up as part of a stylesheet targetted for visual (screen) media. This is yet another example of vendors ignoring valuable parts of the CSS specification, but until screen readers become more intelligent we're going to have to live with it."
1181-1,"passage: An even neater variant is provided by Tom Gilder on his blog, where the :active and :focus pseudo selectors are used to provide a skip navigation link that remains invisible until focussed on using the tab key on the keyboard. This technique really does provide the best of both worlds; the skip link is invisible in the standard design, but still shows up for keyboard navigation users who may find it useful. I've implemented Tom's technique in my stylesheet for this site."
1181-2,"passage: I've long heard rumours that some screen readers fail to read out text hidden using the CSS display: none property, but I had never really investigated it as I don't have access to a screen reader myself (I should really download the JAWS trial some day). Bob Easton's What do screen readers really say? describes the problem and specifies a number of tests for screen reader abilities, the results of which are collated on this Wiki page. As a side note, quickly collecting the results of this kind of test is an excellent way to make use of a Wiki."
1181-3,"passage: Luckily, a solution is at hand. Jon Hicks demonstrates that the following 4 lines of CSS can hide elements from visual browsers while leaving them available to screen readers:"
1182-0,"passage: Russ Weakley has followed up his excellent Listamatic with a useful set of tutorials on styling lists. The style of the tutorial looks worth emulating: each page adds a new property, explaining what it does and showing how it affects the list. I particularly liked the Icon lists demonstration."
1183-0,passage: Kirby Urner provides some great examples of how Python can be used as an aid to understanding mathematics on the marketing-python mailing list. I particularly liked this demonstration of Pascal's triangle using Python generators:
1184-0,"passage: I feel very strongly about this. JavaScript's syntax ism abominable...too many curly braces, semi-colons, square brackets, regular parentheses and all the claptrap symbols it borrowed from that abominable language - C - and its successor - C++ -. The hours I spent hunting for the missing semi-colon or the improperly inserted double colon and wading thru the false error messages of Borland's C v.2. It was a horriblem experience. I need you to give me your unstinted and selfless support to kill off, once and for all, that abomination called JavaScript. This is a call for sanity in scripting. Let's bring back simplicity, lets get rid of unnecessary complexity. Help ME!!!"
1184-1,"passage: Respectfully taking a leaf from you I would most strongly urge you to cease using JavaScript and instead use the much better script language, Microsoft's VBScript."
1184-2,passage: There follow two of the weirdest emails I have ever received through my contact form. The first is a fascinating rant against standards compliant client side scripting:
1184-3,passage: Eat grassfed beef...now its the real McCoy...full-flavored beef that is heart healthy and rich in Omega-3 and CLA. Try GrasslandBeef.com
1184-4,passage: The second is just plain odd. I can only guess it has something to do with this entry.
1184-5,"passage: Grain fed beef is not heart healthy...and I used to eat it all the time and really gained weight and increased my cholesterol...and now that I have found grass fed beef, it is going down and I actually prefer the taste of bland grain fed products."
1184-6,"passage: In the smae vein, I beg of you to use the DOM.all of IE exclusively and turn your back on Netscape and its clones."
1185-0,"passage: Ideas in Technology and Publishing is a great new blog covering content management, XML and other publishing related technologies. It's less than a month old so it's still possible to read through the archives in full, which I've just done and recommend to anyone with an interest in content management."
1186-0,"passage: Paul Sowden is the blogger who inspired me to start my own blog over a year ago. He's restarted his blog at a new domain: delete.me.uk. Let's hope the new site doesn't live up to its name. Oh, and be sure to view source for Paul's own special brand of minimalist valid HTML 4."
1187-0,"passage: A more interesting problem that came up today was working out the percentage of Netscape 4 visits to the Python.org site in the last month, as part of a mailing list discussion on whether or not the site should embrace a pure CSS layout. The raw data is a huge, ugly file listing 12,000 odd user agent strings along with the number of hits from each. My first step was to copy out the data part of the file and save it as a text file. I also compiled a new regular expression to find all lines that start with a number, which could then be used to ensure the data loaded was in the right format."
1187-1,"passage: OK, I now had two arrays, one featuring all of the lines in the input set and another featuring just those lines that referred to a Netscape 4 browser. The final trick is to add up the total numbers for each of those sets. Remember, the total is the sum of all of the numbers at the start of each line. First, I built up new arrays of just those numbers (as integers) using the regular expression defined previously:"
1187-2,"passage: I adore the Python interactive interpreter. I use it for development (it's amazing how many bugs you can skip by testing your code line by line in the interactive environment), I use it for calculations, but recently I've also found myself using it just as a general tool for answering questions."
1187-3,"passage: Here's a classic example. This blog entry describes a campaign to reimbuse the 12 year old girl recently fined $2000 by the RIAA for file sharing. The full amount has been raised, and a list of doners is available along with how much each donated. Being the inquisitive type I am, I wanted to know how much money was raised in total. First, I copied and pasted the list in to a Python string in IDLE:"
1187-4,"passage: When working in the interactive prompt it's a good idea to periodically check that the data you are dealing with looks how you expect it to look. I've stripped down the explanation of what I did quite a bit - in fact there was a lot more checking of variables and lists to make sure nothing had gone wrong. At this point, here's what an item in my netscape array looked like:"
1187-5,passage: Are you getting the impression that I love list comprehensions yet?
1187-6,"passage: Finding the lines that contained a user agent string for Netscape 4 took a bit of effort, mainly because of the utterly insane way user agent strings have evolved over the years. I eventually settled on the rule that anything with Mozilla/4.x in it without the word 'compatible' was probably a Netscape 4 variant. I excluded anything with 'Gecko' in it as well, but with hindsight this was unnecessary as Gecko browsers all start with Mozilla/5.x."
1187-7,"passage: And there's the answer. I think this quite neatly demonstrates the power and flexibility of the interactive prompt - for one thing, it shows that errors really don't matter as you can simply try again the next time round. It also shows that most of the time you don't even need to assign additional variables - Python is fast enough that you can just build up more and more complicated expressions. When you're just trying to find a one off answer to a problem code readability doesn't really come in to the equation."
1187-8,passage: Oops! sum operates on integers but the list is full of strings. We can use map to apply the int function to every item in the list first:
1187-9,passage: Now I can run the sum() function to add them all up:
1187-10,"passage: We now have two arrays of numbers. The total for each array can be found with the sum function, but we want the over all percentage of Netscape 4 user agents:"
1187-11,"passage: The float call is in there because Python disregards the remainder in straight integer division; by casting one of the arguments to a float floating point division is used instead. As you can see, only approximately 1.17% of visits to Python.org in August were made using Netscape 4*. The case for CSS seems assured."
1187-12,"passage: This has turned in to a longer entry than I had intended, but I hope it demonstrates the power and versatility of Python's interactive mode."
1187-13,"passage: * Please note that this figure is not entirely accurate, as it may also include web spiders that pretend to be Netscape 4, Opera users and a few other false positives as well. As an estimate though it's probably pretty good."
1187-14,"passage: All of the monetary values consist of 2 digits, so next I compiled and tested a regular expression to search for them:"
1188-0,"passage: It could be argued that the most important site that should appear when searching for the word blogs would be the generic site where anyone with a blog can get listed for her/his three minutes of fame, which includes any blog, anywhere in any system. Weblogs.com is a directory of sorts to any current post and is like, if you please, a central nervous system to the world of blogs. However, Google does not list weblogs.com as the primary site -- blogger.com is listed as the prime, first-up site in the listings that result from the blogs search. Is that because Google Inc., owns blogger.com, or is it that blogger.com is really what one would expect as the first result?"
1188-1,"passage: The above code shows that while Blogger.com mentions the word 'blogs' four times in 26,000 characters, Weblogs.com only mentions it three times in 394,000 characters! Blogger has a far higher 'blogs' word density - in fact, the only occurrence of the word on Weblogs.com is when it happens to be a part of the name of one of the several thousand blogs listed on the page at any one time."
1188-2,"passage: Further more, if you run a search for 'weblogs', Weblogs.com comes out as the number one result. It's all in the name."
1188-3,"passage: Although word density is a reasonably useful metric for telling if Google will like something, everyone knows that Google's secret sauce is PageRank, which is based in part on the number of pages linking to a site. Two quick link: searches reveal 7,840 links to Weblogs.com, but a whopping 61,500 links to Blogger.com (no doubt helped by all those ""powered by blogger"" stickers)."
1188-4,"passage: So Blogger.com not only has a higher word density for the designated search term, it also has far more links to it overall. Is it really so surprising that it's coming out on top?"
1188-5,"passage: Time to break out Python again. I won't explain the following code in detail, but essentially it downloads the HTML source of the front pages of both Blogger.com and Weblogs.com, strips out the HTML tags (defined as anything between two angle brackets) and counts the number of occurrences of the individual word 'blogs'."
1188-6,"passage: Dave Winer finds it strange that the Google Weblog (unaffiliated with Google the company) comes out as the first result in a search for 'weblog'. My guess is that this is a result of the blog's name influencing the text of links made to it - when you link to Doc Searls or myself (both of whom have 'weblog' in their site title) you can abbreviate it to ""Doc Searls"" or ""Simon Willison"", but when you link to the Google Weblog you have to use the fully qualified name or your link won't make sense. Google can be strongly affected by link text, as last year's Google bombing epidemic aptly demonstrated."
1188-7,passage: Microdoc News have a poorly researched story suggesting that Google have been engineering their search results to favour their own properties:
1189-0,passage: The actual benchmarking code makes use of the new timeit module from Python 2.3 - I copied it verbatim from that module's example section in the manual.
1189-1,"passage: 'some string'[::-1] is an example of Extended Slices, introduced in Python 2.3. Its affect is to reverse the string, by stepping through it from start to end going back one character at a time."
1189-2,"passage: There are a few points worth explaining in the above code. The (?!\D*\d) part of the first regular expression is a negative lookahead assertion - it basically means ""match the subpattern provided it isn't followed by a string of non-digits followed by at least one digit. This is the bit that ensures we only get back the last digit in the string, and is also the bit that could cause a performance problem."
1189-3,"passage: Via Ned Batchelder, an article on Reversing Regular Expressions from Perl.com. Otherwise known as Sexeger, these offer a performance boost over normal regular expressions for certain tasks. The basic idea is pretty simple: searching backwards through a string using a regular expression can be a messy business, but by reversing both the string and the expression, running it, then reversing the result far better performance can be achieved (reversing a string is a relatively inexpensive operation). The example code is in Perl, but I couldn't resist trying it in Python. The challenge is to find the last number occurring in a string."
1189-4,passage: The resutls speak for themselves: 26.82 for the lookahead assertion expression compared to just 9.26 for the reversed regular expression. This is definitely a useful trick to add to the tool box.
1190-0,"passage: If you haven't read Dive Into Python yet, you've been sorely missing out. It's all good, but the sections I've found most useful are as follows:"
1190-1,"passage: Sweet. Mark Pilgrim is working on Dive Into Python again, funded by a dead tree publisher for publication in 2004 (hopefully). The free version will stay available as well. I've always preferred reading paper to reading a screen so I'm definitely down for a copy."
1191-0,passage: (Weebl and Bob's navigation be worth an eyeball an' all.)
1191-1,"passage: It be International Pirate Day, ya scurvy landlubbers. Avast and be merry, for the day is young and the wenches plentiful. And remember t'chat up line of the day: Prepare to be boarded!"
1192-0,"passage: I don't usually get more than 5 or 6 spams a day, but today I've been hammered with an additional 7 emails with executable attachments claiming to be the ""latest critical patch"" from Microsoft. The emails are HTML formatted and make a pretty convincing rendition of a Microsoft.com page, so I can see how less savvy internet users could easily fall for them. Is this yet another virus outbreak? I make that the third in as many weeks."
1193-0,passage: I'm not the only person to have written a piratify function: Dougal Campbell has one as well (also mentioned here). I'm looking forward to seeing his released code.
1193-1,"passage: So, now that ""talk like a pirate"" day has sadly come to an end, it's time to reveal the five minute code hack that rendered my front page semi-legible for the best part of a day. It was actually pretty simple:"
1193-2,"passage: My first attempt simply applied the 6 regular expressions shown above, but they mangled links within my entries as well. The solution was to use preg_replace_callback to target only text occuring outside of HTML tags (defined as anything between a > and a <). This turned a five minute hack in to half an hour of frenzied debugging as I'd already posted the change to my site! In fact, the whole lot was written at 2am in the morning with my friend Tristan after a night out with Andy. Some how cider makes for easier construction of regular expressions."
1194-0,"passage: There's a great new article up on Sitepoint describing a technique for adding auto-complete functionality to normal HTML text input fields using Javascript. The code uses a whole bunch of browser-specific code, but it has to thanks to the unconsistent ways in which different browsers handle text selection ranges. Unfortunately the article doesn't actually provide a demo of the code in action, so I've posted one here. It's a very nice effect."
1195-0,passage: I'm comfortable using tables for forms. My point of view is that they are interactive tabular data.
1195-1,"passage: ... When an HTML page incorporates forms it starts to move away from being a ""structural document"" and towards being a ""logical interface"" instead - once I start working with forms I switch my focus from semantics to accessibility and usability. Since these share many of the same requriements as semantics (use proper header tags etc) I don't feel too guilty about using divs instead of paragraphs."
1195-2,"passage: I'd never thought of them like that before, but that view point certainly makes a lot of sense."
1195-3,passage: Just spotted in a comment by Drew McLellan on Russell Beattie's Notebook:
1195-4,"passage: I recently contributed my own opinion on trying to create ""semantic"" forms to an interesting discussion on SimpleBits:"
1196-0,"passage: It's a sad state of affairs when you come back to your blog after a week elsewhere and have to add another 56 domains to your blacklist. I'm actually getting more comment spam than legitimate comments now - this is becoming more than just a minor nuisance. I'm considering a number of improvements, including adding a moderation queue to comments on entries posted more than a month ago, disabling the comment form if the referral is a search engine (as per Russell Beattie's suggestion) and adding some kind of wildcard support to the blacklist file."
1196-1,"passage: I'd really rather not do any of this, but the problem looks like it's going to escalate."
1197-0,"passage: For reasons too numerous to list, homeless pet rats need care until they're found new homes. £15 takes care of 6 weeks feeding and even includes a health check. If, however, you're fed up with a particular 'human rat', this gift could give expression to your feelings..."
1197-1,"passage: Some friends of the family have created a brilliant charitable solution to the problem of buying a gift for someone who already has everything. The Good Gifts Catalogue sells products such as a New leash of life for homeless dogs, Ropes for monkeys living in zoos and many other cleverly titled charitable packages. The full price of every item ordered is donated to the supported charity and the recipient of the gift gets a keepsake card describing the gift given on their behalf. My favourite item from the catalogue has to be this one:"
1198-0,passage: Ned also offers clear examples of metadata in the real world and shows how the concept goes back thousands of years. If you still don't quite understand what the term means you won't have any excuses once you've read his article.
1198-1,"passage:
Metadata is information about a thing, apart from the thing itself.
"
1198-2,"passage: Ned Batchelder: Metadata is nothing new. Ned includes a far better definition of metadata than the standard ""data about data"" phrase:"
1199-0,"passage: Let's just hope the Google mantra ""don't be evil"" wins out in the end. At the moment their AdSense programme is suddenly looking a lot less tempting."
1199-1,"passage: I guess it really was too good to be true. The AdSense backlash has begun, with Eric Thauvin's dismissal from the scheme for ""invalid clicks"" prompting Russell Beattie to take a good look at the AdSense terms and conditions - which have some pretty nasty twists in them. The plot has thickened today with Google adding a new term prohibiting users from issuing any press release or mak[ing] any public statement about the subject matter of this Agreement. What's that about?"
1199-2,"passage: Google are obviously trying to cover their backs against people who would abuse the system by clicking their own ads (manually or with a script), but seem to be using draconian measures to do so. This raises an interesting question: can a malicious third party deprive their competition of advertising revenue by setting up a script to follow their competitor's Google ads, thus banning them from the service? I don't see how Google could detect such shenanigans, especially given the number of advertisers within their system."
1200-0,"passage: Alarm Bell Phrases on Ward's Wiki are just great. As with all links to the Wiki though, be warned: click too many links and hours of your life will inexplicably vanish..."
1201-0,passage: Dave Shea is running a series on designing for colour blindness: parts one and two are already available. I've found the Colorblind Web Page Filter useful in the past as a tool for understanding the problems faced by colour-blind users.
1202-0,passage: Balancing visual and structural complexity in interaction design (via Column Two) is an interesting article that shows how over-simplifying a design can harm usability rather than helping it.
1202-1,passage: It also includes a good debunking of the idea that users don't like to scroll - in this age of wheel mouses I've never understood some people's preference for multi-page articles over one page with a scroll bar. The article concludes that the real challenge is coming up with the proper balance between visual and structural complexity.
1202-2,"passage:
It's true that the more simple a page looks, the easier users can find information on it. But reducing visual complexity to make things pleasing to the eye by hiding critical information from users will inevitably increase structural complexity, and make it difficult for users to grasp and navigate the site.
"
1203-0,"passage: Ruby vs Python is currently threatening to overtake Perl vs Python as the favourite holy war amongst language geeks. I'm predisposed towards Python, mainly because I haven't seen any benefits of Ruby over Python strong enough to convince me to invest some serious time in the former."
1203-1,"passage:
Ruby inherited the Perl philosophy of having more than one way to do the same thing. I inherited that philosophy from Larry Wall, who is my hero actually. I want to make Ruby users free. I want to give them the freedom to choose. People are different. People choose different criteria. But if there is a better way among many alternatives, I want to encourage that way by making it comfortable. So that's what I've tried to do. Maybe Python code is a bit more readable. Everyone can write the same style of Python code, so it can be easier to read, maybe. But the difference from one person to the next is so big, providing only one way is little help even if you're using Python, I think. I'd rather provide many ways if it's possible, but encourage or guide users to choose a better way if it's possible.
"
1203-2,"passage: The Philosophy of Ruby is the first part of Artima's interview with Yukihiro Matsumoto (aka Matz), creator of the Ruby language. The interview touches on the philosophical differences between Python and Ruby, in particular Python's preference for having one obvious way of doing things:"
1204-0,"passage: That said, the most interesting comment I read about the leak was this one on Slashdot describing how the leak of the source code for Falcon 4.0 lead to a huge community effort to dramatically improve the original game. Since Valve already have a great history of supporting the modding community I doubt that the effects of this leak will be nearly as beneficial."
1204-1,"passage: Valve are seeking the assistance of the community to help them track down the culprit, who may also be responsible for Denial of Service attacks against their network. I think this is the most serious targetted cracking attempt I've ever read about."
1204-2,"passage: As for the source itself being available, the biggest concern seems to be that it will allow cheaters to truly rip the new Half-Life engine to shreds. I used to play a lot of online games, and nothing ruins a game more than cheating."
1204-3,"passage: Yesterday, the Half-Life 2 source code was leaked (all 100 MB of it). Today comes the news from Valve that the leaked version is indeed the real thing, and that the leak was almost certainly the result of keystroke recorders installed remotely on Valve machines using a buffer overflow in Outlook's preview pane."
1204-4,passage: Ouch!
1205-0,"passage: Introducing mod_python by Gregory Trubetskoy. One of my biggest problems with mod_python is that documentation outside of the mod_python manual is pretty hard to come by. This article is more of an executive overview than a tutorial, but anything that adds to the overall body of knowledge out there concerning mod_python has to be a good thing. I'm hoping to write some material on mod_python best practises at some point in the near future, but I have to work out what they are first. Luckily the project has an active and very helpful mailing list."
1206-0,"passage: Richard P. Gabriel's proposal for a Master of Fine Arts in Software looks like it's getting some serious consideration from the University of Illinois (via Sam Buchanan). The idea of programming as a creative art has been around for a long time, so teaching it in this way is in some ways a logical progression. Personally I'm intrigued by the focus on reading other people's code - ""the work of masters"". This is something that been sadly lacking in my BSc course at Bath. Aaron Swartz started a collection of links to Quality Software last year, but other than that I don't know of any resources dedicated to highlighting ""classic"" code that deserves to be studied."
1207-0,passage: Mimicking Magazines (via techno weenie) is a nice set of CSS styled paragraphs inspired by the design of Cosmopolitan. They resize well thanks to intelligent use of ems for sizing instead of pixels.
1208-0,"passage: I'm a bit late to the party on this one, but Paul Hammond's open letter to ""tableless"" recoders caused quite a stir a few weeks back with its extensive list of reasons that recoding someone else's site in CSS helps no one and can in fact have a negative affect on the CSS advocacy effort (the response to the article is summarised in his follow up post)."
1208-1,"passage: A year ago I would have strongly disagreed with him - the question then was whether or not CSS was even capable of creating complex layouts, and CSS redesigns were a valuable demonstration of how much could be achieved without tables. I am unsure if that argument has been won yet - there still exist legions of web developers who think CSS is a useful trick for turning off the underlines on links - but the body of evidence seems great enough now that this no longer counts as a valid reason for creating tableless remakes. Paul's main arguments rest on etiquette (it's rude to dismiss someone's work by recreating it), and it's hard to disagree with him there."
1208-2,"passage: Paul is right that publishing CSS remakes of existing sites with no good reason is no longer appropriate, but as a tool for education this activity should not be under-estimated."
1208-3,"passage: That said, I remain a huge fan of tableless recoding as a tool for education. I myself have a collection of over a dozen recreations of existing sites in CSS, the majority of which I have never publicised and have no intention of doing so. While I was learning CSS (and I doubt you can truly ever finish learning it) I used to recode existing sites at a rate of one or two a week, targetting sites with designs that looked particularly well suited to tables. I learnt a great deal doing this, and I would recommend it to anyone still getting to grips with CSS positioning."
1209-0,"passage: Spotted on City of Sound, via Paul Hammond:"
1209-1,passage: [...]
1209-2,"passage: I'm not looking for a job, but if I was I'd jump at the chance."
1209-3,"passage: And now, we're looking for a couple of software engineers,
initially on a 6-month contract - good solid programmers, based around
Perl, Python etc. Helping make public-facing apps like Challenge Lawro,
building internal workflow tools like the wiki Tom wrote about recently, doing R&D stuff around DAB Java, all kinds of things."
1209-4,"passage: Folks will know I don't usually do this kind of thing, but ...
we're hiring. I'm looking to add to our Technology and Design team at
BBC Radio and Music Interactive. We're responsible for designing and
building all the BBC's radio and music-based interactive services, from
our radio and music web-based products, through to our new DTV channels and WAP services. I manage the team."
1210-0,"passage: Finally, the code uses an error handling technique I picked up on Ward's Wiki called the SamuraiPrinciple, which states you should either complete your contract and return a valid result, or throw an exception. This is used by the handlers and the main date parsing function itself, with thrown exceptions only caught by the magicDate function attached directly to the onblur event of the input box."
1210-1,"passage: The CreativityGoblin dropped in on me today, and as a result I've been tackling the challenge of entering dates in to a web application. In the past, I've used DHTML calendar widgets for this purpose (my favourite is Mishoo's highly configurable, standards compliant JS Calendar) but while widgets like this have a great deal of ""wow"" factor I'm not convinced that they are the best entry mechanism when it comes to raw user speed. Today's experiment was partially inspired by PHP's strtotime function, which accepts a string in a wide variety of formats and converts it in to a time."
1210-2,"passage: I wanted the same thing but in Javascript, as interfaces like this are best carried out on the client without needing a round trip to the server to check any entered data. Here's a demo of what I came up with (javascript code here). It accepts a number of different input formats and converts them to a standardised mm/dd/yyyy (American style dates because it's for use in an American piece of software) when you move the focus away from the box. Importantly, the date is shown in two places: in the input box itself and in ""Mon Oct 06 2003"" format as text below the date entry field. This second display serves two purposes. Firstly, by displaying the date in an unambiguous format mistakes are easier to spot (especially important considering the American date format used in the main input). Secondly, it provides a useful place to display error messages should the script fail to parse some input."
1210-3,"passage: There are still quite a few improvements that could be made to the code: more input styles (easily added by extending the main data structure), better planned functions and maybe a clean up to move more of the code out of the root Javascript namespace. For the moment though it serves my purpose just fine."
1210-4,"passage: Update: It wasn't the Creativity Goblin after all - it was the goblin of someone elses half remembered idea. It turns out my friend Andy wrote something very similar to this back in July. Thinking back, I can remember seeing it as well. Despite not being original it's still a very useful piece of code."
1210-5,"passage: The Javascript itself was quite fun to write, and uses a number of interesting idioms I've picked up over the past year. It adds a 'filter' method to Javascript's Array class to better support functional programming (in fact I use it to match partially entered month and weekday names) and an 'indexOf' method identical to the one provided by the String class. The majority of the work is done by a data structure called dateParsePatterns, which defines a set of pairs of regular expressions and handler functions. The regular expressions match a n input style and extract any useful information; the handler functions then create a Date object from the extracted information and return it to the caller."
1211-0,"passage: Hans Nowak has been churning out some really interesting Python stuff recently. He's been experimenting with Self style objects in Python (similar in many respects to objects in Javascript), developing Wax, a coder friendly wrapper around wxPython, working on a Python framework for writing text adventure games and most recently experimenting with streams in Python using generators."
1211-1,"passage: Streams are a fascinating concept: they provide a way of defining infinite sized data structures, such as an array of all numbers that are multiples of 7. By only calculuating items when they are requested these seemingly impossible data structures can exist and be processed in a similar way to normal arrays. As Hans points out, Python generators aren't quite as elegant for this purpose as Scheme's stream implementation or Haskell's recurive list declarations but this use for them does help show why generators are such a powerful tool."
1212-0,passage: As with almost all hacks it looks pretty revolting. My recommendation is to accompany all hacks like this used in live stylesheets with a commented link to the page describing the technique.
1212-1,"passage: Tantek has created/discovered a new CSS hack, the Mid Pass Filter. This filter allows you to write CSS rules that will only be applied by IE 5 and IE 5.5 for Windows. This is great news, as those are the browsers with the broken box model (provided you trigger standards mode in IE 6)."
1213-0,"passage: You may well ask what I'm doing on the Neighbours messageboard in the first place. Let's just call it a guilty addiction - the temptation of 25 minutes of brain-dead telly at lunch time just proves too much. I check out the message boards because they have a great tradition of posting acerbic reviews of each day's episode, which are far more entertaining than the actual show."
1213-1,"passage: Here's something I've never seen before. The BBC's Neighbours messageboard currently has a note up saying ""This messageboard is currently closed"", with a link to the opening times: 9am until 10pm weekdays, opening 10am at weekends. You can still read the forums but you can't post anything. This is obviously a moderation tactic to ensure there is always an administrator available to delete offensive material should any be posted - I'm writing about it here because I've never seen this approach used before."
1214-0,"passage: The single most important thing to know is this: You cannot turn up at the Embassy without an appointment! I nearly missed this detail and went down to London without one, which would have been a wasted trip. You make an appointment by calling the Embassy's live operator service, currently on 09055-444-546 and charged at £1.30/minute. As far as I know there is no other way of booking an appointment."
1214-1,"passage: My appointment was set for 9am on a Friday morning, approximately 3 weeks after I made the call. A few days after making the call I received an envelope in the mail with full instructions on what I needed to bring to the Embassy. This included the DS-2019 form mentioned previously, plus forms DS-156, DS-157 and DS-158 (all of which were included in the envelope; they can also be filled out and printed online). I also needed a valid UK passport, a 2 inch square colour photograph, a self addressed Royal Mail special delivery envelope, proof that I had paid the visa application fee and documents to support the fact that I wasn't planning to move to the US permanently as an illegal immigrant. I used a letter from my University confirming I would be entering the final year of my degree in 2004. The letter also mentioned that I needed ""confirmation that your admission has been entered into the SEVIS database"" but as far as I can tell this was covered by the DS-2019 form sent by AIPT."
1214-2,"passage: The forms turned out to be the easy part; the hard part was obtaining the photo, payment proof and special delivery envelope. The envelope I bought from a post office or around £7. The photo I got from a specialist photographer on Oxford Street (Passport Photo Service) for £6 - as far as I can tell the American 2 inch format is not available from passport photo machines. Additional details on the photograph as well as suggested suppliers are available on the Embassy website. Again, this information was included in the information sent by the Embassy. Finally, the proof of payment involved taking a form sent by the Embassy to a branch of Barclay's bank (HSBC didn't know how to process it) and paying the bank clerk a £67 fee."
1214-3,"passage: My appointment was at 9.30am. I arrived at 9.10am (the closest tube station is Bond Street; do not go to Hyde Park corner as it's a longer walk than you might think) and joined a huge queue of people waiting to get through security. I made it in to the Embassy just after 10am; luckily it seems that the security queues mean most people miss their appointment time and it's not a problem if you do, but I still recommend arriving earlier than I did. Once inside, there was another queue to hand my documents over at a window. Then I sat down and waited for them to call my number. Once called, I was interviewed briefly at another window about what I would be doing in the States and a few personal details, then told that my visa had been approved and would be mailed to me in 7 to 10 working days. And that was it."
1214-4,passage: A final piece of advice: special delivery envelopes are tricky things. Open carefully and hopefully you won't make the same mistake I did!
1214-5,"passage: Repeated disclaimer for people coming in via a search engine: I am not a visa expert. This article describes the process I went through to get my J-1 academic visa in the hope that it will be useful to someone else trying to obtain the same thing, but for any visa application you need to do your homework, read your way around the official site and double check everything. Oh, and allow at least several months for the overall process."
1214-6,"passage: We paid an express processing fee and waited only a few weeks, but without the fee it could have taken longer. AIPT then sent me the key to my visa application, a DS-2019 form entitled ""Certificate of eligibility for Exchange Visitor (J-1) Status"". This was one of three forms which I had to present at the US Embassy in London."
1214-7,"passage: I applied for a J-1 academic visa, which is a Nonimmigrant visa specifically designed for educational visitors. Nonimmigrant means you aren't planning to move to the States permanently. In order to qualify for a J-1 visa you need to by a member of an officially approved program sponsored by an educational or other nonprofit institution. I went with AIPT. The first part of the application process involved the company I am training with contacting AIPT, followed by a whole bunch of forms and a registration fee."
1214-8,"passage: I'm going to describe the application process I followed here, because the information on the official site can be a bit confusing. These tips apply to University students who are UK citizens and wish to take a (paid) industrial placement in the United States as part of their degree course. This is what I had to do; your circumstances may differ, and no garauntees are made as to the accuracy of this information. This information is likely to be of very limited interest to anyone not planning to take an industrial placement in the USA."
1214-9,"passage: I received my J-1 Visa for 11 months in the US this morning, accompanied by my certificate of eligibility for J-1 status. I promptly cut the certificate in half with a pair of scissors while opening the envelope, but a call to the Embassy has confirmed that it's still valid and will still get me in to the country."
1215-0,"passage: I might alter the interface a bit in the future, maybe creating an extended version of the datetime class itself, but for the moment this serves my purposes just fine."
1215-1,"passage: In switching from PHP to Python I'm discovering an increasing number of PHP functions that I've learnt to rely on but have no direct equivalent in the Python standard library. Often Python simply provides a different way of approaching the problem, but old habits die hard and I've been replicating some of PHP's functionality in Python for my own personal use."
1215-2,"passage: Python 2.3 introduced the datetime module, which has comprehensive support for performing calculations on dates. Users of earlier Python versions can still benefit from the module thanks to a pure Python implementation available here. datetime objects can be formatted as strings using the strftime method, documented here; PHP offers a similar function. strftime() is a powerful function which takes full account of the current locale when formatting dates. PHP's date() function ignores the locale but provides a far richer set of formatting options, including my favourite: the ability to display a date with an ordinal, for example ""7th October""."
1215-3,"passage: I've always preferred date(), so I've ported it to to Python. My version supports most of PHP's date format options, raising a NotImplemented exception for any that are unsupported. Usage looks like this:"
1215-4,"passage: The class works using a neat piece of introspection. Each of the available formatting options is implemented as a method of the class which returns that part of the date formatted in the correct way. For example, the 'a' command (for returning 'am' or 'pm' in lower case) looks like this:"
1215-5,"passage: The format method simply cycles through the characters in the format string, attempting to call the method of that name each time round using getattr(). If a method doesn't exist (i.e the character isn't one of the special formatting commands) a try/except block catches the thrown AttributeError. The whole method looks like this:"
1216-0,passage: Blogs just stopped being cool.
1218-0,"passage: It's not a new idea (Feedster has been doing it for a while) but it's a first for a major search engine: Yahoo are now offering RSS feeds of the results of searches within Yahoo news. The feeds are advertisement free, probably because you have to click through to the news stories to read them in full. I wonder how long it will be before someone starts offering custom feeds like this with advertising in the feed itself? As RSS is an XML format parsing out adverts before they get to the user is a much more obviosu step than ad-blockers in web browsers."
1219-0,passage: Blogged so I don't lose it (blogging as external memory):
1219-1,passage: Update: See comments for improved version.
1220-0,"passage: But then, because you're curious, you start using it. The first thing you notice is that (if you had good formatting habits to begin with) the indenting issue goes away. You were going to do it that way anyway, right? Then you notice that you got the job done in less time than you realized it would take. Personally, that's my favorite bit. The ""It's done already? And it works?"" feeling. I love it."
1220-1,"passage: I've had that ""It's done already?"" several times over the past few days. It's actually quite disconcerting - you flesh out a code idea, run it... and it works. And it's finished. And it's generally in good enough shape to be used as-is. I think part of the reason is that I constantly have the interactive prompt open to try out code snippets, so most of the syntax errors and misunderstandings about how a language feature work have been dealt with before I even commit a line of code to my text editor."
1220-2,passage: David Brown: Python is a time bomb (in a good way):
1220-3,"passage: Python is a time bomb. I've yet to see someone run with it the first time they are exposed to it. We all know the drill. ""Indenting for block structure?"" ""Why should I use Python when I can do all that in Perl?"" and the ever popular ""Scripting languages are not for serious programs."""
1221-0,passage: Check out Firebird Help for the definitive list of keyboard shortcuts and mouse shortcuts.
1221-1,"passage: Finally, Ctrl+K focuses you on the quick search box at the top, and F6 or Alt+D jump you to the URL bar itself."
1221-2,"passage: I've been using these for ages, but in case you haven't heard about them here are some handy shortcuts involving Firebird's URL bar:"
1222-0,"passage: Update: Sencer has pointed out in the comments that PageRank persists over redirects, and Google appears to ignore robots.txt when used to hide a redirecting page. I've updated my redirection script to use javascript to power the redirect (with a link for people with javascript disabled) and an extra meta tag to remind Google not to follow the link. This has the unfortunate side effect that referral information no longer persists across the redirect."
1222-1,passage: I've added a new anti-comment-spam measure to this site. The majority of comment spam exists for one reason and one reason only to increase the Google PageRank of the site linked from the spam and specifically to increase its ranking for the term used in the link. This is why so many comment spams include links like this: Cheap Viagra.
1222-2,"passage: Cut off the PageRank boost and you cut off the advantage of spamming, simple as that. I've altered my comments system to redirect ALL outgoing links through a simple redirect script, and added that script to my robots.txt file. Links still work fine (even the referral information persists across the redirect) but Google will ignore them completely when calculating PageRank."
1222-3,passage: Will this reduce the floods of comment spam my site receives? Probably not; I've added a note about the restriction to my 'add comment' form but I doubt many spammers bother to read much about the sites they are targetting. What's really needed is for this technique to become widespread by being integrated in to existing blogging tools - are you listening Moveable Type hackers?
1223-0,"passage: Enough of the theory: the web needs practical advice on developing Unicode enabled web pages and web applications. Is it just a case of ensuring my text editor is ""saving as Unicode""? What about storage - can I throw Unicode at MySQL and expect it to come out again? If I serve a page up with Japanese characters in it, what will my users have to do to be able to read them? It's a big, confusing world out there."
1223-1,"passage: These should all be required reading for anyone involved in programming and web development. Unfortunately, they all lack one critical aspect: practical advice. Having read all three I feel like I could lecture for an hour on code points, glyphs, ASCII, byte-order and a whole bunch of other topics. When it comes to updating my blogging system to support comments written in Japanese I'm still almost as clueless as I was before I read any of the above."
1223-2,"passage: Joel Spolsky has joined Tim Bray in the quest to educate the masses as to the importance of Unicode. Dan Sugalski kicks in as well with What the heck is: A string, a lengthy essay about string handling and why it really is a lot more complicated than you think it is."
1224-0,"passage: I'm going offline for a couple of days. The next time I post I'll be in Kansas, for the start of my 11 month placement at the Journal-World."
1224-1,"passage: Russ Weakley's latest offering, Floatutorial, is probably the single most valuable CSS tutorial I've seen to date. Floats are one of the most powerful constructs offered by CSS, but they are also the hardest to master. Floatutorial provides a clear introduction to the theory behind floats, then dives straight in with a series of 9 tutorials that take you from using simple floats to align images right up to building a liquid 3 column layout using floated divs. If you haven't yet mastered floats you owe it to yourself to read this tutorial; if you feel you have mastered them its worth looking through to pick up some ideas. The more tutorials like this the better."
1225-0,"passage: I've only written one entry for it, but it's already clear that writing a personal blog and writing a technical blog involve very different styles. It'll probably take me a while to get settled in over there."
1225-1,"passage: I've set up a new blog, A Year in Kansas, to chronicle my adventures during my 11 months in the States. I'm going to keep my two blogs pretty much separate; my Kansas blog is going to be squarely targetted at friends and family who want to know how I'm getting on, while this blog will remain focused on my geekier interests."
1225-2,"passage: Incidentally, the new blog is running a bare bones implementation of my re-engineered blogging system, which is developed along the lines of ""the simplest thing that could possible work"". I'll be adding new features such as comments as and when time permits. That's if I don't decide to start from scratch in Python of course ;)"
1226-0,passage: Update: On closer inspection the additional divs aren't nested within each other; they are individually positioned to achieve the desired effect.
1226-1,"passage: Chris Hester's 3D Border Demo 2 (via Web Graphics) is an impressive demo of just how much you can achieve with CSS borders. His Tips & Demos collection is worth browsing through as well; I particularly liked this Shadow Demo, although markup purists may be distressed by the number of nested divs. The sooner we can use the CSS3 ::outside pseudo element to achieve effects like this without the surplus divs the better."
1227-0,"passage: I'm hoping that the SIG can work to bring together some of the work being done with web frameworks within the Python community. As demonstrated by this wiki page, Python users are spoilt for choice when it comes to selecting a framework for developing web applications. This is a dual edged sword - on the one hand diversity is a good thing, but on the other hand actually chosing a framework for a project has become a lengthy and arduous task. A few web frameworks (such as mod_python) are partially standardised around the interface defined by Python's CGI module, but this module has some severe shortcomings (the greatest of which is probably an inability to distinguish between GET and POST data). I would like to see the SIG define a more capable interface that covers more common web abilities, then encourage existing frameworks to provide a compatability layer for that interface. That way, developers could code to the standard interface safe in the knowledge that selecting and moving between frameworks would require very little in the way of changes to developed code."
1227-1,"passage: Python now has a Web SIG. SIGs are Special Interest Groups, each with a target to develop and improve a certain aspect of the Python language, standard library or community. The Web SIG has two purposes: create a plan for improving Python's web client abilities (including things like the ability to parse CSS) and work on improving Python's server side capabilities."
1227-2,"passage: The SIG is open to all, so I encourage anyone with an interest in Python's web programming capabilities to sign up and get involved."
1228-0,"passage: My colleague Adrian is putting together a meetup for web designers and developers in the Lawrence, Kansas area on Monday evening. The venue is yet to be decided but we're looking to book somewhere for dinner with an atmosphere that's conducive to lively conversation. Likely attendants so far include Adrian Holovaty, Travis Beckham, Anitra Pavka, Dan Cox (designer for ljworld.com, lawrence.com and kusports.com) and myself. If you're a web developer/designer in the area and this sounds like your kind of thing drop Adrian a line for more information. It should be a lot of fun."
1228-1,passage: Update: Adrian's site now has a more details of confirmed attendants.
1229-0,passage: The final job is to convert the above in to PHP:
1229-1,"passage: I've added a comment system to my new Kansas blog. Since the target audience for that site is friends and family rather than fellow web developers, I've taken a very different approach to processing the input from comments. While this blog insists upon valid XHTML and gives very little help to comment posters aside from highlighting validation problems, my new site's comment system takes the more traditional root of disallowing HTML while automatically converting line breaks and links."
1229-2,"passage: The standard way of doing this with PHP is to use the nl2br function. I've never been a big fan of this method as I prefer blocks of text to be surrounded by paragraph tags. Luckily, adding paragraph tags to blocks of text is a relatively easy task. Here's the pseudo-code, mocked up in Python because it's quicker to experiment with than PHP:"
1229-3,"passage: The above code splits the text block on any occurrence of a double newline, then wraps each of the resulting blocks in a paragraph tag (after stripping off any remaining whitespace) before joining the blocks back together with a pair of newlines between each one - because I like to keep my HTML nicely formatted. What it doesn't do is handle any necessary <br> tags. The trick now is to replace any single line breaks with <br> without interfering with the paragraph tags. The easiest way to do this is to put the replacement inside the loop, so that only line breaks that occur within a paragraph are replaced. Here's the updated list comprehension:"
1229-4,"passage: I have no doubt it could be improved, but my tests so far have shown it to be good enough for the job at hand."
1229-5,passage: Here's the finished PHP function:
1229-6,"passage: That's the line conversions handled, but there are a few other important steps. Any HTML tags entered by the user need to be either stripped out or disabled by converting them to entities. Converting them to entities carries the risk of ugly failed attempts at HTML appearing on the comments page, but stripping tags carries an equal risk of innocent parts of a legitimate comment (such as a <wink>) being discarded. I chose to go the entity conversion route but force commenters to preview their comments before posting them, a trick I picked up from Adrian's blog. The final step is to automatically convert links in to <a href=""""> tags. I achieve this using a pair of naive regular expressions in the hope that the preview screen would avoid them mangling comments in a way not intended by the author."
1230-0,"passage: Moderation is a topic that goes hand in hand with online communities, but despite being a highly complex matter it is rarely given the coverage it deserves. That's all set to change now thanks to Tom Coates' excellent new blog, Everything in Moderation. The site's topic is ""creative ways to manage online communities and user-generated content"", and the content posted so far easily lives up to that claim. Of particular interest are the introductory post, the definitions of the four principle types of moderation and a fascinating entry about using stealth moderation tactics to deter abusive posters. Definitely one for the blogroll (at least once it starts pinging blo.gs)."
1231-0,"passage: The first step is to split the string in to an array of words (or tokens) by exploding it on spaces. Spaces are ideal for this as they're the one character we can garauntee won't appear in a link - or at least not one that people are likely to paste in to some text in the expectation that it will be converted. We can now concentrate on each word in turn. If it starts with http:// or www. then we can treat it as a link - but what about the trailing punctuation? If we know the characters we don't want to appear at the end of the link (I use .,'"")(<>;:) we can simply chop off those characters from the end of the link one by one until we get to a character not represented in our block list. To preserve the formatting of the original text we should store each of the eliminated characters and tag them back on once the link has been created."
1231-1,"passage: The only step left is to add in the HTML for the link, then reconstruct the original text by imploding the array back down to a string separated by spaces. Here's the finished function:"
1231-2,passage: It doesn't cover every eventuality (the fuzzy nature of the problem makes that a pretty thankless task) but it handles most cases admirably well. If you want to try it out I've set up a demo page that uses the function right here.
1231-3,"passage: Regular expressions are powerful beasts. It's quite possible that one could be constructed to avoid the problems mentioned above, making extensive use of arcane tricks such as negative lookahead assertions (say that quickly five times) and non-backreferenced atoms. The readability of a regular expression converges towards zero the more these tricks are employed, so I for one prefer to avoid them. Instead, the whole operation can be achieved using a combination of simple string operations."
1231-4,"passage: The problem is the age-old challenge of automatically converting URLs embedded in a piece of text in to links. The standard way of doing this is with regular expressions, as I demonstrated in my previous entry. Creating a reliable regular expression for spotting a link is actually a pretty big challenge; creating one that can deal with the vagaries of typed text even more so. Two common details that normally trip up regular expression based link parsers are as follows:"
1231-5,"passage: The other question of course is what we should be looking for in the first place. To keep things simple, I only consider tokens that start either with ""http://"" or with ""www."" as these are by far the most common ways in which a link is included in plain text."
1231-6,"passage: Update: The above code contains a couple of subtle bugs, mostly relating to line endings. I've posted an updated and improved version on the demo page."
1231-7,"passage: I pair-programmed this code with Natalie just over a month ago, and I've now added it to my Kansas blog simplified comments system as mentioned earlier."
1232-0,passage: Friends don't let friends...
1233-0,passage: Travis Beckham's podLob features 56 experiments in Flash and 19 in Javascript/DHTML. I particularly liked the Flash image transitions. I'd probably complain bitterly I came across that kind of effect on a real site but as experiments they're fascinating and great fun to explore.
1234-0,"passage: So far, the best example of a powerful tool for manipulating this stored XML has been XSLT. XSLT has its fans, but is also often criticised as being unintuitive and having a steep learning curve. XPath is a far better example of a powerful, easy to use tool that can be brought to bare on XHTML content."
1234-1,"passage: For an example of how powerful XPath can be on a much larger scale, take a look at Sam Ruby's XPath enabled blog search feature."
1234-2,"passage: Enough talk, here's an example of what I mean. The following code snippet creates a Python dictionary of all of the acronyms currently visible on the front page of my blog, mapping their shortened version to the expanded text (extracted from the title attribute):"
1234-3,"passage: The above code is slightly more complicated than the first example, as using XPath with a document that uses XML namespaces requires some extra work to register the namespace with the XPath parser. Still, it's a pretty short piece of code considering what it does."
1234-4,"passage: Why is this so exciting? I've been saying for over a year that XHTML is an ideal format for storing pieces of content in a database or content management system. Serving content to browsers as HTML 4 makes perfect sense, but storing your actual content as XML gives you the ability to process that content in the future using XML tools."
1234-5,passage: The Python libxml2 bindings make running XPath expressions incredibly simple. Here's some code that extracts the titles of all of the entries on my Kansas blog from the site's RSS feed:
1234-6,passage: A full XPath tutorial is available.
1234-7,"passage: XPath is a beautifully elegant way of adressing ""nodes"" within an XML document. XPath expressions look a little like file paths, for example:"
1234-8,"passage: This morning, I finally decided to install libxml2 and see what all the fuss was about, in particular with respect to XPath. What followed is best described as an enlightening experience."
1235-0,passage: Evan Williams on Google's intranet weblogs:
1235-1,passage: Markup question: I used a definition list in the above quotation - was this appropriate? Is there a better way of marking up this information?
1236-0,passage: A snippet from Every Language War Ever:
1236-1,passage: I2: A programmer can write unmaintainable code in any language. Let's compare a carefully prepared code snippet from MFL with a horrifically bad snippet from YFL written by a drunken monkey.
1237-0,"passage: The redesign is currently being discussed on Webdesign-L, and the general consensus is that it's a bit of a disappointment. I agree; while a perfectly servicable and attractive design to me it gives off the air of a well designed weblog rather than a cutting edge web design and development magazine."
1237-1,"passage: A List Apart has unveiled the long awaited redesign, and is celebrating it's third manifestation with three brand new articles."
1237-2,"passage: Of the three new articles, the best by far is Doug Bowman's Sliding Doors of CSS, which describes in great detail how multiple background images applied to nested elements can be used to create a set of elegant, size-expandable tabs. Multiple nested backgrounds are not a new idea, but I haven't seen Doug's technique of creating a narrow image for the left hand side which overlaps a much larger right hand image before. I'm sure we're going to see a lot of interesting variations on this in the next few months."
1237-3,"passage: Joe Clark's Facts and Opinion About Fahrner Image Replacement confirms the now widely accepted fact that display: none; hides content from screen readers, rendering the Fahrner Image Replacement technique obsolete. According to the author, the article was completed some time ago and thus does not cover more recent innovations in the field of image replacement, such as the Leahy / Langridge hack."
1237-4,"passage: The third article, Random Image Rotation, introduces a simple PHP script for randomly serving up an image from a directory. I've always found the server side development material on ALA relatively uninspiring, but I guess this is because the target audience of the site is more designers than developers."
1237-5,"passage: It's worth mentioning that the site's information architecture has been completely redone, making it far easier to dig through the excellent material in the archives. All in all it's great to see the site back again, and I look forward to reading new material as it arrives."
1238-0,passage: I think this goes a long way to explaining why a lot of people dislike the Wiki format.
1238-1,"passage: The first thing you have to understand is that because we made wiki easier for authors, we actually made it harder for readers. There is an organization there, and the organization can be improved, but it isn't highly organized. So the feeling for a reader is one of foraging in a wilderness for tidbits of information. You stumble across some great ones and you say, ""This is fantastic, why doesn't somebody just make a list of all the great pieces so I don't have to look at the rest."" In other words, ""Why doesn't somebody organize this so I can get answers to my questions quickly?"" Sooner or later they realize, ""Gee, I could do that."" They put in a month or two of finding what they care about, and then they make a page, which is their take on what the organization of wiki is."
1238-2,"passage: Artima have published the first installment of Bill Venners' Conversation with Ward Cunningham, which focuses on the Wiki. When asked how readers can get a bigger picture of what is going on in a Wiki, Ward responds with this:"
1239-0,"passage: Knoppix auto-detected everything - from my graphics card and network (I guess it used DHCP) right up to the scroll wheel on my mouse. There was a moment of confusion when it came up with a 'boot?' prompt, but it turned out I just had to hit enter for it to start auto-detection (the prompt appeared to be for advanced users to specify additional options). After that, it booted straight in to an attractively set up version of KDE 3. The ease with which it started up was the first pleasant surprise, but what really impressed me was the huge amount of software that came on that one CD. As well as KDE, Knoppix comes with the full Open Office and Mozilla application suites, all the usual Linux tools and editors, plenty of multimedia software, the GIMP (a photo editing program similar to Photoshop), even Python 2.3. Everything was available through the KDE application menus, and everything Just Worked."
1239-1,"passage: So, I finally tried Knoppix today. I'd heard a lot about it and was ready to be impressed, but it still took me by surprise. If you haven't heard of Knoppix, it's a full Linux distribution on a CD that is designed to boot straight from the CD, without you needing to install anything and without you having to worry about it modifying the contents of your hard drive."
1239-2,"passage: Getting it running was pretty simple. I had to change the boot order in my BIOS so that my PC would try booting from the CD before the hard drive (not difficult at all: hit delete as the PC is booting up and the option for changing the boot order was pretty obvious, at least on my machine), then all it took was inserting the CD and powering up the computer."
1239-3,"passage: The icing on the cake though was WINE. WINE is an emulation layer for Linux that allows you to run Windows applications. I had heard about it, but always been put off trying it because it sounded so complicated. Knoppix comes with WINE already installed, so I figured there was nothing to lose by trying it out."
1239-4,passage: wine notepad.exe
1239-5,"passage: Windows notepad loaded up in a new, KDE style window. Wow."
1239-6,"passage: Knoppix mounts your Windows hard drive (in my case as hda2) as read only, so you can play with your existing files without fear of damaging them. I browsed around my Program Files directory and tried to run WINE on various applications. Several failed, including Internet Explorer (hardly essential software, but useful for testing). I don't know if this is because they do weird, screwed up things that WINE doesn't yet know how to handle or if they were upset that they couldn't read the filesystem. Whatever the reason, I was blown away by the fact that any of it worked at all. When UltraEdit loaded under Linux I positively cackled."
1239-7,"passage: I've only made one venture in to Knoppix land so far, but it really was everything as good as people had said it was. If you have access to a CD burner and a fast internet connection you owe it to yourself to try it out."
1240-0,"passage: Altogether they have been highly productive and successful sessions. Our plan now is to pair program the system core, then work separately on the additional modules that don't have major dependencies on each other. There are only two of us developers working on the project so pair programming the whole thing isn't really practical, but the benefits of working together the core modules are obvious."
1240-1,passage: One last thing: it was a lot of fun!
1240-2,"passage: I've spent a few hours over the last two days pair programming with Adrian. We're working on a pretty huge project at the moment, and we've just started work on the coding phase, overlapping the design phase. I had tried pair programming a few times before with some success, but this time in particular the benefits of the approach were crystal clear. In total, we've defined 4 database tables, a number of functions and a simple class. Working separately we would almost certainly have created more lines of code. However..."
1241-0,passage: Now this is cool: The joy of flush() shows how PHP's flush() function can be used to send data to the browser before a page has finished rendering. Check out Ben's demo page to see the trick in action.
1241-1,"passage: I've seen this in use on a few sites for progress indicators, but I'd never realised how easy it was to achieve in PHP. The progress indicator trick is pretty neat - it generally works by having a progress indicator widget that can be modified by javascript, then flushing a <script> element with a call to the progress incrementing function whenever an operation in the server side code has been completed. I've seen it used for IRC style chat applications as well, but I've always been concerned about the server resources that must be tied up in serving multiple persistent connections at once."
1242-0,passage: I wonder if it will be possible to transform XAML in to XUL using XSLT?
1242-1,passage: Update: It has been pointed out that the author of the above blog entry is not a Microsoft employee.
1242-2,"passage: Sound familiar? It should do - that's exactly what XUL does. On the plus side, this completely validates the grossly under-appreciated importance of Mozilla's biggest secret. On the negative side, this looks set to represent the ultimate browser lock-in - in a few years time when IE 7 comes as standard on new PCs I wouldn't be surprised to see the corporate software development world moving almost exclusively to this technology - after all, it's going to be extremely easy both to develop and to distribute and it will have all of the benefits of a web application without the downside of the restricted GUIs offered by HTML."
1242-3,"passage: Of course, Microsoft might make it an open standard. But then I might win the lottery next week."
1242-4,"passage: According to this Microsoft blogger the reason IE development has seemed quiet of late is that they've been working hard on XAML, an XML Application Markup Language which is a way to create applications in the browser (or out for that matter) [...] It is basically an XML structure with CSS and JavaScript. The CSS defines the appearance and the JavaScript dictates behavior."
1243-0,passage: How important is the ability to tell the difference between data sent by POST and data sent by GET (i.e in the query string) when developing web applications? Some web frameworks (such as PHP) provide separate mechanisms for accessing POST and GET data. Others (such as Python's cgi module) provide a single interface to form information that doesn't distinguish between the two. I already have a strong opinion on this but I'm going to leave it open for discussion here for a bit before weighing in.
1244-0,"passage: A complete implementation of the XUL box model. Safari on Panther supports the complete XUL box model, including horizontal and vertical boxes, the ability to flex, and the ability to reorder content and reverse content. If you're building canned content that you control using WebKit, you'll find a whole new range of layout possibilities at your disposal. Need to create dynamically sized headers and footers and flexible center content? The XUL box model can do that. Need to center an object within the viewport? The XUL box model can do that too."
1244-1,"passage: Safari 1.1 is included with the new release of Mac OS X, Panther. From Dave Hyatt's list of Safari 1.1 features:"
1244-2,"passage: With Microsoft's alternative to XUL seemingly a few years away, are Apple looking to beat them to it with an implementation that's compatible with Mozilla?"
1245-0,passage: Here's the magic part though. If you put part or all of the regular expression in parenthesis the separating tokens get included in the resulting list:
1245-1,"passage: Simple parsing and replacement of easily identified tags can already be achieved using the re.sub() method, which allows you to provide a callback function to process each matching token. The difference with using re.split() is that you can easily take in to account the order of the tokens, allowing you to build systems that can use special tags to define areas of documents without getting confused by nesting tag sets. As a simple example, you could build a basic event based XML parser using just a couple of expressions. In fact, I discovered this technique while examining the source code for the tinpy tiny python template module, which gives a clue to why I'm so interested in it."
1245-2,"passage: Having discovered this feature in Python, I just had to see if it existed in other languages as well. Unsurprisingly it does; PHP's preg_split offers an optional PREG_SPLIT_DELIM_CAPTURE flag (added in PHP 4.0.5) and Javascript has similar behaviour to Python, including the splitting token if it is wrapped in parentheses."
1245-3,"passage: A couple of Python tips. The first is really a tip for Mozilla/Firebird: You can set up a Custom Keyword for instantly accessing Python module documentation using the string www.python.org/doc/current/lib/module-%s.html - I have this set up as pydoc, so I can type pydoc re to jump straight to the re module documentation. I only set it up half an hour ago and I've already used it about a dozen times."
1245-4,"passage: The second tip is so powerful I've been kicking myself for not finding out about it sooner. It relates to the regular expression module's re.split() function. Just like string.split(), this lets you split up a string based on a certain token. With string.split() you the token you split on isn't included in the resulting array:"
1245-5,passage: This is also true of re.split:
1245-6,"passage: I'm probably the last person to find out about this, but it's such a useful technique I felt I just had to share it with the world."
1245-7,"passage: Why is this a big deal? Because it suddenly makes writing simple parsers and tokenisers a whole heck of a lot easier. Using the above example, say you wanted to do something with each of the <?> style tags. You can just iterate through the resulting list identifying each tag using the regular expression you've already compiled and then altering just those list items, before joining the whole list back together again at the end."
1246-0,"passage: I'm pretty sure I've never had RSI, but occasionally my wrists feel a little sore after spending time at the keyboard and I know enough about it to know that I really don't want it. This weekend I started using WorkRave after spotting a link to it on Meri's blog. It's a neat little application for Linux and Windows that sits in the background and reminds you to take short breaks from the keyboard every once in a while. Following the suggestion from the FAQ I have it set up to encourage a 15 second ""micropause"" every 10 minutes and a 5 minute proper rest break once an hour. It's too early to stay if I'll stick with it or get annoyed and turn it off, but I have to admit that I have been feeling a bit more comfortable at the keyboard. Whether that's purely a psychological effect from using it or the breaks are actually making a difference is hard to tell."
1247-0,"passage: Some great tips for optimising Python, courtesy of Ian Bicking:"
1248-0,"passage: I've been called to a less-geeky friend's PC before to find it so infested with malware that it had slowed to a crawl. Most security breaches seem to come from Internet Explorer and Outlook Express, so Matt's advice to replace them with Firebird and Thunderbird seems like a particularly good idea. Placing PCs behind a hardware router is a great idea as well as it at least prevents nasty traffic from the internet from probing the computer - although as Adam Kalsey points out such a set up won't prevent malicious software that has already snuck its way on to a PC from calling home."
1248-1,"passage: A couple of interesting links about the security problems faced by the vast majority of the home PC using public, who don't know how to install security updates (or even what they are) and don't have a corporate IT department to bail them out when they run in to problems. Joe Average User Is In Trouble is a column by a security expert bemoaning the scale of the problem. Do we all need a personal system administrator? is a call for advice from Steve Garrity for tips on minimising the support calls he gets from his parents, and includes an excellent response from Matt Haughey in the comments."
1249-0,"passage: Well colour me yellow and black, I've just become the latest member of the web standards project! I've been an avid supporter of the web standards movement for over a year now - in fact, my first ever entry linked to their launch of Phase II. It's a great honour to be a part of something I've supported for so long and I hope to become heavily involved in the Learn campaign, which aims to provide resources to developers who want to learn to use web standards effectively. I'm joining a truly talented team and I look forward to helping encourage web professionals to adopt standards and make the web a more interoperable place."
1250-0,"passage: Peter-Paul Koch has unveiled his new site, QuirksMode.org, which features over 150 pages of cross browser CSS and javascript tips and tricks. Five months in the making, there's just too much good stuff to link to individual pieces here so my best recommendation is to head on over there and spend some time browsing around. I'll make an exception though in linking to the Table of Contents script, which uses the DOM to create an additional navigation bar linking to each of the level 2 and 3 headers on a page. Another great example of the power of structural markup."
1251-0,"passage: The not-so-good news is that the Nvu site and FAQ make no mention of a Windows version of the software. Since development is being sponsored by Lindows this shouldn't come as a surprise, but it is disappointing because the great strength of the Mozilla framework is that it supports cross-platform development."
1251-1,passage: The really good news is that Lindows have hired Daniel Glazman to work on the project full time. Daniel is the principle maintainer of Mozilla Composer and it's great to see his work being funded in this way. Improvements to Composer made for Nvu seem certain to make it back in to the main Mozilla trunk.
1251-2,"passage: Launched today by Lindows, Nvu is a new project to develop a complete ""web authoring system"" (aka Dreamweaver/Frontpage style WYSIWYG editor) for the Linux platform. Reading around the marketing hyperbole, What it actually is is a standalone version of Mozilla's Composer with a whole bunch of improvements and extra features, scheduled for release in early 2004."
1251-3,"passage: It's also going to be interesting to see how this pans out from a web standards point of view. On the one hand, Daniel is certainly on the side of web standards. On the other hand, the current Nvu site's markup seems to come right out of 1998. I very much doubt it was created with the tool it promotes but it doesn't give off a particularly reassuring message. A free WYSIWYG HTML editor with strong standards support out of the box would be a valuable tool in helping authors create standards compliant sites. As it is, Dreamweaver is getting close but Dreamweaver also costs nearly $400."
1251-4,"passage: Wild conjecturing apart, the most interesting thing about Nvu (the name's pretty terrible but at least they got a three letter domain name) may well be the features that are added to the current Composer code base. The screenshots already hint at intelligent FTP publishing support; what would be really interesting would be the integration of a simple templating system and/or client side CMS capabilities - something like a cross between Fog Creek's CityDesk and Macromedia's Contribute. Interested developers are invited to sign up for a mailing list for notification of when the first development builds are made available. This is going to be an interesting project to watch."
1252-0,passage: Kimbro Staken on DRM: The record companies can be proud that they've so thoroughly screwed things up that there really isn't even any point in paying for music now.
1253-0,passage: Spotted so far:
1253-1,passage: Quite a poor showing really. I was going to add a bat to my top right hand corner but Halloween is already over in the UK so it didn't seem worth it.
1254-0,"passage: Confessions of the World's Largest Switcher is the best coverage I've seen to date of Virginia Tech's 1,100 Dual G5 Mac cluster, now the third fastest supercomputer in the world and built for a fraction of the price of its rivals. Mac Supercomputer Just Got Faster on Wired has some more information."
1255-0,"passage: Comments: Visually impaired users tend to select larger fonts, and some users
may turn off backgrounds, use fewer colors, or use font overrides. The
designer should find out what settings most users are using, and specify on
the website exactly what assumptions were made about the browser
settings."
1255-1,"passage: Tellingly, the guidelines make no mention of using web standards or validating pages anywhere in the document. While there's lots of useful stuff in there, this omission (and the clangers highlighted above) mean the overall package should be examined with a critical eye."
1255-2,"passage: Great guideline, lousy comment. How does specifying on a site what assumptions were made about the browser settings help anyone? It's almost like having ""best viewed in Internet Explorer at 1024x768 with 32 bit colour"" plastered on to the front page. No one is going to change their settings for your site, so telling them what is assumed isn't going to help them one iota."
1255-3,"passage: Guideline: Do not assume that all users will have
the same browser features, and will have set the
same defaults."
1255-4,"passage: Rubbish. Designers should attempt to accommodate 100% of all users (in as much as content should be accessible to them), which really isn't difficult if you stick to the standards rather than designing with a particular browser in mind. The 95% statistic is particularly worrying as they link to The Counter.com as a source of browser statistics, which currently shows Internet Explorer as holding 93% of the market."
1255-5,"passage: Comments: Designers should attempt to accommodate ninety-five percent of
all users. Ensure that all testing of a website is done using the most popular
browsers."
1255-6,"passage: Guideline: Design, develop and test for the most common browsers."
1255-7,"passage: Usability.gov's Research-Based Web Design & Usability Guidelines lose instant credibility for being available only as a 39.2 MB PDF file [ Update: this statement is incorrect - see my correction ], with all of the usability and accessibility problems that brings with it. I'm on a fast connection here so I downloaded them anyway to have a look. There's actually a lot of good things I can say about them - the document is attractively laid out, the guidelines clear and easy to follow and each is backed up by references to academic research (hence the title). There are however some guidelines with which I completely disagree, in particular the ones in chapter 4, entitled ""Hardware and Software"":"
1256-0,passage: Stuart's blog entries concerning the two new experiments are here and JavaScript Event Sheets.
1256-1,"passage: Stuart's second experiment, JavaScript Event Sheets, is even more interesting. It tackles the problem of attaching events to page elements. The most common way of doing this is with inline attributes, but these require adding behavioural (rather than structural) code to your markup and can lead to additional maintenance costs further down the road. A better alternative is to use the DOM to dynamically add events, which works fine but means tightly coupling the structure of the document to the Javascript that sets up the events. Stuart's solution is to abstract the logic that attaches events to elements out to a separate file, called a Javascript Event Sheet. This uses CSS style syntax (partially handled by my getElementsBySelector function) to specify how events attached to different elements should be handled. Stuart demonstrates the idea with a common image rollover:"
1256-2,"passage: Stuart Langridge has released a couple of very neat new Javascript experiments. sorttable makes any data table on a page ""sortable"" by clicking the table headers. I've seen this effect used to demonstrate Microsoft's proprietary ""behaviors"" technology but Stuart's solution has the advantage of being standards compliant and working across different browsers. Best of all, it follows the principles of inobtrusive DHTML and hooks in to the markup using only a class attribute."
1257-0,"passage: I thought it was finished, until I tested it in Apple's Safari browser. In Safari, the worst possible thing happens. The initialisation code which hides all of the panels after the first one works fine. Unfortunately, the code that causes the links to change which panel is visible fails silently, leaving only the first panel accessible to users with that browser. That's a big problem."
1257-1,"passage: It was at this point that I discovered that Safari's support for debugging Javascript sucks rocks. Firstly, the browser gives no indication that a bug has been encountered. I'm sure this is a deliberate usability decision, but it also means users who encounter a bug won't even know that there is a problem with the site. A quick Google led me to this page, which told me how to enable Javascript error reporting:"
1257-2,"passage: Excellent - just what I needed to know. The entire error message I got when I clicked a link? (event handler):Undefined value. Gee, thanks a lot Safari. If anyone has any ideas how I can fix the script in Safari (or at the very least prevent it from being unusable) please leave me a note."
1257-3,"passage: Update: Thanks to a tip from David Lindquist, the updated version of the script now works in Safari. It's a little bit uglier though."
1257-4,"passage: I've been working on a new inobtrusive DHTML effect: easytoggle, which is an inobtrusive implementation of the common effect where links or tabs can be clicked to reveal part of a page while hiding the other parts. It's similar in some ways to the Multi part forms with Javascript technique."
1257-5,"passage: The idea is pretty simple - all you need are a bunch of links and a bunch of elements that should be toggled by those links. When adding special behaviour to links it is always a good idea to ensure that they still link to something sensible, so that in user agents without Javascript support they still do something useful. In this case, it makes sense for them to act as anchor links that point to the elements with which they are associated. With easytoggle, all you need to do is define the links, point them at an element with an ID and assign them the class 'toggle'. The script does the rest of the work. For example, for a simple set with only two panels the markup would look something like this:"
1257-6,passage: That's all it takes - the demo has a very slightly more complicated example.
1258-0,"passage: In an earlier entry about Usability.gov's Research based Web Design & Usability Guidelines I criticised them heavily for not providing an HTML alternative to the huge PDF file containing the guidelines. It has since been pointed out that the guidelines are in fact also available as HTML. I'd like to apologise to the authors of the site, although I would also like to suggest that they add a link to the HTML version from the PDF page. Thanks go to Adam Bramwell for alerting me to my mistake."
1259-0,"passage: In possibly the best news web designers will hear this year, Joe Maddalone of Insert Title Web Designs has discovered a way of running multiple versions of Internet Explorer on one installation of Windows! The problem of testing in different versions of IE has plagued developers for years, and it's fantastic to see a solution that doesn't involve running multiple partitions with separate Windows installations or shelling out for VMWare or VirtualPC."
1259-1,"passage: Unsurprisingly, Joe's revelation is causing quite a stir in the web development community. Matthew Haughey is asking why Microsoft didn't tell us about this themselves, Luke Redpath has released some funky coloured icons to distinguish between versions and Ryan Parman has taken the risky (from a bandwidth point of view) step of packaging the minimum files needed to run versions 5.01 and 5.5 up in to zip files. Amazingly, they're 2.92 MB and 3.25 MB respectively. I'm running them now and they seem to work just fine - major kudos to Joe for the discovery, and Ryan for making it so easy to take advantage of."
1260-0,"passage: It turns out however that there is a third option. Load up this page, recently posted to Webdesign-L by Rick Cecil. Now increase and decrease your browser's text size. The whole page scales with the text, thanks to extensive use of the em unit for setting the width of various page elements. I don't know if this technique even has a name yet but if it hasn't I suggest ""full page zoom"". I will certainly be investigating it as an option for future projects."
1260-1,"passage: Update: While experimenting with this idea further, I came up with this Javascript experiment. Make of it what you will."
1260-2,"passage: For as long as I've understood the issue, I've been an advocate of liquid layouts over fixed widths for web page design. Liquid layouts are layouts like the one used by this site, where the page adjusts to fix the size of the user's browser window. Fixed widths on the other hand are sites such as LJWorld.com where the width of the page is fixed no matter how large or small the browser window gets."
1260-3,passage: There are good arguments for both sides of the issue. Liquid layouts give control to the user and avoid wasted screen real estate; fixed width layouts give the site author greater control over the look of the site and (more importantly) ensure that text line widths remain sensible.
1260-4,"passage: In recent months, I've been seriously reconsidering my preference for liquid layouts. I'm currently using Windows at a resolution of 1280 x 1024 with my browser fully maximised, and reading liquid sites is a pain. The standard cry of liquid layout fans in this case is ""you don't have to surf with your browser window maximised"", and I have repeated this myself many times. The problem is, I surf with my browser window maximised. I don't know why, but I just feel more comfortable with a maximised browser window (it may be related to the ridiculous number of tabs I normally have open). My solution so far has been a combination of using these bookmarklets and increasing the text size of the page, but fixed width layouts are becoming more and more appealing."
1260-5,"passage: One final thought: if only the current pack of browsers supported the min-width and max-width CSS properties, this whole issue could have been solved years ago."
1261-0,"passage: Dunstan Orchard's great looking blog has had a whole bunch of upgrades, and some of them are pretty interesting. Firstly, he's taken my blockquote citations script and modified it to handle citations that aren't links in an intelligent way. He also now has a comment spam blacklist (I really need to work out the syndication details for that and publish some code)."
1261-1,"passage: His most interesting new feature is comment alerts, a system that allows people to keep track of discussions that they have participated in on his blog. Dunstan's system allows users to ""opt in"" to allow future commenters to alert them if their comment is relevant to what the original user posted. It's well worth surfing over and checking out Dunstan's explanation of the system, which may well materialise on this site as well some time in the future. There are quite a few other neat tricks around the site, some of which are detailed in the Colophon."
1262-0,"passage: Made possible by Ryan Parman. Now if I had a Mac and Virtual PC, I'd be able to run even more..."
1263-0,"passage: Via Craig, Big John and Holly Bergevin present Float: The Theory and Flowing and Positioning: Two Page Models. Both articles take a complex topic and present it in clear, straight forward terms with excellent illustrations and the kind of insight in to browser bugs (in particular the vagaries of IE) that you just won't find anywhere else."
1264-0,"passage: There's blogging a list of links, and then there's blogging a list of lists of links:"
1264-1,passage: Now if someone else links to this we'll have a link to a list of lists of links. And that would be just silly.
1265-0,"passage: We put together a bookmarklet today that allows our editing staff to jump instantly from looking at a story on one of our web sites to the interface for editing it within our current content management system. It took about 5 minutes development time, plus an extra 15 minutes spent showing it to people, setting it up on machines and demonstrating how it works. It's hard to over state how well this new shortcut was received by the people who spend hours every day using the system. For end users, a little feature can sometimes go a very long way."
1266-0,"passage: That said, what impressed me about FUDforum more than anything else was the installation process. The forum is distributed as a zipped archive, but when you extract it the only file you need to copy to your web server is a single 4.5 MB file called ""install.php"". You drop that in to a web facing directory and access it from your browser. It then steps you through the rest of the install, telling you which directories to chmod 777 so that the installation process can access them, asking for your database settings and automatically creating all of the scripts, database tables and configuration files it needs to run. It even refuses to let you in to the admin panel at the end until you've deleted the install.php file from the server. Pretty slick."
1266-1,"passage: I tried out FUDforum last night, after Rasmus Lerdorf recommended it in a comment on Jeremy Zawodny's blog. Feature wise, it's pretty impressive but still doesn't quite do it for me - I want something that's trivial to integrate with an existing authentication system and outputs valid HTML (or XHTML) out of the box. Rasmus says it's the only board he's seen that doesn't have obvious security holes though so it's probably worth checking out if you need to set up a forum of that kind."
1266-2,"passage: Of course, the need to chmod anything 777 in a shared hosting environment is a little bit worrying, but that's been a common problem with server side web development for as long as I can remember."
1267-0,"passage: I've been rewriting the photo gallery management system for KUSports.com in Python. One of the new features is that the system can automagically extract caption and photographer information from the photos, provided the information has previously been added to the jpeg file as EXIF data. I tried several methods of doing this but eventually settled on EXIF.py because it worked straight away using a simple process_file() function and doesn't require any additional software. Recommended."
1268-0,passage: Update: It turns out the obfuscation was the result of compressing the Javascript for efficiency reasons - see my apology for further information.
1268-1,"passage: PHP.net has a new feature on their search page - a really nice implementation of an auto complete text widget in Javascript. Even better, the search page is valid XHTML 1.0 Strict and uses CSS for the layout. Let's hope this is an indication of things to the come for the rest of the site, which still mostly consists of tag soup."
1268-2,"passage: Here's the ugly bit: the javascript for the auto complete function is deliberately obfuscated. Now I know that this decision is completely up to the author of the script, but personally I find it exasperating. PHP is an open source project, and obfuscation in this way is the antithesis of the open source ideal. A big part about open source is that people shouldn't have to invent something twice - why waste duplicated effort when sharing code costs nothing and benefits everyone? I'm sure the author had their reasons for hiding the code in this way but to me it seems like a wasted opportunity to teach site visitors a useful new trick. A bug concerning the obfuscation has already been raised in PHP's bug tracker but was closed without a full explanation."
1268-3,"passage: Obfuscation of client side code such as Javascript is a pretty futile exercise in any case. Most of the effect of the obfuscation can be easily reversed using a tool such as Jesse Ruderman's view variables bookmarklet, which displays all variables on a page (including ones that contain decoded content from obfuscated variables) and pretty-prints functions to make them more readable."
1268-4,"passage: It's impossible to prevent ""theft"" of your Javascript, but if you really want to stop people from using it the best you can do is to place a copyright notice in the code and ask people to contact you for licensing options. If it's on the web, people can take it. Clear copyright messages are a far more ethical deterrent than ineffective tricks."
1269-0,"passage: I'm not a very visual person; complex entity relation ship diagrams, data flow diagrams and the like are usually completely lost on me, and I try to avoid them when they are mandated by coursework at University. Give me a text based SQL schema any day. Click Maps on the other hand I could learn to like - they're nice and straight forward and solve the very real problem of planning how different parts of a web application will link to each other."
1270-0,"passage: It turns out that the Javascript on PHP.net mentioned previously was not deliberately obfuscated to protect the code from prying eyes; it was merely compressed to reduce the size of the script. See this comment for further details. I'd like to apologise to the maintainers of PHP.net for jumping the gun on this issue. Incidentally, the unobfuscated code is now available in CVS."
1271-0,"passage: But we don't have the data. We don't have any data. You can give us anecdotes left and right about how methodology X worked or didn't work, but you can't prove that when it worked it wasn't just because of one really, really good programmer on the team, and you can't prove that when it failed is wasn't just because the company was in the process of going bankrupt and everybody was too demoralized to do anything at all, Aeron chairs notwithstanding."
1271-1,passage: Joel Spolsky on analysing development methodologies:
1272-0,"passage: Then, when his pallor begins to fade and he begins to take on signs of socialization, take him into the offices in the hospital and let him see the four sets of user names and password clinging to the monitors on yellow stickies (e. g., Post-It Notes) or, for the more security-minded, slid into the top drawer where no one would think to look."
1272-1,passage: Take him out for a walk. Let him see the sunshine for the first time in years. Introduce him to some normal human beings. Be gentle at first; these are creatures with whom he has had no contact since being sucked into the depths of the university system.
1272-2,"passage: Via Crypto-Gram, a great piece from Bruce Tognazzini about how tough security measures can actively reduce the security of a system:"
1272-3,"passage: My wife, the Doctor, was working over the summer at a local hospital. They are fiercely into security, requiring no fewer than four sets of passwords to navigate their system. And why not? There are confidential patient records on those systems! By golly, they ought to have eight sets of passwords, and really make things secure!"
1272-4,"passage: So works the mind of a D'ohLTish security engineer, working feverishly away in his cubicle in the basement next to the steam plant."
1273-0,"passage: Spotted on Slashdot, IBM's Open Source Desktop - Directions for today... and Tomorrow presentation includes one slide that really caught my attention:"
1273-1,"passage: To continue our own journey to becoming an on demand business, IBM expects to migrate our internal desktop environment, where appropriate, to open standards based on the Linux platform."
1273-2,"passage: Of course, depending on how they define ""appropriate"" this could be a lot less exciting than it looks. Still, it's a pretty huge boost for the Linux desktop movement."
1274-0,"passage: We're having a problem at work with Macromedia Contribute. We host sites for a number of local companies, and one of them wants to use Contribute to update its site. The problem is that whenever Contribute tries to connect to our FTP server, it opens up 30 simultaneous connections, effectively running a denial of service that prevents other clients from logging in during peak times. I've searched the 'net and haven't found any references to this problem; does anyone know anything about the issue? We're running ProFTPD 1.2.9 and the client is using Macromedia Contribute 2."
1275-0,"passage: In related news, WaSP have an excellent interview up with Dan Cederholm, lead developer behind the high profile Fast Company and Inc.com web standards redesigns and squire of Simple Bits. The interview has a lot of great anecdotes about how switching to standards saved both time and money."
1275-1,"passage: The Sprint PCS site has relaunched, using XHTML 1.0 transitional and CSS. It's another great example of a mostly web standards compliant commerical/corporate; there are a few validation errors thanks to a quarrelsome CMS. France Rupert is the lead developer behind the new site and is promising a detailed writeup of the process and challenges behind the redesign. France hails from Kansas City, so hopefully we'll be able to get him along to a web meetup in the not too distant future."
1276-0,"passage: This email to the css-discuss mailing list does a great job of describing the confusion and frustration that still confronts traditional web developers who are only just starting out on the road to mastering CSS. When you've ""got it"", it's easy to forget how much of a paradigm shift it is away from old school table methods. Here's an extract:"
1276-1,passage: Step Eight.
1276-2,"passage: Just when you think you're settling down into a slow and steady
learning curve, this is about when you start getting emails from
everyone who uses your site describing all kinds of variations on your
layout as it has been interpreted by their varying browsers and
platforms. This stage is the most important of all, the one where you
realize that CSS support is far, far more random than any HTML
workarounds that you've been dealing with for the (insert personal
experience here) years you've been making web pages."
1276-3,"passage: (Excerpt from an email from a user of one of my sites: ""the new
color and stuff on the homepage looks good, except on my computor [sic]
some of the pages are cut off at the bottom and have big gaps in them"")"
1276-4,"passage: Maybe a good analogy to make here is one with Linux: both are great in principle, but if you aren't comfortable with what you are doing you can run in to a whole bunch of problems. I wouldn't recommend anyone who is still on the CSS learning curve to move a big commercial project to pure CSS, just as I wouldn't suggest a Linux newbie start hosting their own internet facing server."
1276-5,"passage: At any rate, it's obvious that we as a community still have a long way to go in creating useful resources for people who want to make the switch to CSS."
1277-0,"passage: My hunch is that this could be an obscure bug that only surfaces when Contribute is used with ProFTPd 1.2.9. At any rate, we've solved the problem by setting the MaxClientsPerUser directive in the ProFTPd configuration file. Contribute doesn't seem to mind in the slightest."
1277-1,"passage: After further analysis of the Contribute problem described earlier, we discovered that Contribute was opening a new FTP connection every time we clicked a link within the application even before we had hit the ""edit page"" button to fire up the editing mode. Switching the connection over to use SFTP instead of FTP had the same problem, with a secure connection being opened for each link we clicked instead. The connections remained open until we shut down Contribute."
1278-0,"passage: cgi_buffer is voodoo magic for Perl, Python and PHP scripts that automatically handles a bunch of bandwidth saving HTTP tricks such as Content-Length headers (which enable persistent connections), ETags for caching and GZip content compression. Pretty neat."
1279-0,passage: Status Notification is a web application pattern from Ian Bicking that uses sessions to solve the problem of how to display simple status messages without displaying whole pages with just a one line message on them or passing a message in a URL. My current project could certainly benefit from this.
1280-0,"passage: Therefore you could end up with a hack that applies an extra rule you no longer need, or with a necessary extra rule that isn't applied any more."
1280-1,"passage: When all is said and done, a large proportion of hacks in use today exist to combat the infamous box model problem - and the best advice for coping with that can be found on Dave Shea's CSS Crib Sheet: Try to avoid applying padding/borders and a fixed width to an element. Do that, and box model hacks just stop being necessary."
1280-2,"passage: Via Web-Graphics, Petr Pisar's Underscore Hack provides a new way of targetting CSS rules specifically at Internet Explorer on Windows. As with all such hacks, the pros and cons of using this approach need to be closely examined before deploying it. The hack takes advantage of the fact that adding an underscore to the start of a property name causes that declaration to be ignored by every browser except IE for Windows. However, the hack takes the dangerous step of using one bug to solve another. Peter-Paul Koch explained why this is a risky thing to do in a recent column for Digital Web magazine:"
1280-3,"passage: A certain browser has a certain CSS bug. Good to know. This same browser has another bug, usually in its parsing of CSS selectors or comments. This, too, is important information. However, a CSS hacker proceeds to use the second bug to ""solve"" the first one."
1280-4,"passage: Solving one bug by another is not my idea of keeping Web development simple, but the matter goes beyond bad coding style. These hacks are inherently unsafe."
1280-5,passage: In an ideal world the next release of the browser would solve both bugs. In an uncaring world the next release of the browser would solve neither. In the uncertain world we live in the next release could solve one bug but not the other!
1280-6,"passage: In my opinion, hacks like this are safe for use on sites that are being actively maintained. If you use them in a ""fire and forget"" project you could well find it breaking in new browsers in a few years time, when the site is no longer being maintained but remains online and broken for all to see. If on the other hand you use it for a living, breathing site such as a constantly changing commercial project or a personal weblog errors that crop up in future browsers can be taken on as and when they appear."
1281-0,"passage: My main points of inspiration were Paul Hammond's bookmark store, Mark Pilgrim's b-links, Anil Dash's Daily Links and Jason Kottke's Remaindered Links. Since there didn't seem to be any naming convention I decided to call them blogmarks, which isn't a new term but doesn't seem to have a widely accepted meaning yet either."
1281-1,passage: The system is powered by a simple bookmarklet. To make things a little more interesting I'm capturing the referral information and using it to automatically generate the 'via' link; since the title of the previous page isn't available in Javascript I extract is using a server side script instead. I swayed briefly between using page extracts a la Hammond or sarcastic commentary a la Pilgrim and decided that commentary would be far more fun.
1281-2,"passage: This entry was going to be another list of links, together with a note about how much I really needed to set up a separate link blog. Then I realised that it would make more sense just to set one up so that's exactly what I've done. I still need to implement the archive but it's getting dark so I'm posting this and heading home."
1282-0,"passage: Out with the orange, in with the green. As with my last redesign, only the CSS changed. A fun deviation with this one was that it was a collaboration between myself and Natalie over nearly 5,000 miles, using edit styles and AIM to pass each other snippets of CSS and instantly try them out."
1282-1,passage: I haven't tested it very thoroughly at all so if there are any glaring abominations leave me a comment - I know about the blogmarks looking slightly out of place in IE 6 but I haven't quite decided if I can be bothered to find a workaround yet.
1283-0,"passage: Last week's release of PostgreSQL 7.4 made a great open source project even better - it even managed to impress hard-core MySQL advocate Jeremy Zawodny. The detailed release notes show that most of the improvements were with regards to performance, but the thing that really caught my eye was tsearch2, the new full text indexing suite. A bit of digging brought up the CVS tree for the new module, which in turn lead me to this tutorial style overview of its capabilities."
1283-1,"passage: I make extensive use of MySQL's built in full text indexing on this blog for both the search engine and the ""related entries"" lists, so it's a feature I've really been missing in my experiments with PostgreSQL."
1284-0,"passage: Wow, that's what I call feedback! It's a shame pretty much everyone hates the new design but I like it so it stays. I've taken a few tips though and tweaked the link colours a bit, as well as making a few other small changes such as a darker green for the header and a 1em margin around the page."
1284-1,"passage: In an attempt to satiate the voracious appetite for RSS displayed by some of my visitors I've set up two new feeds: Blog comments and Blogmarks. I don't use an aggregator myself so I'd appreciate feedback on how well they work. I've also put together a blogmarks archive - no search engine yet, but it's on the list."
1285-0,"passage: I'd never done anything with Berkeley DB before, but luckily Python has a module which seems to do all of the hard work for me:"
1285-1,"passage: Some digging around turned up the real information: the Berkeley DB Tutorial and Reference Guide, which contains pretty much everything you could possible want to know about the technology. It turns out that at a basic level Berkeley DB is just a very high performance, reliable way of persisting dictionary style data structures - anything where a piece of data can be stored and looked up using a unique key. The key and the value can each be up to 4 gigabytes in length and can consist of anything that can be crammed in to a string of bytes, so what you do with it is completely up to you. The only operations available are ""store this value under this key"", ""check if this key exists"" and ""retrieve the value for this key"" so conceptually it's pretty simple - the complicated stuff all happens under the hood."
1285-2,passage: I'm working on a project at the moment which involves exporting a whole bunch of data out of an existing system. The system is written in Perl and uses Berkeley DB files for most of its storage.
1285-3,"passage: It seems like a great alternative to a full on relational database for simple applications, although I'm slightly confused by the license which allows free use for open source products but requires a license for commercial applications. Does that mean that if I use the bsddb Python module in a commercial app I need to get a license from Sleepycat?"
1285-4,"passage: The Berkeley DB libraries are maintained by Sleepycat Software. Unfortunately, their site is completely saturated with marketing jargon. Our customers rely on Berkeley DB for fast, scalable, reliable and cost-effective data management for their mission-critical applications. Great - now what does it do exactly?"
1286-0,"passage: I imagine there's a slight performance impact from using Python's list data structures instead of a more low level C array, but I doubt it's significant. In any case, the real promise of Pyrex lies in making it easier to write Python wrappers for existing C libraries - a topic touched on by the Pyrex Documentation."
1286-1,"passage: Pyrex is a language for writing Python extension modules. It's pretty interesting - the syntax looks very similar to Python (the authors claim you can write C extension modules without knowing anything about the Python/C API) but uses additional type hints to compile down to ultra efficient C code, ready to be imported in to your Python applications. The prime numbers example maakes things a lot more clear:"
1287-0,"passage: Billett defended the company's patching process, which he said involves testing each new bug fix, and deploying at a wide variety of institutions with a mix of network architectures. ""A lot of those machines actually have to be visited by a service technician"" to be patched, said Billett. ""Our experience in the past is we are able to turn those around in one or two days."""
1287-1,"passage: What do you have to do to patch these things, plug in a keyboard and mouse?"
1287-2,passage: Check out this article on The Register: Nachi worm infected Diebold ATMs. This just beggars belief. How a Windows worm spread on to a network with ATMs connected to it is beyond me - even if you take in to account employee laptops plugged in behind the firewall it's still incredible that the ATMs weren't on their own separate secure network.
1287-3,"passage: So you're writing the software for an ATM. It needs to display something pretty on the screen, control the hardware that serves out the money and talk securely to your central servers. It also needs to be stable, secure, reliable and allow remote administration. Why on earth would you choose Windows as the operating system?"
1287-4,passage: Here's the best bit:
1288-0,"passage: Harry Fuecks has been hacking on my XML-RPC library, and has released a new version with some significant changes. His article on phpPatterns describes the changes and provides a link to download the updated code. He's made a bunch of interesting architectural changes which take advantage of a number of useful PEAR classes, including HTTP_Request which provides support for proxies and authentication, two frequently requested features."
1288-1,"passage: I don't know when I'll get a chance to look at my version of the code again, since most of my current development work involves Python rather than PHP. If you're looking for an updated version of the library you would do well to check out Harry's enhancements."
1289-0,"passage: Charles Miller, in Google, Microsoft and Tall Poppies.:"
1289-1,"passage: Bill Gates' original goal in forming Microsoft was famously to
have (emphasis mine) ""A computer on every desk and in every home, running Microsoft software"".
You'll not find the last three words of that sentence in any official
Microsoft history (or at least I couldn't, and I searched hard).
They've been carefully un-happened: the dream of a nascent monopolist
truncated into a facade of altruism."
1289-2,passage: Google:
1289-3,passage: Fascinating.
1290-0,passage: I've been long bemoaning the fact that if you want to repartition your hard drive to install Linux as a dual boot with an existing Windows system the most frequently recommended method is to buy a copy of Partion Magic. You would have thought the open source software world would have provided a free alternative by now.
1290-1,"passage: Update: Closer inspection reveals that Parted can't resize NTFS. Thankfully, ntfsresize can - and ntfsresize is integrated in to QtParted. Magic."
1290-2,"passage: As an aside, has anyone ever found a web page that lists all of the software included on the Knoppix CD?"
1290-3,"passage: Via Andy Todd, it turns out that they have. GNU Parted is a repartioning tool for Linux. QtParted wraps it in a GUI with a Partition Magic style interface. And the awesome Knoppix comes with QtParted included on the disk. So instead of shelling out for an expensive package that you are unlikely to ever use more than once, you can download and burn a Knoppix CD, boot in to Linux and repartition from there. I'll be trying this out for real on Monday, and I'll report back with the results when I do."
1291-0,"passage: New from Russ Weakley: Selectutorial, which taks his widely acclaimed step by step CSS tutorial style and applies it to CSS selectors. Having a full understanding of selectors is critical if you're going to take full advantage of CSS, so if you don't get them yet you should really check this out."
1292-0,"passage: I've suspected this for a long time, and now here's the empirical evidence: Popular Spam Protection Technique Doesn't Work. If you're relying on HTML entities to protect your email address from spam harvesters - for example username@example.com - your email address may as well be in plain text. Chip Rosenthal downloaded a tool called ""Web Data Extractor v4.0"" and tried it on some test data to prove once and for all that the technique doesn't work."
1292-1,"passage: My advice is to use your common sense when analysing a potential spam protection technique. If you were a spammer, would you be able to outwit the method? Spammers aren't always very smart, but the people who write spamming tools (and get paid big bucks for them) are. Also remember to think about the payoff - unencoding a bunch of entities is a cheap operation. Embedding a Javascript interpreter to decipher email addresses that are glued together using Javascript at the last possible moment is a lot harder and could slow down a tool, so it may not be worth the effort."
1292-2,"passage: I'm still pretty confident in my own anti-spam harvester technique of hiding my email address behind a POST form, but even that could eventually be outsmarted by a really dedicated harvesting tool."
1293-0,"passage: Adrian just pointed me to a fantastic tool: Gotmail, a utility to download mail from Hotmail accounts. It's a command line utitlity, written in Perl and making use of the curl binary, which can connect to Hotmail over the web and grab any new emails, saving them locally as an mbox file and deleting them from the Hotmail server."
1293-1,"passage: Naturally, anything like this is completely dependent on Hotmail's design staying the same and maintaining the tool is a constant arms race. At the moment, Hotmail is ahead - a recent upgrade to the Hotmail design (some time in the last few days) has rendered Gotmail useless. A call for help on the Gotmail mailing list from the lead developer makes particularly interesting reading. He's looking for developers and users who can help with the debugging effort required to get the tool working again, but the last paragraph of the email really caught my attention:"
1293-2,"passage:
Developers: If you have some Python proficiency, and would like to
assist in developing the next generation of Gotmail (development
name: gotfemail), email me off-list. I have some pretty ambitious
plans for this project, and depending on how much is actually
implemented, Hotmail breakages should be either self-fixing or very
simple to fix. I've done some work on making a generic library for
this sort of job (so the fetchyahoo people and others might be
interested), and some preliminary work on embedding the Javascript
interpreter from the Mozilla project.
"
1293-3,"passage: A self-fixing screen scraper sounds like one heck of an interesting project, and I can't complain about the choice of development language either ;) If you're a Python hacker looking for a new project this could be well worth checking out."
1294-0,"passage: However, for other files total_time() is returning (-1, -1). I'm sure there's a solution to this but I haven't stumbled across it yet."
1294-1,"passage: After installing the Windows package and experimenting for a while, I managed to extract the time from one of my test files using the following:"
1294-2,"passage: Ned Batchelder recently wrote about the difficulties involved in extracting the length from an MP3 file. We're going to need to solve this problem soon at work; luckily, it seems that the answer may lie in the Python bindings for mpgedit, an audio file editing library available for both Windows and Linux."
1295-0,"passage: D. Keith Robinson writes about Using Dates For Featured Web Content. Keith's right, including a date with your content really is a no-brainer. I'll add an anecdote of my own. Several years ago I ran a popular news site for Team Fortress Classic, a team based online first person shooter game with a thriving clan scene. I was careful to include dates on every piece of content, but in my youthful naivety I neglected to include the year. The years rolled by and the content built up until I suddenly realised that I was no longer sure what year some of it was written in! The site has sadly now passed in to history but the lesson remains: the web moves faster than you might think, so omitting the year in your dates is a pretty dumb thing to do."
1295-1,"passage: It's pretty obvious but I'll point out anyway that using dd/mm/yyyy or mm/dd/yyyy for dates on sites is a bad idea as well. Us crazy brits use the former, them crazy yanks use the latter and everyone ends up thoroughly confused about any written date before the 13th of the month. I personally like to use the full ""4th December 2003"" format, but when space is limited the least ambiguous format is ISO standard YYYY-MM-DD."
1296-0,"passage: The Guild of Accessible Web Designers is a world wide organisation of web designers and developers committed to helping each other, and promoting the message that accessible web design is 'good for business'. I'd describe the organisation in detail here, but the official site does a far better job than I could. If you've been following the web accessibility community in any detail You're likely to recognise a number of the names on the registered members list; I've been following GAWDS developments for a while and its shaping up to be a great resource for accessibility minded designers. I've also contributed an article on Writing good ALT text which hopefully provides some useful advice on a frequently misunderstood topic."
1297-0,"passage: Perls of wisdom in a sea of site mismanagement, via the ever-excellent Column Two:"
1297-1,"passage: Some influential voices are starting to argue that many sites should, in effect, wait out this immature phase of website management. For the moment, they should content themselves with limited automation."
1297-2,"passage: Of course, if you don't have a competent server-side programmer to hand your only option is to buy a pre-made solution, but with a half-decent programmer and a good set of tools a simple home built CMS customised to fit your needs could be a much better investment than some $100,000 one-size-fits all monstrosity."
1297-3,"passage: The great surprise of the past five years of content management is that, despite all the hundreds of systems, no clear winners have emerged. Instead, there's a growing dissatisfaction with the ongoing technical burden that such systems impose."
1297-4,"passage: The article concludes with the idea that many sites can do perfectly well with a few simple Perl scripts and maybe a relational database on the back end, rather than investing in an expensive super-package that claims to be able to do anything you could possibly want. This is very sound advice. The simple fact of the matter is that many sites really don't need a complex content management platform with support for templating, user logins, workflow, versioning and a dozen other high end features. Most sites just need someone to be able to easily update them, when necessary. This is why Macromedia Contribute has been such a success - people want the ability to hit ""Edit This Page"", make a few changes and publish straight to their site."
1297-5,"passage: I've worked on my fair share of content management systems (in fact I'm helping develop one at the moment) and out of all of the ones I've been involved in, the one I got the biggest kick out of took the shortest time to develop. It was based on Tavi Wiki, and consisted of a password protected Tavi install for the back end and a slightly modified separate install for the front end. Both installs pointed to the same database, but the front end was altered to disable all editing features and make the site look less like a Wiki. You can see the end result here."
1297-6,"passage: All in all, the CMS took less than an hour to put together from start to finish. It made it easy enough for contributors with no previous knowledge of HTML to update the site (using Wiki markup) and provided us with full versioning on all content contained within the project. The final site gives very few clues that the underlying engine is a Wiki, and thanks to Tavi's ease of customisation the site design can be easily changed to look even less wiki-like. It's close to the simplest thing that could possibly work and it works just fine."
1298-0,"passage: I wonder if Python would benefit from something like this? Python already has an excellent decentralised community centered mainly around the Python newsgroups, blogs and mailing lists, but it would be nice if Python.org provided more community oriented features."
1298-1,"passage: Via The Farm, Chris Shiflett is calling for assistance in setting up a new PHP community site to run along similar lines to use Perl. Chris has already secured an offer of hosting and support from O'Reilly and is now seeking offers of help from potential contributers. PHP has long needed a site of this kind (PHP Builder has lost a lot of momentum since being sold by Tim Perdue) so this could be a worth while project to get involved with if you have the time."
1299-0,"passage: Via Jeremy Hylton, Mark Shuttleworth (super-rich geek and space tourist) is offering $100,000 worth of bounties in 2004 to developers willing to help out with a number of Open Source projects, most of which are to be developed in Python. A comparison can be made here with Mitch Kapor, another geek-done-well who funds open source development through his sponsorship of the Open Source Applications Foundation."
1299-1,"passage: Personally I think this is a great way of funding open source development, although a counter-argument is that this kind of reward could encourage the wrong kind of attitude within the open source community with programmers dedicating their time to paid projects at the expense of others. I don't see this happening - people work on open source projects for the love of doing so and to scratch an itch. If you have the money to spend and want to offer it up as a bounty for someone to further develop a product you like then more power to you! I would certainly consider doing so if some freak incident left me rolling in cash (very unlikely to happen considering my complete disinterest in nursing my finances)."
1300-0,"passage: Via Hans Nowak, Understanding Object Oriented Programming, or how to turn 19 lines of easily maintained code in to an OO monstrosity spanning 7 class files. This is not the way to make code more maintainable. For comparison, here's how I would implement a solution to the same problem in Python, assuming the availability of an equivalent function to Java's System.getProperty(""os.name"") (os.name is similar but inappropriate for this example):"
1300-1,"passage: In my book, smart data-driven programming beats over-engineered class-based programming any day of the week."
1301-0,"passage: Continuing on the same theme, The Rise of the Spammers is a fascinating article by David Barroso Berrueta describing how one of his servers was turned in to a spam relay after being compromised through a vulnerability in a PHP script. The technical details are intriguing; the attacker downloaded and uncompressed a daemon which then communicated with another host using an extended version of the SMTP protocol, receiving spam email bodies along with lists of addresses to send the spam on to."
1301-1,"passage: Computer security researchers have been watching the evolution of remote-access rogue programs as they have become more common and have put more machines under the control of hackers. Programs like Sinit infect target machines and surreptitiously open back doors that allow outsiders to control the PC's. The rings of infected computers have been used to send spam, to present online advertisements for pornographic Web sites or to trick people into giving up information like credit card numbers."
1301-2,"passage: In fact, at least a third of all spam circulating on the Internet is now sent from or relayed by personal home computers that have been taken over, said Jesse Dougherty, director of development at Sophos, an antivirus and antispam company. "
1301-3,"passage: Incidentally, I know you can disable opening files over HTTP and I know you shouldnt allow the direct creation of variables from the query string in the first place. The problems here are two-fold: firstly, opening files over HTTP is actually a very useful feature, one that would be all the more useful if it didn't carry the risk of executing arbitrary code. Secondly, the problem is mainly down to third party software which often requires insecure PHP settings (such as register_globals) in order to work."
1301-4,"passage: Let's talk about the PHP vulnerability in question: yet again, it was the classic problem where an attacker can instruct PHP to download and execute code from their own server by feeding in a query string parameter that is passed un-checked to an include() function call. While there are a number of steps that can be taken to deny this kind of attack, it unveils a fundamental problem with PHP itself - that it will execute code retrieved from a URL in the first place! This feature should be removed from PHP - it has almost no purpose in the real world aside from allowing servers to be cracked in to. The feature exists because PHP has the extremely useful ability to open remote files over HTTP. Unfortunately, this feature extends to the include() and require() functions which will execute any PHP code in the file passed to the functions. The most obvious solution to my mind would be for these functions to refuse to execute PHP in files that were opened via HTTP. I have no doubt that this would involve an ugly hack on behalf of PHP's maintainers, but I believe the number of security problems it would solve would be well worth the trade-off."
1301-5,"passage: Emphasis mine. Of course, whether or not you want to believe a director from a company that directly profits from people's fear of security attacks is up to you. That said, I've seen plenty of supporting evidence in the past few months that indicates that spamming is now the number one reason that a cracker would want to take over a PC, not least this Wired article."
1301-6,passage: From the New York Times:
1302-0,"passage: You Ain't Gonna Need It states that you should always implement things when you actually need them, never when you just foresee that you need them. This is great for controlling feature creep; the moment one of us says ""we might need that later"" the other says ""YAGNI"" and we can move right along."
1302-1,"passage: Don't Repeat Yourself is one of the tips from The Pragmatic Programmer, a book which is every bit as good as people say it is. It states that Every piece of knowledge must have a single, unambiguous, authoritative representation within a system - whenever we spot something that is duplicated and can be considered a ""piece of knowledge"" we frequently refactor it straight away."
1302-2,"passage: One of the most interesting things about pair programming is that introduces a complete reliance on communication into something that is generally a solitary activity. Guidelines like the two listed above extend the vocabulary that can be used in such communication, speeding up development and making tough decisions easier to quickly resolve."
1302-3,"passage: Two acronyms that have been seeing a lot of action at work recently are YAGNI and DRY. They're great principles to go by in any case, but in a pair programming environment they take on a whole new level of utility."
1303-0,"passage: Today's new Internet Explorer vulnerability makes the problem a hundred times worse. By including an 0x01 character after the @ symbol in the fake URL, IE can be tricked in to not displaying the rest of the URL at all. Don't expect a patch for a while either; the guy who discovered the bug released it to BugTraq on the same day he notified the vendor."
1303-1,"passage: Most people reading are probably aware of the common trick whereby spammers and other assorted ne'er-do-wells publish URLs with usernames that look like hostnames to fool people in to trusting a malicious site - for example, http://www.microsoft.com&session%123123123@simon.incutio.com. This trick is frequently used by spammers to steal people's PayPal accounts, by tricking them in to ""resetting"" their password at a site owned by the spammer but disguised as PayPal.com."
1304-0,"passage: I'm sure there are performance and stability issues that make most of the above more trouble than it's worth, but I think you'll agree it's a pretty exciting technology."
1304-1,"passage: LUFS-Python provides a relatively simple API for implementing new Linux filesystems in pure Python. You install the package, write a class implementing methods for handling filesystem operations such as creating a directory, opening/reading/writing/closing a file, creating symlinks etc and finally mount your new filesystem with some special arguments to the mount command."
1304-2,"passage: At first glance, this is a bit of a gimmick - why would you want to write your own filesystem in the first place? We've been talking about this at work and came up with a few ideas. How about a filesystem where HTML files saved in a certain directory were instantly run through HTMLTidy and converted in to valid XHTML ? Or a custom network filesystem that saves files on a remote server using GnuPG to encrypt them before transfer? How about a read-only filesystem that lets you browse the contents of a MySQL database? Just imagine being able to use tools such as grep and find to search your database. A module that maps someone elses public web server to your own filesystem, making mirroring as easy as running a recursive cp command. A filesystem that updates a swish-e full-text index every time a file is saved to it - years before Microsoft release Longhorn. The possibilities are endless."
1304-3,"passage: Here's a really fun idea: a filesystem that implements a dynamic website. Instead of using tools like mod_python to dynamically create pages, implement a filesystem that dynamically creates HTML files as they are requested and set up a stock Apache install with the dynamic filesystem as the document root. Then point ProFTPD at it so you can log in via FTP and mess with your content dynamically. We're thinking about bulding an FTP interface to our new database driven CMS, but we could just build a filesystem interface and point our FTP server straight at it."
1305-0,"passage: The other thing I'm currently mulling over is whether or not blogmarks should allow comments. Jason Kottke's inline links get a decent amount of comment traffic but I'm not sure mine would get enough individual traffic to warrant a comments thread for each one. I could always add comments to the blogmark daily archive pages, although that could get confusing on days with a lot of comment-worthy links."
1305-1,"passage: I'm up to 110 blogmarks now, and from my point of view they're the single most useful feature I've added to this site in a long time. I've modified my day archive pages to show the blogmarks added on that day, and I'm considering adding them to individual entry pages as well so that an entry is displayed along with the blogmarks added while that entry was at the top of my blog. The idea there is that I could aim to blogmark ""related items"" for the top entry, although obviously unrelated sites would end up in there as well."
1305-2,passage: Does anyone actually look at the blogmarks? Would you comment on them or read the comments if they were available?
1306-0,"passage: Enhancing Structural Markup with JavaScript is my first published article for SitePoint, a web development portal that is also home to some of the best web design forums on the web. I've been a big fan of SitePoint for a number of years and it's great to finally have contributed something to the site. The article discusses two methods of building useful Javascript effects on top of well structured markup and is based on my easytoggle and blockquote citations experiments, both previously featured on this blog."
1306-1,passage: Associated trivia: The dopey looking photograph the accompanies my profile was taken outside a youth hostel in Amsterdam earlier this year.
1307-0,"passage: Ian Bicking has an interesting pieces on using static publishing in a CMS. The choice between static and dynamic when building software for the web is a critical one, and one that I think deserves in-depth discussion."
1307-1,"passage: Static content generation certainly isn't appropriate for every project, but for plain content sites sites that don't need dynamic features it's a much more viable option than many people think."
1307-2,"passage: In addition to the performance and reliability benefits, an additional benefit is that static generation provides a simple ""staging area"" style feature for free. Both the coupons and the gallery interfaces allow users to make multiple changes to site content safe in the knowledge that none of the changes will become visible until the ""Publish Site"" button is selected. At first I was worried that this extra step could prove confusing, but in practise it allows our content producers to make changes in a safe environment, without fear of accidentally breaking the public site while they are working."
1307-3,"passage: I've been developing dynamic sites almost exclusively for the past two or three years, but a couple of my most recent projects were static rather than dynamic. These were the LJWorld.com Coupons site and the KUSports.com photo galleries. I wanted to write both of these in Python, because doing so would make the process of transferring them over to our new mod_python powered CMS (currently in development) far less involved. Unfortunately our main production servers don't currently have mod_python configured, and we weren't overly keen on setting it up there for the sake of a couple of small projects. Instead I decided to write the administration interfaces using Python CGI scripts, but generate the actual front end pages (which would see far heavier traffic) as static files."
1307-4,"passage: A big part is that it takes the pressure off of going live. I can be sure before going live that the public website is correct. The actual CMS may explode in flames, but the site will be fine. Going live with a web application is always a stressful process, and anything that reduces the stress of that is a great benefit. As time goes on, static publishing is also a big stress reduction for the system administrator, since a simple Apache configuration is a lot more reliable under different loads and configurations than any dynamic site will be."
1307-5,"passage: At first glance, the benefits of dynamic publishing are obvious. What is frequently ignored are the benefits of static publishing, at least for content-driven sites which don't have any heavy need for dynamic features. The most obvious benefit is performance; serving static files is what web servers such as Apache are optimised to do, and they can do it fast. A second advantage is reliability, as Ian explains:"
1307-6,"passage: The most widespread example of a static publishing system I've seen is Moveable Type, which rebuilds static files for a site each time a weblog entry is added or modified - although it can be configured to serve content dynamically instead."
1307-7,"passage: In a static publishing system, HTML pages are pre-generated by the publishing software and stored as flat files on the web server, ready to be served. This approach is less flexible than dynamic generation in many ways and is often ignored as an option as a result, but in fact the vast majority of content sites consist of primarily static pages and could be powered by static content generation without any loss of functionality to the end user."
1307-8,"passage: In a dynamic site, pages ar
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment