Archive

Archive for June, 2009

Most Visitors In a Single Day

June 24th, 2009 amclean No comments

I’m a single visitor short of this being my most visited day ever. Or that is to say, I’ve tied my best day ever. Very encouraging after my seemingly long absence. And there are 2 1/2 hours left of the day in my time zone alone, so there’s some time yet.

Just throwing this idea out there, but if anyone wants to do any sort of link exchange, I’m open to it. I feel a bit weird going from site to site soliciting them, so I’m hoping if I just say I’m all for it that some of you will throw yourselves at me.

I almost feel like link exchanges are cheating, but that’s only because it’s a bit of a new field for me. And many of you are bloggers like me who crave the traffic or Google page rank, so you’re probably all used to it by now.

Thanks for reading

Categories: News Tags:

XBMC advancedsettings.xml Continued

June 24th, 2009 amclean No comments

I recently decided to tackle a problem that has plagued me from the beginning in XBMC.

Some time ago, I changed the naming convention of my files to something that was cleaner and more logical to me. The format used to be like this example:

Burn Notice/Season 1/Burn Notice – 101 – Pilot.avi

I noted that having the name of the show was completely unnecessary, as was the season since I could infer from the number that it is season 1 episode 1.  So I spent some time renaming and moving things around to something more like this:

Burn Notice/101 – Pilot.avi

Much cleaner, no fluff.

The problem at first was that for some reason, this broke XBMC’s scraper’s fragile little mind, and thus it could not scrape episodes anymore. So I did some research and found that advancedsettings.xml offered a solution, which I mentioned in a previous post.

What I failed to mention in that post was that there was a single catch. One show I have is called “The 4400” which was tragically cancelled before its fifth and potentially last season. When I added the folder to the library, it would recognize the show title and apply a general synopsis I could view of the entire show, but the episodes contained within that folder refused to be scanned into the library database. I’ve suffered this for ages. Every time I reinstalled or upgraded or created a new instance of XBMC for PC or my Mac Mini, I copied over my custom advancedsettings.xml file to each.

As it turns out, the scraper problem has been fixed for ages, and my own solution was preventing it from working. Today I installed XBMC on my beloved laptop for the first time as an experiment, and I intentionally left the advancedsettings.xml file out. Sure enough, The 4400 scanned in immediately as well as all the episodes, synopses and screenshots.

So that’s that. I removed the “tvshowmatching” tag from the xml file and left my other customizations in place, as now the default setup works for me.

Categories: Software Tags:

ColdFusion Jobs?

June 24th, 2009 amclean 6 comments

So I took some time off to get some work done. dColumbus and I cranked together some great work in record time. Having him do the forms in Flex in itself saved me days of work, and I must say the end product is something we’re both quite proud of.

But due to the downturn in the economy, several of my jobs have dried up, and thus the amenities I have grown accustomed to I can no longer afford. These being rent and food, primarily – and not to illicit sympathy, but this includes for my wife and two very young children.

Among other things I do contract work locally as a mobile tech, not unlike the Nerd Herd from NBC’s “Chuck”. However back in march, the workload dropped drastically from around 3-4 hours a day to now 1-2 hours a week.

I’m looking to continue my education in Coldfusion and general application development, but locally there is limited need and I find it mentally draining trying to compete with India on most of the freelancer sites available. So the question I pose to you, my colleagues, mentors, tutors, and readers: where do you find ColdFusion work?

Please, please, please comment.

Categories: ColdFusion Tags:

The Long-Awaited Return of Adventure Games

June 21st, 2009 amclean 8 comments

I long for the days of the old Sierra and Lucasarts Classic adventure games. The Laura Bow Mysteries, King’s Quest, The Dig, Full Throttle, Monkey Island. It’s been a long time since there’s been a great adventure game. Developers such as Quantic Dream – the creators of Fahrenheit (Indigo Prophecy here in North America) and the upcoming Heavy Rain – and Funcom – the developer of The Longest Journey series – have been bright lights in a dark age of first-person shooters and “sandbox” games.

