New Users: Quick PHP Info: Difference between revisions

From The Uniform Server Wiki
Jump to navigation Jump to search
(New page: <span id="top"></span> <div style="padding:0;margin:0; border-bottom:3px inset #000000"> {| | MPG UniCenter || New Users: [[New Users: Home 3.5-Apollo | Hom...)
(No difference)

Revision as of 21:30, 26 May 2008

MPG UniCenter

New Users: Home | Quick PHP CGI | Quick PHP CLI | Quick PHP Info

Quick PHP General information 3.5-Apollo

This page contains snippets of information linked from PHP new user pages. Hence they are in no particular order.

How to enable PHP

PHP is enabled by default hence nothing to do

Where to place files

You can place PHP files anywhere within the servers's root folder. Location of this root folder: *\Uniform Server\udrive\www


Note 1: *\ Is the path where you installed Uniform Server

For example if you extracted to folder c:\myserver then the root folder is located in:

c:\myserver\Uniform Server\udrive\www

Note 2: Folder www is referred to as the site or server root folder.

PHP file extensions

The default installation of Uniform server 3.5-Apollo allows PHP code in files with extentions .phtml , .php3 and .php

You are not restricted to using just these extentions you can use for example .htm however you must add the extension to the Apache configuration file as follows:

  1. Open the config file: *\Uniform Server\udrive\usr\local\apache2\conf\httpd.conf
  2. Navigate to line 294 and add your extention to the list:
  • AddType application/x-httpd-php .phtml .php3 .php .htm
  1. Save the file and restart Uniform Server


Note: Disadvantage of doing this, all files with the above extentions are always checked for PHP code. Hence even if there is no code in the files they are still passed through the parser hence you get a small processing hit. (No big deal its your server you can do what you like)

Top


Ric