Great Free Differencing Tool for Mac

For some odd reason, searching in Google for a file differencing tool for Mac does not return anything promising. The best I found easily was a blog post saying to use the FileMerge that gets installed with Xcode. You can run it from the command line.

Command line? Look, I am a Microsoft developer most of the time. That means I both expect and need things to be kinda easy.

Luckily, I searched a little further and found Sourcegear's DiffMerge. Just like you would expect, graphical, easy to use, and free.

Thanks, Sourcegear!

Crank Out Some iPhone Apps - Outsource Them!

If you have been reading my blog, you know my story--I am a Microsoft developer by day, and an iPhone/iPad developer by night. The problem--when you have a wife and kids and a house (or even a social life) this is not really sustainable for long.

With iOS4 coming out, I have been doing a little less coding lately and a little more reading about iPhone development. One of the things I have been reading is books by others promising ways to write apps quickly or make money on iPhone apps. A lot of them I just laugh at. So when I read an ad promising to let me write iPhone quickly without writing code--well, I had to read the book just to see what they were promising.

To my surprise, it was a really good idea! The book, How To Create iPhone Apps with No Programming Experience is actually a great step-by-step methodology to get apps built the easy way--by explaining what you want and handing it off to someone else to code. The book comes with a few extras, the most interesting on how to make money with free apps, which you probably already know. But the book itself was a good read. If you have any thoughts about trying to write an iPhone yourself but just don't have the time, this is a great solution.

The best part of the book was the description of some of the completely ridiculous apps that have made big money. The point being, of course, that marketing is every bit as important in the iPhone app gold rush as programming. You can have a slick app, but if you have no marketing plan, it will disappear in the mountain of apps released daily. Conversely, if you have an idea for an app that you can market, maybe a crazy simple app could make you rich. And if you outsource them, you can crank out ten in the time you would have done one yourself.

Anyway, check out How To Create iPhone Apps with No Programming Experience. It is a great no-nonsense approach to getting your app out there for people to download.

BTW--I have unofficially crossed the 50,000 app download mark. How exciting is that!!

Review process for iPad apps--Yikes!

So I submitted my first iPad app almost 2 weeks ago. After being lulled into a false sense of confidence following iPhone app reviews, I have had a bad experience with this review.

iPhone app reviews had gotten down to a few days at the end of last year and earlier this year. So I expected the iPad app review for my first app to be, I don't know, vaguely like that.

When I saw my app go from "submitted" to "in review" so quickly, I was very optimistic. But then came an extremely long delay. And OK, I am fine with a delay--I am sure everyone is submitted iPad apps right now.

But then came the frustration. After 8 days (yes, 8 days) I get a notice that my app had been rejected. The reason? I had called it "FindIt for iPad" on the title screen, and this is a copyrighted term. Fair enough--I probably should have thought of that. But what required 8 days to figure out that "iPad" was prominently placed on the main page?????

Then, of course, the process has to start over from scratch. Again, I get it--a new binary, and anything can be in it. So the new executable has to be completely tested. So we are now a full 16 days from the initial submittal. And I don't have much confidence that it is really being reviewed any more when it says "in review." (See rant above about "how did it take 8 days to figure out 'iPad' was prominently placed on the main page.")


Scary stuff. Hopefully this helps someone out there avoid the same issue I had.

Anybody need $5/mo PHP hosting?

So it turns out I overbought my PHP hosting a bit....and I have a bunch of extra bandwidth. It is great hosting from HostNine, including MySQL database, Control Panel, Fantastico Deluxe with Joomla and WordPress, etc etc. I bought a reseller account because I needed to host for several of my clients. This was a good deal, but I have a bunch of unneeded bandwidth that is going to waste.

Anyway, let me know if you are interested. We can work out how much throughput and space you need. You can't get quality hosting like anywhere for $5/month!

I think I can take on 4-5 new accounts, so I will offer this deal to the first 4 or 5 people to get in touch with me. Good luck!

Best. Mac Memory. Ever.

I have really wanted for a while to upgrade my MacBook Pro from 4G to 8G, but I didn't want to fork over the $800 (recently dropped to $600) to get it from the Apple Store. There are lots of sites out there that offer premium memory for discount prices--how do you know you will get good memory and good customer service? You ask your other Mac friends where they get there memory!

Luckily, my friend Dave Ferrell (a.k.a. XCodeGuy) has owned Macs for a long time and has a number of do's and don'ts when it comes to software, hardware, and peripherals. He recommended RamJet.com, which he said has great prices and the memory has always worked for him.

I have to say the customer experience with RamJet was above average. Between the emails alerting me to the status of the order, the status of shipping, and the status of my refund, I was very impressed. Yes, I said REFUND. RamJet will buy back your existing memory for a nice price. I was able to buy my new memory for $359 and get $50 back for my Apple memory. So for almost 1/2 the price of the Apple memory, I got my 8G and I am loving it!

So, if you need solid memory for less than you would pay for genuine Apple memory, you can't miss with RamJet. Thanks guys!

Pretty tired of Magic Mouse issues

As you are probably aware, I am huge fan of the Mac and of Apple products. The are solid, well engineered, and I have had few issues with any Apply hardware.

Except for the Magic Mouse, which has caused me a lot of frustration. My first mouse I got at Christmas of 2009 for use with my early-2009 unibody 2.66Ghz MacBook Pro. It worked great for a while--it was easy to make the transition to it, and I really like having the desktop even less cluttered because it is wireless.

But then, after a few months, I started experiencing a strange issue. A large percentage of the time, even if I clicked all the way over to the left of the mouse, it would act like I was doing a right-click. After having my wife try it too (to make sure I wasn't doing something wrong) and confirm it was acting strangely, I took it back and had it replaced.

Then, everything worked well for a few months. Until I disconnected the MacBook Pro from everything and used it away from my mouse and keyboard. Ever since I brought the MacBook Pro back and reconnected it, I have to manually disconnect and reconnect the mouse every time I start up my laptop.

One of the things I love about Apple products is that they just work. We pay a premium for them, and they are worth it, because they save us time. But what about when they don't work? Then we paid a premium for junk--and worse yet, with high expectations, because Apple stuff is supposed to *just work*.

This is definitely the kind of thing that would have annoyed me on the PC. On the Mac, I am just fed up. I want my money back.

Detect IE6 and redirect to compatible site in CRE Loaded

There are tons are beautiful CRE Loaded sites--if you are ever in the market for one, I personally am a huge fan of AlgoZone and RocketTheme for CRE Loaded and Joomla themes. But one of the downsides of the nicer themes is compatibility issues. For those of you who have not jumped on the CSS bandwagon, or for others of you unaware of the "old days" of web development, there has been a huge shift over time in the way styles are applied to sites.

In the old days, tables were your only tool. Whatever you needed to do, you created tables, nested tables, and played with table attributes. Tables could do a lot, but the final code for a complex page was all but incomprehensible, and forget trying to debug someone else's. It could be a real mess to find and fix errors, or to try to add new elements into pages.

The shift over time has been to use CSS styles applied to DIV tags. This keeps a great deal of presentation details separate from the pages, allow for page content to be developed apart from really complex styles. In addition to separating the actual code, this also provides great ways to take a page and render it completely differently based completely on the CSS applied. Content management systems in particular make extensive use of this because their individual widgets can display simple content, and the CSS applied can really change the output. This would have been a very difficult job in the old table days.

So back to CRE Loaded styles. I recently was working on putting a new template on a storefront, when one of my team members thought to look at the in IE6. The results were horrific. The site not only looked bad, elements such as the product menu just didn't show up. We ran some stats and found to our surprise that nearly 10% of potential customers coming to the store use IE6. So something had to be done.

I decided the easiest solution was to set up another domain, check the browser type, and then redirect IE6 users to the other domain. Connection information in CRE Loaded would stay the same, so both sets of users would share the same database, and the job would be trivial.

So, I searched the code and found a good place to put the IE6. The first step was the put the following in includes/application_top.php:


// first.....since IE6 performs very badly with our template....
// detect the browser and send all those poor souls to the
// old template
include('includes/browser_detect.php');

$a_browser_data = browser_detection('full');
if ( $a_browser_data[0] == 'ie' )
{
if ( $a_browser_data[1] <= 6 ) { $url = (!empty($_SERVER['HTTPS'])) ? "https://".$_SERVER['SERVER_NAME'].$_SERVER['REQUEST_URI'] : "http://".$_SERVER['SERVER_NAME'].$_SERVER['REQUEST_URI']; $url = str_replace("www.myDomain.com", "www2.myDomain.com", $url); header('Location: ' . $url ) ; } }



I found some great code to detect the browser type here. I put that code in includes/browser_detect.php.

Then I went to test, and discovered that half the time I clicked on things, I was being redirected to the old site. After some seaching, I found that the domain is actually stored in a few pages of the php script. I changed those, and then I was staying consistently in the new site. Perfect.

Next I went into the admin side of the new site, and changed the template. Oh wait. The default template is stored in the database! The database that I am sharing between the sites! Time for more analysis.

I searched and searched through the code and discovered that DEFAULT_TEMPLATE was the variable that I needed to set, but DEFAULT_TEMPLATE was not set anywhere in the code. I realized my lack of PHP knowledge was hurting me, so I started looking up constant definition in PHP. It became clear that the value was being set somewhere, but searching the codebase had turned up nothing. Then I realized there must be somewhere in the code that all the configuration variables were being pulled in from the database and constants were being created for them.

After more searching, I discovered the code I expected was in includes/application_top.php, not far from where I had inserted the above lines:


// set application wide parameters
$configuration_query = tep_db_query('select configuration_key as cfgKey, configuration_value as cfgValue from ' . TABLE_CONFIGURATION);
while ($configuration = tep_db_fetch_array($configuration_query)) {
define($configuration['cfgKey'], $configuration['cfgValue']);
}



PHP does not allow you to redefine the constants either....so there was no way to let this loop occur and then redefine the value later. Instead, you could either put an if clause in the code, look for DEFAULT_TEMPLATE, and set the value there, or instead set your override value first, then check as you are looping to see if the value is already defined, and only define it if it is not. It was late at night, so I chose the first. The more bulletproof way would really be to set up an include to define overrides and then put the conditional logic in this loop to skip any values that are currently defined. When I have some free time I will definitely refactor this code.

Anyone ever try to do anything like this? Let me know if you had a better solution. Thanks!