1. 程式人生 > >ci的url去除index.php

ci的url去除index.php

iter httpd conf view cond rec color onf sta

wamp: httpd-vhost.conf

<VirtualHost *:80>
  ServerName localhost
  ServerAlias localhost
  #DocumentRoot "${INSTALL_DIR}/www"
  #<Directory "${INSTALL_DIR}/www/">
  DocumentRoot "C:\JabinDoc\php_www"
  <Directory "C:\JabinDoc\php_www">
    Options +Indexes +Includes +FollowSymLinks +MultiViews
    AllowOverride All
    Require local
  
</Directory> </VirtualHost> <VirtualHost *:80> ServerName php.test.com ServerAlias php.test.com DocumentRoot "C:\JabinDoc\php_www\ci" <Directory "C:\JabinDoc\php_www\ci"> Options +Indexes +Includes +FollowSymLinks +MultiViews AllowOverride All Require local
</Directory> </VirtualHost>

ci: 根目錄下.htaccess

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1 [L]

ci的url去除index.php