Twitter quote aggregator

I’ve written a little script that pulls quotes tagged with #quote from twitter’s stream. You can take a look at 9quotes.com

Hidden Message In Blog Source Code

I’ve read about hidden messages in source code before, but I think I’ve just found an original hidden message after looking through the source code for a site:

You can check it out yourself at static income daily.

I think this is something we should all do. How many clients check the source code?

Brighton Letting Agent Phone Numbers & Fees

I’m planning to move to Brighton pretty soon and my girlfriend and I spent a long time yesterday ringing round all of the Brighton letting agents (including Hove) asking about their fees and whether they accept a guarantor letter or not.

Hopefully this will prove useful to someone else who is looking to move to Brighton. Sorry the format is a bit weird – I just pasted it straight from an XLS file. Let me know if you want the full xls file instead.

Disclaimer: this info is correct as of 24/8/10 but it may well change and I don’t intend to update this list at all. So please check before you sign any contracts.

Name Tel (01273) Fees (per person) Do They Accept a Guarantor?

Khalil 735904 £125 employed £80 unemployed Yes

Property Moves 321333 Yes

Brighton Accommodation Agency 0845 873 8126

2Let 220144

Kendrick 699600 £155 everything Yes

Martin & co 607698

John Hilton 608151

Harringtons 724000 £150, month’s rent in advance and month’s rent deposit Yes, for both

Countrywide 329776

King & Chasemore 606303

GK Whites 606060 £125 Yes

Foundations 626258

Just Lets 208020 £150

Oakley 688882 £125 Yes

Stephen William & co 686477

Cambridge Residential 204037

Brighton Homes 672333

Leaders (Fiveways) 561534

Michael Joseph Estates 748828 £152.75 Yes

Parks 202089 £120 pp + £95 household Yes but need evidence

Tingleys 710038

Your Move 778588 £150 Yes

Brand Vaughan 205550 Yes

Massey 727278

Direct Lettings 324535

Storm 710005

Wilkins 207208 £165 + vat yes

PJ Palmers 771115 £125 + vat yes

01 Property Letting 915101 £125 + one off £65 yes

Tanat Jones 207207 £176.25 yes

Spencer & lee 565566 £125+vat yes

Northwood 715890

Home Leasing 323344 £130 depends on landlord

Paul Andrew 732362 £115 accidentally lied and said we all worked

St James Lettings 483434 £100 + £20 for guarantor yes

Barry Alderton 570242

Bonetts 677365 £125+vat yes

The Property SHop 915400 £70 total for tenancy agreement + £100 total for credit check forgot to check

BN3 Homes 771155

Lanes Lettings 600068

Pavillion 686306 £150 yes

Rand & co 417 788

Sawyer & co 778844

Let It Bee 220003 £170 + £55 (for 2 bed inventory) yes

David Webb 300 525

Amberstone 252 858 £150 for first person + £50 per person after yes

Hove Lets 735555 £150+vat yes (£75+vat)

Brian Marshall 583453

Calaways 735237 £188 yes

Let’s Go 236547

Mishon Mackey 670 067

Priors 737586

The Worst Example of Web Form Validation Ever

I make websites. I spend a lot of my time thinking about how to make websites more user-friendly and efficient. As a result of this, whenever I see a website that has an extraordinarily bad user interface it makes me angry. This particular example of eye-watering inefficiency came in a letter from Camden Borough Town Hall (my local council). Read more »

Beware of the & (ampersand) character when parsing XML using PHP’s SimpleXML

If you are getting errors like “parser error : EntityRef: expecting ‘;’” when trying to parse some XML using SimpleXML, it could be because your XML file or string contains an & character. Do the following to remedy the situation:

$correct_xml = str_replace('&','&',$problem_xml);

Ajax content, jQuery page transitions and why you should ditch the browser refresh

no browser refresh

Down with the browser refresh

I’ve just finished a project I’ve been working on over the last couple of months that was a jQuery-based ajax application without page refreshes. I thought I’d take this opportunity to share some of the problems I encountered whilst they were still fresh in my mind.

