Post
#1
|
|
|
Grupa: Zarejestrowani Postów: 14 Pomógł: 0 Dołączył: 25.04.2007 Ostrzeżenie: (0%)
|
Zainstalowałem sobie serwer ręcznie Apache, php, mysql i takie tam . Wersja serwera to Apache 2.2.3 a php 5.2.0.
Stronki www działają, zarejestrowałem sobie domenę na no-ip i stworzyłem sobie virtualhost. Działa mi prawidłowo (z zewnątrz moga widzieć moje stronki). Wszystko OK poza jednym. Chciałem aby moje linki były przyjazne i zacząłem interesować sie mod-rewritem. Za chiny nie wiem co jest nie tak. Zrobiłem wg instrukcji czyli w httpd.conf odchaczyłem moduł Cytat LoadModule rewrite_module modules/mod_rewrite.so Pozniej mam takie coś Cytat DocumentRoot "D:/strony" # # Each directory to which Apache has access can be configured with respect # to which services and features are allowed and/or disabled in that # directory (and its subdirectories). # # First, we configure the "default" to be a very restrictive set of # features. <Directory /> Options FollowSymLinks AllowOverride All Order deny,allow Deny from all Satisfy all </Directory> # # Note that from this point forward you must specifically allow # particular features to be enabled - so if something's not working as # you might expect, make sure that you have specifically enabled it # below. # # # This should be changed to whatever you set DocumentRoot to. # <Directory "D:/strony"> # # Possible values for the Options directive are "None", "All", # or any combination of: # Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews # # Note that "MultiViews" must be named *explicitly* --- "Options All" # doesn't give it to you. # # The Options directive is both complicated and important. Please see # <a href=\"http://httpd.apache.org/docs/2.2/mod/core.html#options\" target=\"_blank\">http://httpd.apache.org/docs/2.2/mod/core.html#options</a> # for more information. # Options Indexes FollowSymLinks # # AllowOverride controls what directives may be placed in .htaccess files. # It can be "All", "None", or any combination of the keywords: # Options FileInfo AuthConfig Limit # AllowOverride All # # Controls who can get stuff from this server. # Order allow,deny Allow from all </Directory> I teraz wrzucam plik .htaccess do katalogu strony i wpisuję rózne regułki ale mi nic nie działa. A chciałem zrobić aby z adresu http://domena.no-ip.com/strona/index.php?id=omnie zamienić na link http://domena.no-ip.com/strona/omnie Jak to trzeba zrobić w pliku .htaccess aby to zadziałało na moim serwerze ? Czy coś pominałem przy konfiguracji Apacha odnośnie mod_rewrite ? Bo mam wrażenie jakby ten moduł nie działał. Ten post edytował Guli 7.05.2007, 23:25:55 |
|
|
|
Guli mod_rewrite i Apache 7.05.2007, 23:12:20
Blastereq W katalogu /strona/ umieszczasz plik htaccess z ta... 8.05.2007, 15:42:25
Guli EDIT
Juz działa. Musiałem podać sciezke do katalo... 8.05.2007, 18:30:30
Blastereq I będzie działać na obu, możesz zrobić przekierowa... 11.05.2007, 15:48:03 ![]() ![]() |
|
Aktualny czas: 25.12.2025 - 11:15 |