Local Server questions

Discussion in 'Programming' started by Discovermypath, Jun 14, 2012.

to remove all ads.
  1. Discovermypath

    Discovermypath New Member

    Hello all!

    I'm a noob to web development and I had a few questions about installing a local server onto my computer. I want to practice with PHP.

    My first question is, should I install Apache, PHP and MySQL individually or should I use an all-in-one package that installs the three?

    An article I read said I should install Apache manually because I would learn more about the system and its configuration options.

    The second question is which all-in-one package should I go with (XAMPP, WampServer, Web Developer)?

    Last but not least, any recommendations for learning PHP and how to add comment box's or contact forms to web sites?

    Thanks for any advice in advance!
  2. MarkR

    MarkR New Member

    I've used both XAMPP and WAMP, and while they are both good a personally prefer WAMP. Its GUI is a bit more user friendly, and while I'm not afraid to get technical it saves a lot of time switching environments and altering configuration.

    Learning PHP? PHP.net is a good documentation resource and look at stack overflow for problems. As for tutorials, just type what you want to do in Google and add PHP on the end, there's usually millions of results.
  3. chrishirst

    chrishirst Well-Known Member Staff Member

    One thing to be aware of when testing in a WAMP (Windows, Apache, Mysql, PHP localhost server environment then moving to a LAMP (Linux, Apache, Mysql, PHP remote server environment is that there are differences that are likely to catch you out.

    Linux is a case sensitive OS, Windows is NOT. So on Windows "DBTableName" and "dbtablename" are treated as one and the same, on Linux they are NOT, and it is the same with folder and file names and the file extensions, image.jpg is not the same as image.JPG.

    Also there are some PHP constants and environment variables that PHP on Linux supports but are not available on Windows, ["DOCUMENT_ROOT"] being the most notable.

    Also .htaccess on Windows will/may not work because of the Windows file naming conventions where filenames cannot start with a dot/full stop/period (you can create the file in a command prompt though.

    Or you can edit httpd.conf and change the filename that apache looks for when on localhost.

    But then of course some rewrite rules may not work correctly, and mod_rewite is not enabled by default on a WAMP installation.
  4. Discovermypath

    Discovermypath New Member

    Thanks for the comment. I have found a couple useful books on PHP that have good reviews on amazon. Then I use php.net as a reference when I get confused by something in the books or I want a more in depth look at something.

    I installed WAMP at first and ended up uninstalling it and installing Apache, PHP and MySQL individually. I found a good tutorial on how to do this on lynda.com that really helped.

    Anyways thanks again, I appreciate the reply.

Share This Page