Get Google Image Search Results With PHP

February 28th, 2008

Google Image Search doesn’t get as much time in the spotlight as the “normal” Web Search, but it’s still useful for things like finding suitable illustrations for an article (Flickr also comes to mind). Whatever you use it for, you can often get results faster with a bit of automation. Here’s a simple PHP script that can parse and return the results of any Image Search query. For education purposes only.

Continue Reading...

Random Person Name Generator

February 7th, 2008

I decided to put a person name database I found to good use and make a person name generator. Here it is! The generator uses Markov chains. Most of the source code is available for download.

Continue Reading...

Extracting The Main Content From a Webpage

January 25th, 2008

I’ve created a PHP class that can extract the main content parts from a HTML page, stripping away superfluous components like JavaScript blocks, menus, advertisements and so on. The script isn’t 100% effective, but good enough for many practical purposes. It can also serve as a starting point for more complex systems.

Continue Reading...

Raw HTML Plugin for WordPress

December 13th, 2007

Recently I needed to put some style definitions and a JavaScript function in a post on another blog that I have. I wasted several hours trying to do this, because WordPress insisted on putting backslashes in front of my apostrophes, inserting superfluous <p> or <br /> tags in place of newlines, and generally breaking my HTML in various horrible ways.

In the end I decided to just go and write a plugin that would let me put any code or script in my posts and display it to the visitor unmodified.

Continue Reading...

Detect Users Accessing Your Site Via a Proxy

November 23rd, 2007

The are many reasons why someone might want to detect if users are accessing their site via a proxy. For one, all spammers use proxies. Proxies can also be used to cheat voting systems, create multiple accounts when only one account is allowed or make it appear like the user is browsing from a different […]

Continue Reading...