to LooselyCoupled.com homepage
 
 Weekly emails: how to advanced search
 Glossary lookup:

 

> how to > AppSwitching diary


Friday, May 03, 2002

Some handy references for regular expressions

I found it very difficult to get my head round regular expressions when doing the code for Pro2rss, and I still need to understand them better to make it more adaptable to different blog layouts. Here are some sources I've found that should help out:

  • PHP Regular Expressions on the PHP Developers website is concise, clear and full of examples.
  • Learning to Use Regular Expressions by Example on the PHPBuilder website is written by someone who started out in the same position as I did. Designed to make up for the lack of examples in PHP's online documentation, it's an easy-to-follow resource.
  • Regular Expressions explained at zez.org. This is written in a clear, approachable style and has lots of examples.
  • MySQL Regular Expressions is on the mySQL website. It's very clearly laid out, but makes few concessions to non-programmers (so for example instead of saying, this works, this doesn't, it just puts -> 1 or -> 0).

posted by Phil 6:00 AM (GMT) | comments | link

Wednesday, May 01, 2002

Adding an RSS feed to a Blogger Pro blog

With the addition of the RSS feed, the Loosely Coupled weblog now has its full complement of features, and work can begin on completing the remaining sections of the site, which includes bringing this weblog live to publish a running commentary on the process of building the site.

Generating a separate subject title, description and permalink for each weblog entry meant adapting existing published sources to create my own PHP program. I've documented what I did on a separate Pro2rss page, which also includes a demonstration you can use to test it out on any blog, and links to the source code if you want to copy and amend it for use on your own server.

Ironically, the only weblog this doesn't work for is the main Loosely Coupled weblog (which is hosted at Jumpline), because of an arcane glitch to do with the way my hosting account for this part of the site (which is hosted at Hostcentric) has been set up. What seems to be happening is that, because the Hostcentric server has LooselyCoupled.com set up as the site name, it attempts to serve requests for any pages under that domain from its own directories — even though the DNS for www.looselycoupled.com points to the Jumpline server. I even tried adding "blog.looselycoupled.com" to the DNS entries for the main site, but that still didn't work. So I've paid Hostcentric the princely sum of $30 to have them change the server name to appswitching.net, in the hope that that will fix the problem.

While these tribulations don't quite compare to the tortuous steps Julian Bond had to take to get some advanced PHP functionality operating on his hosted server accounts, it demonstrates some of the hidden traps that lay in wait for those of us that want to build truly loosely coupled sites. The entire hosting industry assumes that people want to build tightly integrated websites consolidated onto a single server box or cluster. It just isn't set up to support people building highly distributed sites.
PS: I'm going to wait until these glitches are resolved before adding an RSS feed to this new blog, so that's why you don't see an XML button on the site today. But it is tagged up for it, so feel free to test out Pro2rss with the URL for this week's archive page: http://howto.looselycoupled.com/blog/2002_04_28_dy.htm

posted by Phil 2:18 AM (GMT) | comments | link

Building a website using plug-in online services: the Loosely Coupled experience

read an RSS feed from this weblog

current


archives

Loosely Coupled weblog RSS source


 
 


Copyright © 2002-2006, Procullux Media Ltd. All Rights Reserved.