Saturday 8 July 2017

So you want to use a framework?

Ahh there's nothing quite like putting fingertips to the keyboard on a new project, especially when you've been pouring over planning documents and fleshing out ideas for a while.

My experience with "from scratch" website development is limited.  I've made a number of functional projects but nothing worth writing home about.  I've been through the homebrew mess of getting a dynamic site up and running and even played around with CodeIgniter in the past in an effort to migrate away from trivial development.  When I started my research into frameworks the message I heard was "use Laravel".  I'm not an expert and besides I'm uninterested in debating the finer points on whether that advice is fantastic or not but I've decided that I will take the advice, come what may.  If nothing else, then as so many other projects, I'll get experience in a popular technology.

For years my development host of choice has been GoDaddy.  For those of you who have finished rolling your eyes, it's cheap and relatively reliable.  When I tried to get Laravel installed there however, the problems began.  The TL;DR version is that I chose to install everything to my Windows 10 machine and upload it to the server whole rather than try to force the GoDaddy server to let me install Laravel directly.

For some of you who found this post hoping for insight on how to get the job done on the server -- don't.  First I migrated from my old Linux hosting package to the new one to get the support of PHP7 as the old servers cap out somewhere in version 5, if you're lucky.  This was a nontrivial bit of work and involved moving a networked WordPress site, phpBB installation and so on.  Surprisingly my own code dragged and dropped over rather seamlessly.

I then discovered that you cannot get a straight answer on what version of PHP is actually installed because your ssh connection to the server runs on a different server than the one that hosts your page.  In other words your phpinfo.php page and your php -v outputs can differ completely.  The web page server will run PHP7 but there's no guarantee your back end will.  At some point you'll get stopped by needing some sort of access that you simply won't get and then you'll be where I am: change hosts or install locally and migrate.

Ok ok ok.  So that's where we've been in this adventure to try out Laravel.  As with any project like this that is not a work project I find that the ones I am most familiar with get done first and the ones that have some uncertainty or insecurity about the technology get pushed off longest.  Tonight I bit the bullet and started down the path to getting this actually working.

I've started this blog because I'm sure some other developers have been through some of these headaches and if this becomes nothing more than a collection of "how to" pages, so be it.  Hopefully I'll have something more interesting to say as we go along.  I didn't want to get tied down in setting up a WordPress site for this project so I'm using the simplest thing that came to hand.  Tonight's goal is to get the first Laravel test project fired up, not to go through pages of templates looking for a slick site :-)

... and away we go...