If you’re thinking of making your own jQuery online app I’d recommend trying out the ‘no refresh’ method. Once you’ve got it working, you’ll wonder how you’ve managed to cope so long with all these page refreshes, and each time somebody else’s site forces your browser to refresh, you’ll throw up a bit in your mouth.

In my humble opinion, asynchronous data transfer is the future and soon it will be very unusual to have your page refresh every time you want to see new content. Browser refreshes are clunky, ugly are an unnecessary interruption to the user experience flow.

With jQuery and ajax ruling your content you can have:

Read more »

Restoring conventional page navigation to your javascript application with jQuery history plugin

I’m not sure how, but my jQuery application suddenly got very complicated. One minute I was adding cool onmouseover effects and then BANG I’m inserting new elements all over the place and I have to look into heavy compression just to get the thing to download this side of the apocalypse.

Browsing through my application is a breeze. All the links are rewired to AJAX requests with smooth transitions and lots of slideUp-and-downs. There’s one glaring hole that might just bring this happy user experience down quicker than a Lehman brother wearing Iron Boots.

Whenever my lovely users click ‘back’ on their browser they get taken back to the obscenity that is the non-standards-compliant flashing gif-ridden site they came from, not the last thing they were viewing on my site. And if he or she clicks ‘refresh’ the application state goes back to the original and my user has to navigate back to the page he or she was viewing all over again. What a knightmare.

The browser navigation controls – back, forwards and refresh – are a staple of any user’s experience. Of course, being a web developer you will recognise the lack of page refreshes and the changing of page elements and automatically look for site-specific navigation links on the page itself. However, your average user is going to get very confused, thinking their browser buttons are broken or worse – your website is broken.

And it’s not only the user that’s going to encounter problems. If a Google Spider can’t see pages with unique URLs it’s not going to index them. So all I’m going to get on a Google search is whatever is on the landing page, which is just header information and a footer – not very useful. If my user wants to bookmark a page for later, he or she is going to have to start again, before all the AJAX fun began. The list goes on. It’s like building a vast palace with turrets and different wings but neglecting to build any doors. Your guests are going to walk over the drawbridge and marvel at the splendour of your architecture, the complete set of Power Ranger themed bedrooms, yet have no idea how to get there.

Anyway, here’s how I solved it:

Read more »

Query’s Maphilight Plugin Tutorial – Create Cool jQuery Image Map Hover Effects

Update: you can see the finished version of my map here.

So I want to make a big map of europe that hilights the different countries when you move your mouse over them. Initially I thought this would be really easy using a bit of CSS and :hover . . . . no dice. But to my surprise I found out that it’s possible to use an ordinary HTML image map to define some pretty complex shapes, and let’s face it, shapes don’t get much more complex than this.

OK, so it’s possible to create clickable areas in HTML using an image map, but how do I add rollover effects to this? CSS didn’t seem to work so my next port of call was the wonderful jQuery. I found a plugin call mapHilight that takes an HTML image map, and adds some javascript hilighting wizardry to it. You can see a really cool example using a map of the states, this is almost exactly what I want but for Europe. I’m going to try and record everything I do, in the hope that someone else might find this useful, so here goes.

Read more »

JQuery Image Dimensions

Simple code to grab the dimensions of any image on your page. Here’s an example:

My Image

Tell JQuery to find out how big this image is by using:

var width = $("#my_image").width();
var height = $("#my_image").height();

spEak You’re bRanes – the pile of steaming faeces that is the BBC’s “Have Your Say” site

Working for the BBC’s “Have Your Say” site is a position to aspire to. On the one hand, you are trying to stop the plague of racist, vacant armchair generals spreading their hatewords. And on the other hand, you are trying to promote the independent, unbisased journalism that has made the BBC a household name worldwide.

At least, that’s what you’d think.

Two examples of how this is not the case come in the forms of ifyoulikeitsomuchwhydontyougolivethere.com – “A collection of ignorance, narcissism, stupidity, hypocrisy and bad grammar” that are comments taken from the site, and NewSniffer.co.uk – a site that dsiaplys comments that have been censored, and tracks changes to BBC articles. The ‘Recommended Revisions’ section shows that many article updates have a different agenda to the average typo corrections you’d expect.