Tuesday, May 21, 2013

Catatan Web Server

Untuk menambahkan Virtual Host

Edit \apache\conf\httpd.conf
Listen 8080
Listen 8081

Edit \apache\conf\extra\httpd-vhosts.conf
NameVirtualHost *:8080
NameVirtualHost *:8081


 ServerName v1
 DocumentRoot "C:/xampp/htdocs/"
 <directory "C:/xampp/htdocs/">
  DirectoryIndex index.php
  AllowOverride All
  Order allow,deny
  Allow from all
 </directory>



 ServerName zendApp
 DocumentRoot "C:/xampp/htdocs/ZendSkeletonApplication/public/"
 SetEnv APPLICATION_ENV "development" 
 <directory "C:/xampp/htdocs/ZendSkeletonApplication/public/">
  DirectoryIndex index.php
  AllowOverride All
  Order allow,deny
  Allow from all
 </directory>


yang perlu di ingat
  1. buang tanda komentar "#" (tanda pagar) untuk Include conf/extra/httpd-vhosts.conf pada httpd.conf
  2. ubah tanda "garis miring" "\" (back slash) menjadi "/"
  3. port web server harus sama antara yang ada di httpd.conf dengan httpd-vhosts.conf

No comments: