1

I want

  1. http://kemtime2_neu.pr.domain.de/css/style.css to open as http://kemtime2_neu.pr.domain.de/public/css/style.css and
  2. http://kemtime2_neu.pr.domain.de/login to open as http://kemtime2_neu.pr.domain.de/public/index.php/login

I have

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

This works for 2.

How do I make it work for 1.? Note that I can not change the document root (sorry!).

PiTheNumber
  • 22,828
  • 17
  • 107
  • 180

2 Answers2

2

Found it:

# Redirect to static content
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond /var/www/de/domain/pr/kemtime2_neu/public%{REQUEST_URI} -f
RewriteRule ^(.+)$ /public/$1 [L]

# otherwise redirect to script
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /public/index.php/$1 [L]
PiTheNumber
  • 22,828
  • 17
  • 107
  • 180
0

Change your DocumentRoot to point to the public directory?

djc
  • 11,603
  • 5
  • 41
  • 54