Archive for the ‘Tech’ Category

PDF files – the most heinous crime against the Internet?

Tuesday, September 22nd, 2009

A long time ago in 1993, Adobe decided to create a format for sharing files called “PDF” that was allegedly independent of application software, hardware, and operating system – this three letter acronym quickly grew infamous as millions worldwide were exposed to the format. The catch, of course, was that for a long time, the free (and thus most common) way of viewing these files, was with a terrible program called “Adobe Acrobat” (now “Adobe Reader“). This program is really quite astounding, in that it essentially transforms your computer into a badly bound photocopied version of whatever content you were trying to view in PDF format, in fact, if one views enough PDF files, one might come to believe that one doesn’t actually posses a computer at all. This leads me to believe that PDF format was in fact funded by some sort of anti-technology secret society – perhaps the Amish or the like. Although – in the contemporary version – there is now an option to “save as text”, this option is still basically useless for most practical uses, such as viewing a spreadsheet that’s been sent to you in PDF format in Excel or Open Office.

If you are unfortunate enough to encounter a PDF file that must be viewed, there is a good download called “pdf download” by “Nitro PDF Software” – you can get it here for Firefox or IE7/8. While this software is useful, I am not sure if “Nitro PDF Software” is a company that has the best morals. After all – they’re essentially profiting off of one of the worst crimes against human civilization (PDF).

In any case, it seems obvious to me that the secret intent of PDF format was to inhibit the technological advancement of mankind. The tragedy of the PDF atrocity, is that, unlike the holocaust, mankind has not learned its lesson from this atrocity (except Bosnia, Darfur, Chechnya, Tibet, and such) – and PDF files are still in wide and open circulation today. Even though all of the evils of PDF files are known, there are still people out there who continue to create and distribute them as if they were oblivious to the plight of the many who are forced to interact with PDF format on a day-to-day basis. When will we, as a species, stand up for our rights and shout as one “ENOUGH IS ENOUGH!” I – for one – have had enough. It’s my sincere hope that, in the future, humanity can be free of all forms of oppression and intellectual suppression – why not start by quashing PDF?

Google Analytics tracking for subdomains – works!

Sunday, September 20th, 2009

Well – as a follow up post to my last one regarding adding subdomain support for Google Analytics – it’s working! It’s trivially easy to make GA work with subdomains, so much so that I’m honestly not sure why this isn’t the default behaviour already :S

It’s always fun to bring someone new into the world of GA – Tuzi is definitely having fun with all of the different filters, reports, and whatnot. Next on the list is probably finding a good wordpress mod that inserts analytics script into themes automatically; it’s not really an issue right now as I only have four themes enabled, but it will definitely be an issue as the site expands.

Adding Tracking for Subdomains with Google Analytics

Thursday, September 17th, 2009

Tuzi asked me to make her an account so that she can see who is viewing her blog; I just finished updating the tracking code and adding the filter – time to see if it works I guess.

I found a great blog post that I’ll share with those of you who might want to attempt something similar:

Tracking Subdomains with Google Analytics (epikone.com)

I’ll post an update probably on the weekend regarding whether or not this worked!

Great PHP Development Platform: Eclipse

Wednesday, August 12th, 2009

I’ve been writing PHP for a rather long time, and up until just recently I did it the old school way – I used EditPlus (basically notepad with syntax highlighting). I give you Eclipse:

Downloads Page

I was recently introduced to this excellent development platform, and I haven’t looked back. Besides taking care of little things like completing matching braces and being able to double click on a function (even user defined) for its description or being able to tell if a method overrides a parent method, it also has a great CVS plug-in. I’m still actually just figuring that part out, but already it’s making programming a lot more enjoyable for me by taking away a lot of the “dirty work”. I highly recommend Eclipse to PHP developers.

Redirection problem for admin login from WordPressMu 2.6 -> 2.8.1 upgrade

Sunday, July 19th, 2009

Welp – writing this update from WordPress Mu version 2.8.1 – the admin definitely looks pretty good, and I like the extra support for Google Gears. I encountered a little bit of trouble that someone with less webdev experience might find extremely puzzling.

A redirect issue (infinite loop) is caused if you have old cookies for the previous WordPress MU install and try to log into the admin panel. As you might expect, the solution is to delete the offending cookies (in my case, I just deleted all cookies for verstory.com and was good to go).

It’s a bit troubling that this advice wasn’t posted on the upgrade page of the WordPress MU sites, but, such is life.

Emulate max-width / max-height for Internet Explorer (no extra work needed!)

Saturday, July 11th, 2009

As I’m sure many of you know, Internet Explorer (even IE8) completely ignores the max-width and max-height css properties. I did some Googling but unfortunately all of the stuff I found was for manually setting the max-width/max-height or some similar buffoonery. I’ve written a nice Javascript (uses jQuery) function that you can include in your head tag to emulate proper detection of the max-width and max-height css attributes without doing any extra work after that (so long as it’s in the head of the content you’re loading with max-width/max-height attributes). Feel free to use it but please keep my copyright statement if you don’t mind!

Cheers and happy designing:

