Tag Archives: Laravel

Setting up Laravel 4 via Tutsplus

I’m planning on writing up a post about the Laravel framework and why I’ve chosen it for my new foray into PHP and away from Coldfusion.
In the meantime, Tutsplus and Jeffery Way have put together a nice tutorial for setting up Laravel 4, the yet-to-be-released next version of the PHP framework that’s really getting a lot of buzz lately.
I also highly recommend the Laravel Essentials course by Tutsplus, also by Jeffrey Way, as well as the tutorial series by Shawn McCool at Laravel.io.

Why I’m moving from Coldfusion to PHP

People have spent a lot of time both predicting the death of Coldfusion, as well as refuting that assertion. Of course, it’s not really “dying”. It’s still very popular in government and higher education (I don’t have any stats to back this up, but this is what I’ve observed). Everywhere else, however, it’s market share appears to be small compared to PHP, Rails, etc. I blame Macromedia/Adobe for not providing a free, open-source version and for not marketing it sufficiently. Railo has filled the open-source hole, but it’s too little, too late.

It doesn’t matter that Coldfusion is a great tool for Getting Things Done. New developers are going to be drawn to languages with thriving frameworks (yes, CF has frameworks. I like CFWheels. There just aren’t many under active development and a lot of CF developers still don’t use them), low cost entry, and unlimited hosting choices. Old developers see that fewer new opportunities include Coldfusion as the solution in spite of its strengths. So you have to be able to adapt.

I can’t go into great detail in comparing Coldfusion to [your language here] because I’m a self-described hack. If you want that, you can check out this blog post and comments. Frankly, I don’t build apps large enough that would really expose the weaknesses and strengths of CF, PHP, etc. I do know that I can do cool things with very little code in CF and the PHP learning curve is slowing me down for now. But it doesn’t matter any way. What matters is career survival and future opportunities.

Why PHP?

Everything above that I described as a negative about Coldfusion is just the opposite with PHP. Tons of active frameworks, supported by just about every web host, unlimited opportunities, low-cost entry, etc. etc.

It’s really reached a new level of maturity with 5.3+ and frameworks like Laravel promise to bring some of that Rails developer-love back to PHP. I’ll do another post later about Laravel from a hack’s point of view, but I’ve already discovered the power of command-line PHP using Laravel’s Tasks and Artisan. I can see the value of Composer while playing with the Laravel 4 alpha. I can see the value of being able to publish an app on infinitely more web hosts than is possible with CF.

So basically, Coldfusion, it’s not you, it’s me.

Moving from MAMP to OS X’s built-in apache, etc. Not fun.

So I just got my 5-year old Macbook Pro back from Apple* after it sat dead for several months (my kid killed it playing Minecraft). I decided I needed it for do some web work in the family room while pretending to watch the Real Lives of Whatever with the family.

I have the impression that real, tough guy developers don’t sissy their way into a local dev environment using MAMP. You gotta use the built-in version of Apache, and download, make, make test, make install, etc. etc. everything else. So that’s what I did.

The Apache part is easy because it’s already there. So is PHP (5.3.15 for Mountain Lion I think). However, it doesn’t include mcrypt, which is required for Laravel. To get that working, just follow the 20 or so steps here, which including getting the latest version of Xcode. Fun.

MySQL was fairly easy if you choose the package installer (sissy) over compiling it yourself (tough guy).

Once it’s finally working, you feel good about yourself, then realize that the mysql ports are different for the dev machines that are still using MAMP and share the same code, PHP CLI isn’t in your path, you don’t know how to switch between PHP 5.2/5.3 if you need to (easy with MAMP), etc.

So in the end, I just went back to using MAMP.

The End.

*Apple has a nice deal where they fill fix anything and everything for $310.