Guide to installing with WAMP5


(Marcus Nyeholt) #1

I've spent some time going through and getting the installation process for WAMP. It was quite a simple process, provided a few manual tasks were carried out. Anyway, here's what I had to do to install matrix using WAMP5 and the latest build of the installer (updated to include a few new checks, and to set a time limit when doing the database population process) and latest version of Matrix.


1 Setting up WAMP5


  • Go to http://www.wampserver.com and get the latest version of WAMP5.

    Additionally, you’ll need to get the

    http://www.wampserver.com

    (wamp5 is, as you might have guessed, for PHP5 by default).


  • Install WAMP5 to its default (C:\wamp) location. Then install the PHP4

    addon over the top.


  • Make sure the default installation is working by going to http://www.wampserver.com.

    If it is, go to the WAMP5 manager (a little speedo icon on your system tray)

    and choose the “Switch to PHP4” option; it’ll restart apache for you after

    finishing.



    2 Setting up PEAR



    Start a command prompt (Start->Run-> cmd) and change to your c:\wamp\php4

    directory.
  • run the pear installer go-pear . If you stuff up, you can run go-pear again

    over the top to reinitialise your pear setup.
  • When I installed, I had to select the directory for my PHP executable. If

    you've previously installed pear or another instance of PHP, you want to

    change this when given the option
    1. Installation prefix : C:\wamp\php4
    2. Binaries directory : $prefix
    3. PHP code directory ($php_dir) : $prefix\pear
    4. Documentation base directory : $php_dir\docs
    5. Data base directory : $php_dir\data
    6. Tests base directory : $php_dir\tests
    7. php.exe path :



      Hit 7 when prompted, and use the selector to choose the C:\wamp\php4\cli

      directory (NOT the php.exe file, you'll get an error if you do).


  • After this has completed, run the PEAR_ENV.reg file that was created in your

    C:\wamp\php4 directory to set up some environment

    variables. You'll need to close and restart your command prompt for these to

    take effect.


  • You'll need to upgrade and install some new pear packages

    pear upgrade DB Net_Socket

    pear install Net_URL HTTP_Request Cache HTTP_Client Mail_Mime XML_HTMLSax



    3 Update your php.ini file

    In the WAMP5 manager, go to the "Config Files" -> php.ini option. This will

    open the php.ini file in notepad to be edited. You'll need to change the

    following:
    • include_path = ".;C:\wamp\php4\PEAR"
    • remove the comment (:wink: from the line

      ;extension=php_gd2.dll

      to enable GD



      You’ll then need to restart apache using the WAMP5 manager.



      4 Create a database

      Go to http://www.wampserver.com and follow the link to phpMyAdmin in the Tools section.

      Create a new database called matrix



      5 Installing Matrix
  • Extract the matrix archive to C:\, so you now have a directory

    mysource_matrix_3-2-0

    -Extract the matrix_installer archive to C:\wamp\www so you now have a directory

    c:\wamp\www\mysource_matrix_installer
  • Go to http://www.wampserver.com, follow link to installer at bottom of page in the

    Your Projects section.



    Follow the prompts and fill in the appropriate details. When prompted for a system root url, use localhost/matrix.

    When prompted for

    database details, use “localhost” for the hostname, “root” as the username,

    leave the password blank, and use the database name you created above (matrix)

    When you get to the final screen, DON’T click the login link just yet…

    do the step below first.



    6 Aliasing to Matrix

    Edit the apache configuration (httpd.conf) from the WAMP manager

    Add aliases at the bottom of the file as follows

[quote]  Alias “/matrix/__data”        “C:/mysource_matrix_3-2-0/data/public”

  Alias “/matrix/__lib”      “C:/mysource_matrix_3-2-0/core/lib”

  Alias “/matrix/__fudge”    “C:/mysource_matrix_3-2-0/fudge”

  Alias “/matrix”            “C:/mysource_matrix_3-2-0/core/web/index.php”[/quote]

Restart Apache



Now you should be fine to login to the backend through http://www.wampserver.com


(Avi Miller) #2

Note that if you want Matrix to run in the root of your website (i.e. at http://localhost) the aliases should be:

    Alias "/__data"        "C:/mysource_matrix_3-2-0/data/public"
      Alias "/__lib"        "C:/mysource_matrix_3-2-0/core/lib"
      Alias "/__fudge"      "C:/mysource_matrix_3-2-0/fudge"
      Alias "/"              "C:/mysource_matrix_3-2-0/core/web/index.php/"


When Matrix is running the root, it needs the trailing / at the end of index.php to work properly.

(Harris Zoe) #3

THANK YOU THANK YOU THANK YOU!


Finally I've got it working!



Merry Christmas, I'm going home. :smiley:


(Avi Miller) #4

Would you mind letting us know what fixed it? I'm really curious! :slight_smile:


(Harris Zoe) #5

I have no idea to be honest. I had tried WAMP before but I don't think I had set Pear up properly. The problems I was having using my own installation were to do with my httpd.conf, but I never could work out what the difference was.


The step-by-step instructions were great for me, since this is my first time working with a web server. However, in the time I spent mucking around with my own installation, I learned a lot that I wouldn't have known if I'd had the instructions right from the start. So it's all good. :slight_smile: