Welcome Guest, Not a member yet? Register   Sign In
htaccess on xampp?
#3

[eluser]Lost_all_hope[/eluser]
[quote author="Jings" date="1287508206"]What about setting the RewriteBase to /ci/ like so:

Code:
<VirtualHost *:80>
  ##ServerAdmin [email protected]
  DocumentRoot “C:\sites\ci”
  ServerName ci
  <Directory “C:\sites\ci “>
    Order Deny,Allow
    Allow from all
    RewriteEngine On
      RewriteBase /ci/
    
      RewriteCond %{REQUEST_FILENAME} !-f
      RewriteCond %{REQUEST_FILENAME} !-d
  
      RewriteRule ^(.*)$ index.php/$1 [L]
  </Directory>
</VirtualHost>
[/quote]

Hi this part works and dispays in the browser within VHOST file with or without RewriteBase /ci/

That's not my issue the issue is i want to transerfer the above values from C:\xampp\apache\conf\extra\httpd-vhosts.conf of:

RewriteEngine On
RewriteBase /ci/

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d

RewriteRule ^(.*)$ index.php/$1 [L]

To a C\sites\ci\.htaccess file at the root of the project
ci
ci/system
ci/index.php
ci/.htaccess

So when I put it on a live web site I only have access to .httacess file not the VHOST file, the problems is when I add the above values to the .htaccess file then remove the above code from the VHOST file, then I restart apache navigate to the url via a browser it says:

Object not found!
The requested URL was not found on this server. If you entered the URL manually please check your spelling and try again.

If you think this is a server error, please contact the webmaster.

Error 404
ci
19/10/2010 13:54:08
Apache/2.2.14 (Win32) DAV/2 mod_ssl/2.2.14 OpenSSL/0.9.8l mod_autoindex_color PHP/5.3.1 mod_apreq2-20090110/2.7.1 mod_perl/2.0.4 Perl/v5.10.1

basically my object is to move the code from httpd-vhosts.conf to the .htaccess file so I then can have URL's of http://ci/blog/ and not http://ci/index.php/blog/

I've tried various methods to get the .htaccess working on this project including a couple of suggestion of this forum with or without RewriteBase on without success.

Again heres the setup:

C:XAMPP
C:XAMPP|APACHE
httpd-vhosts.conf setup in Apache of the following:
## CodeIgnightor
<VirtualHost *:80>
##ServerAdmin [email protected]
DocumentRoot "C:\sites\ci"
ServerName ci
<Directory "C:\sites\ci ">
Order Deny,Allow
Allow from all
RewriteEngine On
RewriteBase /

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d

RewriteRule ^(.*)$ index.php/$1 [L]
</Directory>
</VirtualHost>
LoadModule rewrite_module modules/mod_rewrite.so uncommented in httpd.conf

HOST file 127.0.0.1 ci

C:\sites\ci (root of site)
Site layout:
ci
ci|system
ci|index.php
ci|.htaccess (this is where I want my rewrite stuff to work from)

Any help appreciated

Cheers

Mal


Messages In This Thread
htaccess on xampp? - by El Forum - 10-19-2010, 05:32 AM
htaccess on xampp? - by El Forum - 10-19-2010, 06:10 AM
htaccess on xampp? - by El Forum - 10-19-2010, 07:22 AM
htaccess on xampp? - by El Forum - 10-19-2010, 07:50 AM
htaccess on xampp? - by El Forum - 10-19-2010, 08:00 AM
htaccess on xampp? - by El Forum - 06-15-2011, 07:23 AM



Theme © iAndrew 2016 - Forum software by © MyBB