rest - Apache rewrite rules redux -


I have found a rest of the framework when working in any directory should be plopped (TM), and it seems to work fine When I have projects in the subdirectory, but if it is not in the root therefore, some examples directories are given;

I am running when the project runs in the root directory (it is difficult to understand, I think, but the second level is not working properly again). Here's my attempt on a normal .htaccess file:

  Riverlighting on rest rule ^ static / - [L] Rewrite condom% {REQUEST_URI} ^ $ RewriteRule. * ./ [R, L] Revivalable ^ Index .php - [L] RewriteRule (. *) Index.php? Q = $ 1 [QSA, PT]  

(And yes, all projects have a subdirectory. / Static which is neglected by rewriting) What I am trying to achieve is There is a set of rules for rewriting that works for most cases (which again, plonking the project in a directory of the webserver). I do not want to re-write that a long shot, and any good advice and gouche will be appreciated (and yes, I have gone through many introductory articles.) I want some serious interest.

  • More information on the fun; My webserver got a location under one place (/ usr / share / apache2 / default-site /), but there is a set of rules that says that the projects / projects have been drawn from elsewhere, which are called docot (/ home / user) / Projects /). When I go there, I get a list of projects, and if one of those subdirectories is called with the proposed rewriting rules, I get it;

    The requested URL / Home / User / Projects /stmapp/index.php could not be found on this server.

Try these rules:

 < Code> rewrite rule ^ static / - [l] rewrite% {REQUEST_FILENAME}! -f Rewrite rules Index.php? Q = $ 0 [L, QSA]   R  flag to apply external redirects, or to activate requests to see that How to redirect / redirect internally. 


Comments

Popular posts from this blog

python - Overriding the save method in Django ModelForm -

html - CSS autoheight, but fit content to height of div -

qt - How to prevent QAudioInput from automatically boosting the master volume to 100%? -