Spam Killed My Backups

April 21st, 2009

Having up-to-date backups is an essential safeguard in case something goes wrong with your website. So some time ago I installed WP-DBManager and configured it to send a daily backup of my WordPress database to my GMail account. All was well, until last week the backup process failed five times in a row. Upon checking […]

Continue Reading...

7 Firefox Addons For Viewing The Web Your Way

March 28th, 2009

The Web is big. You just won’t believe how vastly, hugely, mind-bogglingly big it is. I mean, you may think it’s a long way down the road to … oops, wrong reference. Still, the Web really is huge, and in addition to all the well-designed and accessible sites you use every day (right?), there are […]

Continue Reading...

Text Classification With PHP

March 7th, 2009

Text classification is probably the most popular real-world application of machine learning and other AI techniques. This is because the adaptive spam filters that guard our inboxes, comment forms and guestbooks are basically specialized text classifiers that only deal with two categories – “spam” and “not spam”. Text categorization can also be used to detect […]

Continue Reading...

New Web Load Testing Service

February 22nd, 2009

You can never have too much stats, right? Today I came across a new load testing site that might provide you with some interesting data points. LoadImpact.com simulates multiple users accessing a website and presents a simple report on how long the server took to respond. Here’s an example report : You can run the […]

Continue Reading...

Make Your Plugin Faster With Conditional Tags

February 22nd, 2009

