I've recently read Wallace Wang's “Beginning Programming for Dummies, 7 books in 1” and found it to be very enlightening, as it highlighted various differences between the three main operating systems of Linux, Mac and Microsoft; and thought PHP would be as good a starting point to start with and chose “Head First, PHP & MySQL” in the O'Reily library.

Problem, it only describes the set up and installation of LAMP server for Microsoft and Mac and I'm unable to do the exercises, in chapter one. As I failed to set up LAMP, on several occasions using the links and other prescribed methods in this forum.

I get to “Look it Works” on the browser, when you restart Apache, then enter the code lines to obtain the PHP display page, after reading a long message, which tells me certain facets of the php install were deprecated, do you want to continue, “y or n” the terminal goes blank upon typing “y” and followed by a series of new lines starting with a comma, ending with a red line message “E353: nothing in register”.

Entering “php -version” or “mysql -version” commands in the terminal, it informs me I do not have either installed, but gives the option to install either with the following “sudo apt-get install php5-cli” or “sudo apt-get install mysql-client-core-5.5 ” commands. Though Apache comes with multiple choice? Sort of grasp why there is nought in the register.

  1. Security issues, I was informed to enter a new password for MySQL, then re-enter, went with my computer root command password. By the third or fourth attempt I used a new password for MySQL. Boy that cooked the system. Delete and re-installed 12.04.

  2. The system only recognises the, which it didn't like either, and I couldn't find an option to enter my IP localhost.com, shown on the example graphic or the preferred modified address used in other examples.

  3. Is “Head First, PHP & MySQL” still the best way forward for Ubuntu 12.04, if not can you recommend..!

  4. Would it be prudent to download PHP, MySQL and Apache using the sudo apt-get install command first, then attempt the set up using “tasksel”, which is now installed.

Feeling like a NUMPTY and totally lost.

  • For point two I would suggest you look into the following after you get PHP & mySQL working: the vHost files to setup an (apache) host and the etc/hosts file to loop and address/name back to your machine. – chesedo Jan 22 '14 at 4:42

Use the commands it suggests (sudo apt-get install php5 php5-cli mysql-client mysql-server) to install PHP and MySQL, and reboot the Apache server using sudo service apache2 restart. It should load both programs and function properly.

  • You also need to add libapache2-mod-php5 to install the php module for apache – Dan Jan 22 '14 at 11:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.