http – port 80
https – port 443
Tag Archives: Apache
Document Root
It is a location of files which are accessible by clients. By default, the Apache HTTP server in RedHat Enterprise Linux is configured to serve files from the /var/www/html/ directory.
Apache Stop
Use the following command to stop Apache service
service httpd stop
Apache Version
root@hp-Compaq-Presario-CQ40-Notebook-PC:~# apache2 -v
Server version: Apache/2.4.7 (Ubuntu)
Server built: Mar 10 2015 13:05:59
Apache Restart
Use the following command to restart Apache service
service httpd restart
Apache Start
Use the following command to start Apache service
service httpd start
Apache Types Of Virtual Hosts
Name-based
Name-based virtual host means that multiple names are running on each IP address.
IP-based.
IP-based virtual host means that a different IP address exists for each website served.
Most configurations are named-based because it only requires one IP address.
Apache Location Of Log Files
/var/log/httpd is the location of log files
register_globals
It can be considered as a flag that controls how you access form, server, and environment variables. By default this variable is set to Off, requiring you to use special arrays to access these variables. Its values are set in php.ini file .When the value is set to “on” , PHP will dynamically create global variable for many server variable as well as the query string parameters .
Its always better to set the value as “off”
Magic quotes
Magic quotes is a controversial feature of the PHP scripting language, which was introduced to help newcomers write functioning SQL commands without requiring manual escaping. It was later described and widely misinterpreted as help to prevent inexperienced developers from writing code which is vulnerable to SQL injection attacks. This feature is officially deprecated as of PHP 5.3.0, and removed in PHP 5.4 due to security concerns