One of the reasons why WordPress can be slow is that it loads all active plugins on each and every page, even if some of those plugins aren’t actually used on that page. For example, an active anti-spam plugin will still be loaded even if the current page doesn’t contain a comment form (e.g. category […]

Continue Reading...

How To Identify a WordPress Theme

February 15th, 2009

Say you stumble upon a WordPress blog that has a gorgeous design. Amazed, you wonder what theme they’re using. Of course, it would be straightforward to just email the blog’s author and ask, but it might take a few hours (or days) until they get back to you. Here are three simple ways to identify […]

Continue Reading...

Top WordPress Plugin Niches

February 11th, 2009

As a plugin developer, I sometimes wonder what makes a plugin popular. How come some plugins garner hundreds of comments and thousands of downloads, while others pass quietly into the archives? What kind of plugin do the users want? Obviously the plugin’s niche (what kind of stuff it does) would be a huge factor. For […]

Continue Reading...

WordPress API Resources

January 14th, 2009

[Here’s some list-cliche-filler stuff while I fight off a (hopefully) temporary bout of unproductivity and dentists] WordPress internals are documented pretty well, but sometimes finding the right API/Codex page can take a while. That’s why I’ve decided to put together a comprehensive list of all APIs used by WordPress to serve as a “jump-off point” […]

Continue Reading...

How To Speed Up Sociable

January 10th, 2009

I’ve always cared about WordPress performance. I’ve optimized my database, tweaked the server’s configuration, used plugin profilers and installed WP Super Cache and PHP Speedy WP – the “heavy artillery” of performance-related plugins. However, only recently did I decide to finally track down and fix all the remaining subtle issues that may cause slow loading […]

Continue Reading...

Inventing the Future RSS Reader

January 7th, 2009

In this post I’ll discuss some of the failings of existing RSS readers and suggest a few wistful and highly hypothetical improvements. The genre is moderate technobabble, the layot – web2.0 bulletpoint-y. A lot is left to your imagination to allow for personal interpretation (and other things that rhyme with “elation”). Would you like to […]

Continue Reading...

Get Google Search Results With PHP – Google AJAX API And The SEO Perspective

January 5th, 2009

If you’ve ever tried to write a program that fetches search results from Google, you’ll no doubt be familiar with the excrutiating annoyances of parsing the results and getting blocked periodically. Run a couple hundred queries in a row and bam! – your script is banned until proven innocent by entering an captcha. Even that […]

Continue Reading...

Top 10 WordPress Plugin Developers

December 28th, 2008

As the year is coming to an end, perhaps it’s time for a different kind of “Top X” post. Instead of a list of new WP plugins to try out, here are the top plugin authors – the brilliant people who create outstanding tools and share them with the WordPress community. The list is ranked […]

Continue Reading...

Fast Weighted Random Choice In PHP

December 10th, 2008

Sometimes you may need to randomly select items from a list so that some items are selected more frequently than others. For example, you might take a list of applications and their download counts, and randomly pick a “featured application” based on the number of downloads. There are several ways to accomplish this in PHP. […]

Continue Reading...

Cross-Domain POST With JavaScript

November 20th, 2008

Normally you can’t send cross-domain requests in JavaScript due to restrictions imposed by the same-origin security policy. There are many clever hacks that circumvent this by using remote script includes (even CSS includes) or proxy scripts, but so far I haven’t seen anything useful for client-side, cross-domain POST requests. However, it turns out you can […]

Continue Reading...

Displaying Recent Posts On a Non-WordPress Page

November 15th, 2008

Listing recent posts on a WordPress page is easy – there are various widgets and theme functions available just for that purpose. But what about a non-WP page, or even a different site? That’s not that hard either – simply grab some posts from the blog’s RSS feed and output them on your page. In […]

Continue Reading...

Parse, Edit And Create Torrent Files With PHP

November 11th, 2008

A .torrent file contains assorted metadata that is stored in a “bencoded dictionary” format. Bencoding is a relatively simple cross-platform encoding used by BitTorrent and a dictionary is basically an associative array. You can find a high-level overview of the file structure here. To open or edit a .torrent file in PHP you can either […]

Continue Reading...

JavaScript Splitters And Resizable Panels

October 23rd, 2008

In this post I’ll review* several splitter components for JavaScript. A splitter is usually a vertical or horizontal bar that you can drag to change the size of the surrounding elements. Most splitter scripts also depend on, or are part of a JS framework, which may be an important consideration if you’re already using some […]

Continue Reading...

Private Message Sender Script For vBulletin Forums (PHP)

October 9th, 2008

Random script time! Here’s a PHP function that can send messages to any user on a vBulletin forum. I wrote it because somebody asked me if I could help with their code and I figured it would be easier to write it from scratch. Also, I predict it will be useful to more than one […]

Continue Reading...

The Benefits of Using Hooks Instead Of Plugin-Specific Functions

September 21st, 2008

Lets talk about that plugin-related code you have to put in your theme files when you want to add something nifty to your blog, like a “Related posts” feature or AdSense ads. It occurs to me that most plugin authors have been handling this the same way – you get a custom function that you […]

Continue Reading...

Google Chrome vs Opera – JS Speed Test

September 3rd, 2008

With the recent release of the Google’s Chrome browser lots of sites have jumped on it and started churning out reviews. However, most reviews focus on Chrome vs Firefox – for example, I have already seen no less than three articles discussing whether Chrome’s brand new JavaScript engine is really faster than the one used […]

Continue Reading...

Yay, WordPress 2.6 Is Out

July 15th, 2008

I’m sure you know why I write this. A new version of WordPress is out, and I’ve upgraded this blog immediately. So here are the mandatory first impressions (nope, I don’t use SVN betas). Just conforming with the unquestionable avalanche of review-style posts that have appeared, with more no doubt being written right now. Right […]

Continue Reading...

How To Get Redirect URL In PHP

July 5th, 2008

HTTP redirects usually have the response status 301 or 302 and provide the redirection URL in the “Location” header. I’ve written three complementary PHP functions that you can use to find out where an URL redirects to (based on a helpful thread at WebmasterWorld). You don’t even need CURL for this – fsockopen() will do […]

Continue Reading...

How To Create a MySQL Database In cPanel With PHP

June 24th, 2008

A PHP class that uses cURL to log in to cPanel. Can create MySQL databases and users, add users to databases, list existing databases, and more.

Continue Reading...

TOR : How To Switch To a New Identity Using PHP

June 20th, 2008

A simple PHP function that can make TOR switch to a new identity. The script also supports TOR authentication.

Continue Reading...

How To Add User Agent Switch To “Quick Preferences” In Opera 9.5

June 15th, 2008

A short guide that describes how to add the Identify as Opera/IE/Firefox user agent options to the Quick Preferences popup menu. This method works in Opera 9.5 and, hopefully, later versions.

Continue Reading...

Improved Thread Simulation Class for PHP

May 24th, 2008

Two classes that use asynchronous HTTP POST requests to simulate multithreading (works on Windows, too!). The Thread class simulates a single thread of execution, whereas ThreadManager is an utility class that makes handling multiple threads easier.

Continue Reading...

Building a DeviantArt Recommendation Engine

April 29th, 2008

DeviantArt, with its huge number of artworks and a large userbase, is just the kind of site that could use a good recommendation engine. A recommendation engine is basically a program that analyzes your tastes and recommends some images that you might like. There do not seem to be any official plans to create a recommendation system. So I went ahead and started building my own recommendation engine for DA.

Continue Reading...

Simple Text Summarizer In PHP

April 12th, 2008

I’ve written a simple text summarizer that can find the most important sentences in any given (English) text and produce a summary of the specified length. It would be pretty easy to adapt the PHP script to other languages, too.

Continue Reading...

Scrape Google Blog Search With PHP

March 28th, 2008

I’m currently lacking real “bloggable” ideas, so here’s something simple and hopefully useful – a PHP script to get the blog search results from Google. The script is provided strictly for educational purposes, blah blah blah. And by the way, if you only need the top X results, it would be simpler to use the […]

Continue Reading...

Free Tools for Natural Language Processing

March 13th, 2008

I’ve compiled a list of various Python modules and functions that I found most useful in certain Natural Language Processing tasks. For easier skimming, the list is grouped by NLP task, such as tokenization and tagging.

Continue Reading...