Easily 'Linux beginner', 'Linux advanced' and 'Linux professional' supports and does not support the following features:
| ph4 | Yes |
| ph5 | Yes |
| Server Side Includes (SSI) | No |
| htaccess Options | No |
Your files should be amed as follows:
| Index webpages | index.something |
| Normal webpages | file.html |
| PHP4 Webpages | file.php4 |
| PHP5 Webpages | file.php or file.php |
When you load a webpage ending in .php, .php4 or .php5, the web server runs your own executable php interpreter, which lives in the website/cgi-bin directory.
There are two interpreters, one for php4 and one for php5. Each one loads its own configuration file (php4.ini or php.ini), also in the same directory.
Error reporting is, by default, passed to stdout, which means that any php errors are presented to the web browser. If you don't want this to happen, you can turn it off by editing the appropriate php.ini file:
; Log errors into a log file (server-specific log, stderr, or error_log (below))
; As stated above, you're strongly advised to use error logging in place of
; error displaying on production web sites.
log_errors = On
Generating a Mirror Configuration
Install the following packages:
urpmi apache
urpmi apache-mod_userdir
urpmi apache-mod_php
Edit /etc/httpd/httpd.conf and uncomment the following line (removing any comments from the end of it):
LoadModule userdir_module modules/mod_userdir.soAdd the following lines in the httpd.conf file, after all of the other entries:
{IfModule mod_userdir.c}Manually start the webserver (this time) by typing /etc/init.d/httpd start
UserDir public_html
{/IfModule}
{Directory /home/*/public_html}
AllowOverride FileInfo AuthConfig Limit // All ** Need to check this - I used All
Options MultiViews SymLinksIfOwnerMatch IncludesNoExec
{Limit GET POST OPTIONS}
Order allow,deny
Allow from all
{/Limit}
{LimitExcept GET POST OPTIONS}
Order deny,allow
Deny from all
{/LimitExcept}
{/Directory}
Either edit files in ~/public_html, or create a soft link in there to point to the appropriate files / directories.
Finally, access the local website via http://localhost/~username/directory
Easily .htaccess
Only some of the htaccess commands are valid with easily, for example, the Options command does not work. If the htaccess commands file is not parsed correctly, a server error is returned.
A example htaccess file is shown below:
<Files .htaccess>
order allow,deny
deny from all
</Files>
Order allow,deny
Allow from all
AddType text/html .shtml
AddHandler server-parsed .shtml
DirectoryIndex index.shtml index.php index.html