function css_emulateMaxWidthHeight() {
/* (c) Evan Roberts - 7/10/2009
www.GoWFB.com - Wholesale Furniture Brokers
Everyone is free to use/mdoify this but please keep the copyright statement!
*/

	$('img').each(function() {		

		if( $(this).css('max-width') != 'none' || $(this).css('max-height') != 'none' ) {

			max_width = $(this).css('max-width').replace(/[^0-9]/g, '');
			max_height = $(this).css('max-height').replace(/[^0-9]/g, '');		

			if( $(this).width() > max_width || $(this).height() > max_height ) {
				if( (max_width / $(this).width()) < (max_height / $(this).height()) ) {
					$(this).css('height', Math.round($(this).height() * (max_width / $(this).width())));
					$(this).css('width', max_width);
				} else {
					$(this).css('width', Math.round($(this).width() * (max_height / $(this).height())));
					$(this).css('height', max_height);
				}

			}
		}
	});
}

$(document).ready(function() {

	css_emulateMaxWidthHeight();

});

Solution: Secondary LCD monitor flickers when laptop connected to AC power

Monday, April 27th, 2009

A secondary monitor is a very useful thing when you do anything that requires multitasking. In my case, as a web developer, it’s pretty much essential, at the very least being a huge productivity booster. I had this strange issue with my laptop, though, wherein my secondary LCD monitor would flicker if my laptop was plugged in (connected to AC power). Strangely and baffling to me, though, if my laptop was running from its battery, there was no problem at all. Naturally, this led me to suspect my power supply, my laptop’s AC adaptor, the laptop battery, the power bar, the LCD itself, and even my display drivers. Nothing helped.

Solution: THE VGA CABLE. Now, conventional wisdom would probably lead one to assume that the VGA cables that come in the box with your new LCD monitor would be of at least relatively decent quality. If you’re having the same issue that I had, this is incorrect. Apparently most LCD manufacturers are too cheap to include higher quality dual shielded VGA cables with their monitors. The VGA cable that came with my monitor (BenQ T2200HD) only had a shield (the round thing an inch or so from the plug(s)) for one plug. Replacing the cable with a double shielded cable immediately resolved my problem, to my great relief.

I Googled for untold hours trying to fix this issue, and found some similar posts, but none with a solution. I posted on a tech support forum and none of the techies seemed to know. I am telling the world: GET A DUAL SHIELDED VGA CABLE! Shame on manufacturers that include substandard accessories with their products!

I sincerely hope this post reaches those who need it. If the post happens to help you, leave a comment with your story if you don’t mind =)

Remove ads and annoying stuff from MSN messenger!!!

Tuesday, January 20th, 2009

Solution: A-Patch

This is simply awesome – the only thing that pisses me off about the new version of MSN messenger is the abundance of intrusive advertisements. A-Patch, affectionately referred to some as “Arab Patch” on account of all the “Praise be to God” and “Learn about Allah” shit on their site, is a surprisingly good mod for MSN messenger that lets you modify the interface and functionality to better suit your needs.

I highly recommend it.

While we’re on the anti-ads subject, there’s an excellent mod for Firefox that gets rid of almost all advertisements as well:

Ad Block Plus Download

Cheers – oh, and God is great and all that..

Too many links = bad for PR

Monday, January 19th, 2009

I was pretty happy with my Page Rank of 2, however that seems to have plummeted and now my page is “grey” AKA unranked. This happened after I posted a bunch of youtube impression of poker episodes. I think it’s also interesting to note that the videos that I linked to were mostly unranked.

The question now, is whether or not, after those pages disappear from my front blog page, my former PR will return. I suppose we’ll see after I get another seven posts up, so I guess it’s not all bad, as it gives me incentive to keep writing :p

Wikipedia on Page Rank: http://en.wikipedia.org/wiki/Page_rank

Disgruntled Customers have Recourse thanks to Google

Tuesday, December 23rd, 2008

I was checking my mail (Gmail) last night when I came across and interesting text ad. Now – I NEVER and I mean NEVER click on text ads, but this one caught my eye for some reason or another. It read “Cinese Furniture Beware” and linked to a simple one page site. If you check out the site yourself, you’ll see that it shows a number of photos of damaged furniture and the complaints of a customer who was apparently shafted by the company.

In an age in which online marketing can have a hand in determining the success or failure of many third world country export companies, I think this is a very positive sign. Through Google and a little cash spent on adwords, the disgruntled customer has a reasonably viable recourse against bad business practises. If he targets “Cinese Furniture” as his keyword, then anyone who is getting email from that company and using Gmail will most likely see his ad, and think twice about making a deal. Also – the savvy customer who searches for “Cinese Furniture” will most likely see the site “cinesefurniturebeware.com” on account of the keywords in the domain name.

Certainly living in a more connected world has all sorts of advantage, and promotes general liberty and equality; like the press, it ensures that unethical companies / people are more likely to be held accountable for their actions, unlike the press, however, you don’t have to be a tycoon in order for people to hear your message. I can only hope that Google stays “not evil” as they say, and continues the good fight.