Web Development
British Kings and Queens
by Mike on Mar.09, 2010, under General, Projects, Web Development
So, another AdSense site is up and running. British Kings and Queens was built in PHP using CodeIgniter. There are a lot of pages, mostly generated from the database.
I wrote all of the content myself, which took around 4-5 hours. I’m hoping this unique content will pay off, but I’m currently not seeing much traffic.
Check the site out, I actually learnt quite a lot about British History and past Kings and Queens of Britiain whilst writing it.
British Kings and Queens
All Phobias
by Mike on Feb.24, 2010, under Findings, Projects, Web Development
A couple of nights ago I decided to do a little experiment. I was going to create a generic website with a few hundred pages of content, SEO the hell out of it, and see if I can earn anything from AdSense.
The website is All Phobias, and it lists every ‘known’ phobia out there. It’s written in PHP ontop of CodeIgniter. I created a small C app to scrape all of the data off a few different websites and generate some SQL for me. All in all the whole thing took about 4 hours to make. The design is some crappy free one I downloaded, as I’m not really interested in how it looks.
I’ve made sure every page has everything it should like unique titles, h1 tags and all the meta tags to go with it. I have also made a couple of blogs on external websites and made 5-10 posts on each, some linking to the site, and some not. I’ve submitted to some free submission sites, as well as linking from all of my major sites with a decent page rank.
I’ve submitted a hefty sitemap (I think there were 750 pages) to Google, but the domain is still in the incubation period, so I guess I’ll need to wait a couple of months to see any real progress.
Since the site went live 2 nights ago it’s earnt me a whopping £2. Which, to be honest, isn’t bad at all. If I can earn £1 a night from 2 nights work then I’ll be a happy man. Do the math on that, 15 sites per month, for 6 months, that would be ~£90 per day, or £2.7k a month. Not bad. My hope is that in 6-8 months time it will be top of Google for a lot of keywords ‘all phobias’, along with many of the actual phobia names and short descriptions (’fear of spiders’, for example), at which point the £1 a day would easily jump up to £5-10 per day, with a bit of luck.
Linux Portal – Linux News and Linux Articles
by Mike on Jan.31, 2010, under Projects, Web Development
So I’ve owned Linux Portal for as long as I can remember, but not really done much with it. Originally I created it to aggregate some of my favourite Linux RSS feeds from the sites I read the most, but it became a bit of an effort to maintain for something that had very little rewards, because of that I just left it with some RSS feeds with links to the articles on the home page. Nothing new and nothing interesting.
I recently decided to update it though. A similar principle but putting the sturdiness of WordPress to good use. I now use some of those same feeds that I used originally to pull in the articles. I then publish those articles to the blog as posts, all on-the-fly, and totally automated. I update the blog about once a week and it will grab new posts from the feed and publish them.
There were some initial teething problems though. I had ‘Post-to-twitter’ plug-in along with the Google Sitemap generator plug-in both running at the same time. So, when I added a new feed it would pull in around 50 posts. That meant grabbing all 50 posts from the source, then posting 50 new messages to Twitter (in quick succession), and on each post it would generate a new sitemap.xml, update robots.txt and notify 5 search engines of the change. Quite a massive task for one webserver really. Inevitably, the server came to a standstill every time. I’ve since solved it by disabling the plug-ins but if the site takes off I might create a cron job that checks for updates and then notifies Twitter and the sitemap plug-in to run periodically.
If you’re interested check the site out, there are Linux Articles and Linux News.
Enjoy
Football Badges 50,000
by Mike on Jan.26, 2010, under Projects, Web Development
Another milestone. Football Badges has now reach 50,000 active users. This is the largest Facebook application that I have created to date.
I will be releasing a new Facebook app in the next few days. It has some functionality and will hopefully keep users coming back to use the application, whereas Football Badges is a sort of one-off thing. Keep your eyes peels and the feed subscribed to!
SEO Friendly PHP Twitter Script
by Mike on Jan.25, 2010, under Web Development
There are loads of scripts out there for pulling in your Twitter posts. A lot, if not most of them, base themselves heavily on JavaScript. This is bad for 3 reasons:
- People with JS disabled can’t read them
- It’s bad for your website’s search engine rank (SEO) as the search bots can’t read them
- It slows user’s browsers down (if only slightly)
I have written a very simple PHP script that pulls in your Twitter posts, and outputs them in an unordered list. Feel free to use however you like:
<?php
// Your Twitter username
$username = 'mikemike86';
$rssUrl = "http://twitter.com/statuses/user_timeline/$username.rss";
$rss = @file_get_contents($rssUrl);
if($rss){
$xml = @simplexml_load_string($rss);
if($xml !== false){
$var=true;
foreach($xml->channel->item as $tweet){
//echo $tweet->pubDate."\n";
echo ''.substr($tweet->description,(strlen($username)+2))."\n\n";
if($var){
break;
}
}
} else {
echo "Error: RSS file not valid!";
}
} else {
echo "Error: RSS file not found. Username invalid or requires authentication";
}
?>
PHP json_encode Alternative
by Mike on Jan.25, 2010, under Web Development
The amount of times I’ve been working on a project and the environment hasn’t had the useful json_encode function installed due to PHP being < version 5.2 is quite worrying. So, I decided to write my own replacement. How very decent of me. You can use it as you will. I wrote this a long time ago, but I've noticed it's somehow wormed its way onto the php.net site under someone elses name, and someone else seems to be taking credit for it. Oh well...
<?php
if (!function_exists(’json_encode’))
{
function json_encode($a=false)
{
// Some basic debugging to ensure we have something returned
if (is_null($a)) return ‘null’;
if ($a === false) return ‘false’;
if ($a === true) return ‘true’;
if (is_scalar($a))
{
if (is_float($a))
{
// Always use “.” for floats.
return floatval(str_replace(”,”, “.”, strval($a)));
}
if (is_string($a))
{
static $jsonReplaces = array(array(”\\”, “/”, “\n”, “\t”, “\r”, “\b”, “\f”, ‘”‘), array(’\\\\’, ‘\\/’, ‘\\n’, ‘\\t’, ‘\\r’, ‘\\b’, ‘\\f’, ‘\”‘));
return ‘”‘ . str_replace($jsonReplaces[0], $jsonReplaces[1], $a) . ‘”‘;
}
else
return $a;
}
$isList = true;
for ($i = 0, reset($a); $i {
if (key($a) !== $i)
{
$isList = false;
break;
}
}
$result = array();
if ($isList)
{
foreach ($a as $v) $result[] = json_encode($v);
return ‘[' . join(',', $result) . ']‘;
}
else
{
foreach ($a as $k => $v) $result[] = json_encode($k).’:’.json_encode($v);
return ‘{’ . join(’,', $result) . ‘}’;
}
}
}
?>
Facebook Ads or Google AdWords?
by Mike on Jan.12, 2010, under Findings, General, Web Development
In the past I have used several different online ad platforms for a little bit of advertising here and there, but the two that I (along with the majority of e-marketers) prefer is Google AdWords. Recently I have begun using Google AdWords more heavily.
There is a lot of hype about Google AdWords and how it can work wonders for your website. I’m not entirely sure I could agree with that. Google definitely have the biggest audience for the ads, but that doesn’t mean it’s better value for money, or whether the audience is more targetted.
Facebook Ads is the Ad management tool for displaying ads on Facebook, and personally my favourite ad platform. Due to Facebooks nature the customisation of the Facebook ad’s is phenominal. I recently launched an advert for one of my Facebook applications (you can advertise anything*) that is designed for Baseball fans. I was able to tell Facebook that I only wanted to display the advert for users who are in the USA (where the Facebook app is hosted) and who are fans of Baseball and like some Baseball TV shows. This was a great help as it meant maximum exposure. Having said that, it doesn’t neccessarily mean I’ll save any money…
Pay per click is what it says… you pay every time someone clicks your ad. Google AdWords is pay per click. Facebook allows you to run campaigns on a pay per click or a pay per impression basis. This gives huge amounts of flexibility and allows you to save money depending ont he type of advert. If I was advertising a car insurance company then I’ll want to have it display to a large number of people, so I’d run pay per click, only paying if someone clicks through. But if I was advertising a car insurance promotion that only female students aged 21 or above, attending university in the UK, then I can easily drill down to only have the advert display to girls in 3rd year of uni or above who live in the UK – it’s then much cheaper to pay per impression, as less people will see it, but the one’s that do see it are more likely to click. Facebook also tells you how many users it has meeting this criteria.
Facebook is also MUCH cheaper than Google. I recently ran a campaign for the project Downtime Preventer. The average cost per click on Google was over £5. The average cost per click on Facebook was £0.05. You can see that this is a massive difference in price. However, the reason Google excels is the amount of traffic it receives. It took me a month to get through £15 on Google, for ‘downtime’ related keywords, hardly worth doing. On Facebook it was quite difficult to pick specifics for the campaign, so ended up going for ‘All users with their on company page’, hoping that would be small business owners.
Another plus Facebook has over Google are the ads themselves. Google is text-based only. Facebook allows more characters and one small image. The Facebook ads are subtle enough to not disturb the user but allow the advertiser to get their point across more easily.
Although my preference is definitely with Facebook, Google has it’s plus points. Facebook can only be used for so much before Google comes into it’s own. If you’re advertising a huge campaign then Facebook just won’t cut it, the audience just isn’t the same. The Downtime Preventer example is a good one, as it goes to show how difficult it can be to advertise something niche.
The bottom line is this: Google knows what people might be looking for and displays your advert, Facebook will display ads that people might like.
If you remember that golden rule then you’ll probably make the right choice.
Plans for the New Year
by Mike on Jan.06, 2010, under General, Projects, Web Development
Well, it’s a new year and as everyone else are starting their fitness regimes, I’m thinking about what projects need finishing off, beginning and pushing.
2009 was a good year for me and some great accomplishments were made. I graduated with my Software Engineering Degree, I got ‘best project’ of 2009, I started my job as lead developer over at Reckless New Media and I have begun several important projects of my own.
Towards the beginning of 2009 I began work on the Football Badges app, which now has (at time of writing) well over 35,000 active users, with over 15,000 signing up each month. With the success of this project I decided to branch out with some similar projects including University Badges and more recently Baseball Badges. As expected Uni Badges has not been as popular with only 1,000 active users, Baseball Badges however is growing very fast, and it’s rate of growth reflects that of Football Badges.
Another finished project taken on this year was Downtime Preventer, a system built to notify web site owners of downtime via email and SMS within minutes (if not seconds) of the downtime occurring.
A joint project that is completed that was launched earlier this year is QueryLife. QueryLife is a social network that asks thought-provoking questions to users every day. Users can add their friends and view/comment on friends answers. Answers are not simple text-based answers, but can instead be stories told by text, imagery and video. The project has been created in a partnership between myself and the guys over at Creative Happy.
Other projects that are VERY close to deployment are ‘Officing’ and ‘Dont U Forget’, both web applications built for specific purposes and unlike anything out there at the moment.
So, my plan for the first quarter of the new year is:
- Promote Downtime Preventer
- Complete Officing and deploy live
- Complete Dont U Forget and deploy
- Market QueryLife
Once I’m happy that this list has been satisfied I will not doubt begin a new project, maybe something to do with Andoird…
Football Badges 30000
by Mike on Dec.29, 2009, under Projects, Web Development
Yet another milestone, Football Badges now has (close enough) 30,000 users. There are around 15,000 new users signing up per month at the moment, so hopefully we’ll hit the 100,000 mark very soon. There are 300,000,000 people using Facebook at the moment, so I think 1 in every 3,000 people having my application on their profile isn’t such a bad thing, do you?
Baseball Badges
by Mike on Dec.16, 2009, under General, Projects, Web Development
Similar to Football Badges I have just released Baseball Badges. The ideal is exactly the same, you add the application to your Facebook profile and it will display your favourite teams badge. Most major league teams are listed but more can be added on request.