Imagine, if you will, the following scenario:
- You design a whole new database schema for your cool new scalable web-application. You’re using MySQL and the InnoDB datbase engine for everything, because your schema is so cool it uses all sorts of foreign keys and transactions and the like.
- You quickly set up MySQL and get your application going with your new schema on your development staging machine.
- You get MySQL up and running on your live server, play around with it for a bit to make sure it’s working, and then set up a my.cnf file with all sorts of caching and security goodies in it.
- You do a backup from your dev machine, restore it to the live server, and ta-daa!!! Your web application is up and running on your live server.
What you might not have noticed, especially if you – like me – have a few thousands rows of data, is that MySQL might have screwed you along the way and not really told you all that clearly.[Read Rest of Article]
Sorry for the long pause in updating. I have spent the last couple of months writing a new blogging engine to power the Chipmunk Ninja web site. The problem with comments and extremely annoying process via which I would post new articles was getting to be a real problem.
The new system, while superficially quite similar to the old one, has a number of major new features:[Read Rest of Article]
One of my favourite things about PHP 5 is how nifty the object-oriented features are. I have been able to put together surprisingly robust web applications using simple class hierarchies and abstract classes, features that only took off in PHP with the version 5.0 release. One of the other things I have loved is using the the various built-in object-oriented classes provided by the runtime, most notably the
mysqli and related functionality.
One extremely common task I complete is to use database storage for session data. When you are running multiple web servers and individual HTTP requests might go to different machines, trying to come up with a scheme to synchronise session data files between the individual servers becomes prohibitive. Far better a solution is to simply put these data in the database server along with everything else (see Figure 1) – your application servers hold only the code needed to generate the pages from the database.[Read Rest of Article]
As I sat down to edit “Core Web Application Programming with PHP and MySQL”, I would sometimes find errors in the text so blindingly obvious and stupid that I would question whether or not I was truly qualified to write such a book. And yet, after talking with some other people who write books (and recalling days when I wrote huge amounts of code), it seems that this is all common and with much proof-reading and the hard work of some friendly reviewers, I was able to write a book of extremely high quality.
Of course, that just meant I would be even more devastated when the first technical errors WERE found in the book.
There have been a couple, but they’re not that killer serious.[Read Rest of Article]
Many Mac OS X users seem to be having problems getting AMP (Apache, MySQL, and PHP) working properly on various versions of the operating system. In this article, I will describe the process by which I did this on my Powerbook which started out running Panther (10.3) and then Tiger (10.4) (the instructions are the same for both OSes).[Read Rest of Article]
I never really intended for it to spiral out of control like that. I had just started writing my book (a programming book on designing and writing web applications using outrageously nerdy technologies – truly the “Great American Novel”), and found myself frequently needing a little pick-me-up that only mind-altering substances could provide. You wouldn’t think that writing a book would be all that hard – you either know a lot about something or learn about it, and then sit down and write about it in your chosen language (which I am currently pretending still qualifies as “English”). The material to be covered should be planned out well in advance and one can thus sit down and write, write, Write![Read Rest of Article]