I mainly play games for story. If the storyline isn’t fun, the gameplay certainly can’t save it. I admit, I’m the guy most mainstream gamers seem to hate. I have patience for cutscenes that go on for several minutes. I’m not chomping at the bit to move on without knowing what the story holds – my primary motivation to continue. Truth be told, if I were to watch someone else play a game start to finish, I would be equally satisfied as if I had played it myself and there would be no need for me to play it over.

And so it is my pleasure to discover that Lucasarts may be ushering in the second age of Adventure games, starting with a remake of The Secret of Monkey Island, the original pc adventure, and releasing it on Xbox Live Arcade later this year. This will be a scene-for-scene remake with huge graphical and auditory improvements as well a fancy new hints system for the uninitiated gamer.

I daresay this could bring some intelligence back to the gaming world. One where puzzles don’t always involve shooting things in sequence, or moving heavy objects. A world where dialog isn’t an afterthought.

I am extremely excited about this and have been angry with developers (read: Lucasarts) because they stopped making adventure games altogether, opting instead to make some pretty mediocre ones – exceptions being the Knights of the Old Republic games, which are only a step removed from an adventure game so that’s ok. I hope that the world of gamers are with me in this, and I hope we can send a message to developers that says we are DYING for some good adventures. That there IS a market for it.

And then the floodgates will open again.

Categories: Games Tags:

Taking A Break

June 12th, 2009 amclean No comments

I’ve taken the week off of writing to get some work done.  I’ll return next week with some new articles.

Thanks for reading!

Categories: News Tags:

I Hate Domain Squatters

June 8th, 2009 amclean 2 comments

dcolumbus and I just spent the ENTIRE day trying to narrow down a domain name for our newest project. Sadly this would have been done in the first 20 minutes of brainstorming if it weren’t for domain squatters having bought up every last domain ever. This of course was amplified by the fact that we arbitrarily decided on a .com TLD and not a .org or .net

Something has to be done about this problem. Domain squatting should be made illegal. It is not cool and is the lowest form of internet business.

Categories: News Tags:

ColdFusion Brush For SyntaxHighlighter Evolved

June 8th, 2009 amclean No comments

It has been brought to my attention that I have not yet made reference to my code highlighter provided by “SyntaxHighlighter Evolved”. Or more specifically the fact that it doesn’t come with ColdFusion support and yet here on my site it does. Well I can’t take the credit, a quick Google search yields the true source, http://www.jensbits.com/2009/05/14/coldfusion-brush-for-syntaxhighlighter-plus/.

Categories: Coding Tags:

cftry/cfcatch With Database Response

June 8th, 2009 amclean 3 comments

I did a search on cftry and cfcatch, and somehow I missed the logic behind some of the pages describing it. So I’m writing up a quick example in hopes that maybe my demo will light someone’s bulb more than the rest.

I’m writing a backend for a system whose frontend is Flex. The flex expects a response of 100 for a successful process and 101 for an error, plus a couple detailed responses for debugging purposes. This is returned in XML format which the Flex application is expecting, but I won’t bother including the formatting in the code since it’s all too simple to output XML.

In this case, the Flex form is submitting some values for a user to change some profile settings.

<cftry>
    <cfupdate datasource="testdb" tablename="users">
    <cfset success="True">
    <cfset status="100">
    <cfset desc="Everything worked">
<cfcatch type = "Database">
        <cfset success="False">
        <cfset status="101">
        <cfset desc=cfcatch.message>
</cfcatch>
</cftry>

There are a number of <cfcatch> types, most of which I have not yet had opportunity to use. But it is worth noting you can “try” a number of operations together and also “catch” multiple operations within the same <cftry> tag. The “type” attribute tells ColdFusion what it’s trying to catch. This includes types such as “MissingInclude” or “application” to correspond to missing include file errors or general application errors.

