Autor | Zpráva | ||
---|---|---|---|
Loli Profil * |
#1 · Zasláno: 30. 8. 2007, 21:05:56
muj .htaccess
RewriteEngine on RewriteRule ^libs/.*$ - [PT] RewriteRule ^templates/.*$ - [PT] RewriteRule ^(.+)/$ $1 [R=301,L] RewriteCond %{REQUEST_URI} !index.php$ RewriteRule ^([^/]*) index.php?page=$1 [L] mam takovouhle stranku jako zalad http://localhost/neco/index.php a chci aby: http://localhost/neco/neco2 preformatovalo na http://localhost/neco/index.php?page=neco2 a to mi funguje , ale taky chci aby http://localhost/neco/neco2/ presmerovalo na http://localhost/neco/neco2 a to pak teda podle toho dalsiho pravidla preformatovalo na http://localhost/neco/index.php?page=neco2 a to mi zaboho anejde a hazi to na http://localhost/neco2 prosim pomoct uz s tim bojuju hodinu a kus a furt nic )): |
||
Lolita Profil |
#2 · Zasláno: 30. 8. 2007, 21:27:52 · Upravil/a: Lolita
No potreboval sem to kvuli "include" javascriptu, obrazku atd.
RewriteEngine on RewriteRule ^libs/.*$ - [PT] RewriteRule ^templates/.*$ - [PT] RewriteRule ^[^/]*/libs/(.*)$ libs/$1 [L] RewriteRule ^[^/]*/templates/(.*)$ templates/$1 [L] RewriteCond %{REQUEST_URI} !index.php$ RewriteRule ^([^/]*) index.php?page=$1 [L] A tohle je taky reseni :) Mimochodem to s tim redirectem neslo kvuli cache firefoxu ... ehm : |
||
Lolita Profil |
#3 · Zasláno: 30. 8. 2007, 21:47:32
tak problem byl hlavne stim, ze to mam na webu jinak nez na locale - podadresar
takze tady je finalni reseni kdyby nekdo potreboval RewriteEngine on RewriteRule ^libs/.*$ - [PT] RewriteRule ^templates/.*$ - [PT] RewriteCond %{REMOTE_HOST} ^localhost$ [OR] RewriteCond %{REMOTE_HOST} ^127.0.0.1$ [OR] RewriteRule ^(.+)/$ %{REQUEST_HOST}/neco/$1 [R=301,L] RewriteRule ^(.+)/$ %{REQUEST_HOST}/$1 [R=301,L] RewriteCond %{REQUEST_URI} !index.php$ RewriteRule ^([^/]*) index.php?page=$1 [L] |
||
Časová prodleva: 17 let
|
0