In a previous article, I gave some tips on how to pick a web host. Here we discuss the best way to set up your hosting and development environment.
The first decision you need to make is what stack to use. 80% of the worlds websites run on the LAMP stack. That’s:
- Linux servers
- Apache serving and routing software
- MySQL database
- Perl or PHP datamover
Luckily, you don’t even have to worry about the first two (they’re selected by your hosting provider). Chances are, they’re already following my advice. On the off-chance that your host is running on Windows (vs. Linux) servers, it’s no big deal. When I worked at Yahoo! I installed this stack on their internal Windows servers and it ran fine.
As for PHP and MySQL, these are the coding languages that make your website dynamic (so you don’t have to recreate the wheel every time you want to post new content). The way they work is simple. Think about a news site like npr.org. They have a whole bunch of stories on any topic you can imagine. And each story has a number of ‘assets’ such as the headline, the body, the audio file, an image, etc. The crazy thing is, for all its thousands of stories, the NPR.org storypage is just one HTML document. Every time you click on a story, the web server is delivering that single page and then merging in data from a giant spreadsheet. I say ‘merging’ because this is exactly like the mail-merge process you use when you want to send out the same letter to a bunch of people. In this case, each story is a row in the spreadsheet, and each asset is a column. MySQL is the spreadsheet, PHP is the little piece of code that tells the HTML page that it needs to pick up something new from the spreadsheet. As an example, check out this story: http://www.npr.org/templates/story/story.php?storyId=100815944. The first part of the url (everything up to story.php) tells your browser where to find the html document. Story.php is the HTML document (which, as I said before, is a single document for all stories). Everything after the ‘?’ is known as the ‘query string’ and this is what PHP uses to look up the assets in the story archive spreadsheet. PHP reads this, finds story number 100815944, grabs all the information about the story (including the text of the story) and displays it on the page.
There are viable alternatives to PHP (such as Python and ASP), but I’d recommend sticking with the crowd. By doing what everyone else is doing, you’re securing a long future of support for your code.
Installing PHP and MySQL is a cinch. Most webhosts offer an admin tool that allows you to install each by selecting a single checkbox. If your host doesn’t provide this service, you can find instructions on the install at both the PHP and MySQL sites.
You do eventually need to learn MySQL and PHP (which has replaced Perl as the dominent data-mover on the web), but you don’t need to learn either to start a website. The best place to learn these languages is Tizag. This is a free, learn-by-doing tutorial that will have you coding in no time. And it’s simple. I was an English major with no prior coding experience, and I was able to pick up PHP and MySQL in two weeks by working through the tutorials for about a half hour a day. The key is to actually do each of the examples on your own server. To do that, I recommend downloading the excellent (and free!) Komodo development environment. Komodo is just a text editor, but it color-codes your code as you go, so you know when you make a mistake. It also offers syntax suggestions as you type, so you don’t have to remember everything that goes into an expression.
But let’s assume, for now, that you’re not going to bother to learn how to code. If you want to be able to quickly deploy new content every day, you’ll need a Content Management System (CMS). There are thousands of CMS solutions to choose from (and your hosting provider probably offers you at least a dozen choices that you can install on your server with a single click. A good place to learn about the best CMS for you is CMS Matrix. Here again I will make the recommendation that you stick with the open-source (that is, free) platform that is favored by the crowd. The two most popular solutions are Drupal and WordPress. Drupal is for serious websites and is a bit more flexible than wordpress, but it’s not user-friendly and it doesn’t really give you anything out of the box. WordPress is a hit with bloggers because, well, anyone can use it. The best thing about wordpress is that its community of developers are pushing the flexibility of the platform so that it can increasingly handle the kind of serious web applications that hertofore would have been the realm of Drupal. If you want a CMS to learn on, WordPress is for you.
Once WordPress is installed, follow the instructions on how to set up your site. Don’t worry about making the wrong decisions here (you can always go back and change it with minimal effort). Just play around and get to know the software.
When you really understand WordPress, go back and learn PHP and MySQL, which are the platforms on which everything in WordPress is built. After that, you may want to get a good book on Ajax. Ajax helps webpages talk to each other (and with the server) so that you can change the content of a webpage without reloading the page. I don’t recommend getting too far into the weeds with javascript (instead learn jQuery, which is a shortcut way of writing ajax and javascript that automatically works on every browser). If you’ve installed WordPress, you don’t even need to install jQuery, because it comes with the package. Have fun out there!
Economic Analysis
Economic Calendar
Real Clear Markets
Undervalued stocks
Value Cruncher
Wikinvest
2 Comments
Some relevant links I found:
2010 comparison chart Blogger vs. WordPress (see cool widget chart in same post)
conclusion – “If WordPress.com allowed stylesheet editing without having to pay, and visitor stats comparable to the tracker scripts you can obtain for free, my choice would have been WordPress.com for sure.”
http://pulsed.blogspot.com/2007/07/blogger-wordpress-chart.html
Link to free download of Komodo Edit
http://download.cnet.com/Komodo-Edit-Windows/3000-2352_4-10700439.html
squarespace.com has evolved tremendously since this article was written a year ago