In PHP it was a different process as a mysql_query tag could give a Boolean response to indicate it worked. In ColdFusion this might be possible as well but I could never manage to get it to. So if you want any sort of success/fail response from a cfupdate, cfinsert or cfquery (or any other function for that matter), the above is what you’ll need to set up.

 

Categories: ColdFusion Tags:

Why ColdFusion Is So Great With Databases

June 5th, 2009 amclean 4 comments

Having just come from developing PHP for around a year, switching to ColdFusion was an interesting experience.

Being a bit anal about everything seems to help with PHP, but this is true of most languages. For example closing every tag you’ve opened, validating every form to correct user input and handle any mistakes, or explicitly stating every behaviour a page should have.

I have heard it said that anything you can do with ColdFusion you can do with PHP, and vice-versa. However, I’ve found that although it takes some getting used to, there are some distinct advantages to CFML.

How often have PHP developers created a form that takes values, then creates an update or insert query to the database? I recall this to be not entirely painful, but very verbose. First of all, you would either have to write an include file to hold the db connection information, or simply type it out at the top of the script:

mysql_connect(host,username,password)
or die("Error connecting to Database!" . mysql_error());
mysql_select_db(database)
or die("Cannot select database!" . mysql_error());

In ColdFusion this is unnecessary. The connection information is specified server-side as something called a datasource, so it requires 0 lines of code until the query itself is made.

This brings us to the query step.

$query="INSERT INTO users (FirstName, LastName, Age) VALUES ('$_POST[firstname]','$_POST[lastname]','$_POST[age]')";
mysql_real_escape_string($_POST(firstname));
mysql_real_escape_string($_POST(lastname));
mysql_real_escape_string($_POST(age));

$result = mysql_query($query);

Technically the mysql_real_escape_string should be used to prevent anyone from inputting anything to intentionally (or unintentionally) corrupt your database, and is standard practise for sanitizing database inputs. In ColdFusion, however, queries are much easier.

<cfquery name=”query” datasource=”database”>
INSERT INTO Persons (FirstName, LastName, Age) VALUES (#firstname#,#lastname#,#age#)
</cfquery>

However, this gets even easier.

It’s pretty safe to assume that what gets put into the database at any point generally comes from some kind of form. Well the form basically spits out the same thing every time, even if the value is blank. So say someone fills out a form containing the firstname, lastname, and age as above and submits it. ColdFusion could handle it all and put it in the database with this:

<cfinsert datasource="database" tablename="users">

What that single line of code does is amazing. It takes the values passed from the form (IMPORTANT: This assumes that the form variable names passed forward match the names of the columns in the database, which is best practise anyway), and automatically creates a query to insert these new values into the database. The same is true for the <cfupdate> tag. Not only that, but ColdFusion has an automated character escape feature, so it always assumes you want special characters escaped when performing a query.

ColdFusion skips all the boring parts of working with databases, and lets you just do what you need to.

Categories: ColdFusion Tags:

A Bad Week For My Xbox Consoles

June 4th, 2009 amclean No comments

My Xbox 360, purchased launch day November 4th, 2005, at exactly 43 months old died today of general hardware failure. The device and I conquered worlds together, collecting well over 20,000 Gamer Points over its lifespan. The evening before its death we were solving some of Orange Box: Portal’s challenge puzzles when suddenly it froze. I thought nothing of it, rebooted and carried on. But at about 1:30 this afternoon, it would not come out of a deep sleep and instead flashed me with three ominous red lights.

It is survived by several games and mourning family members.

I bragged in an earlier post that I was unaffected by the dreaded “Red Ring of Death” despite owning a launch console. Ironically just over two weeks later, here I am lamenting the loss of the very same console. It’s not a total loss – I get to keep the hard drive, and Microsoft has seen fit to still sell the Arcade consoles with no drive…

Categories: Xbox 360 Tags: