Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

 
Reply to this topicStart new topic
> [htaccess] Usunięcie .php
gg1985
post
Post #1





Grupa: Zarejestrowani
Postów: 174
Pomógł: 3
Dołączył: 23.02.2008

Ostrzeżenie: (0%)
-----


Witam

Co wpisać w htaccess, aby zmienić adres:

www.strona.pl/podstrona.php

na

www.strona.pl/podstrona

Z góry dzięki

Pozdro
Go to the top of the page
+Quote Post
wookieb
post
Post #2





Grupa: Moderatorzy
Postów: 8 989
Pomógł: 1550
Dołączył: 8.08.2008
Skąd: Słupsk/Gdańsk




MOD_REWRITE!! Było miliony razy
Go to the top of the page
+Quote Post
gg1985
post
Post #3





Grupa: Zarejestrowani
Postów: 174
Pomógł: 3
Dołączył: 23.02.2008

Ostrzeżenie: (0%)
-----


Dodałem do htacces coś takiego, ale nie działa

RewriteRule ^adres$ adres.php [L]
Go to the top of the page
+Quote Post
wookieb
post
Post #4





Grupa: Moderatorzy
Postów: 8 989
Pomógł: 1550
Dołączył: 8.08.2008
Skąd: Słupsk/Gdańsk




A masz?
Kod
RewriteEngine On
Go to the top of the page
+Quote Post
gg1985
post
Post #5





Grupa: Zarejestrowani
Postów: 174
Pomógł: 3
Dołączył: 23.02.2008

Ostrzeżenie: (0%)
-----


Mój cały htaccess:

Kod
RewriteEngine On
Options +FollowSymlinks
RewriteBase /
RewriteCond %{HTTP_HOST} ^www.adres.pl$
RewriteRule ^(.*)$ http://adres.pl/$1 [R=301,L]
RewriteRule ^podstrona.html$ podstrona.php [L]
Go to the top of the page
+Quote Post
Villentre
post
Post #6





Grupa: Zarejestrowani
Postów: 21
Pomógł: 10
Dołączył: 14.10.2008
Skąd: 127.0.0.1

Ostrzeżenie: (0%)
-----


To może tak:

Kod
<Files podstrona>
ForceType application/x-httpd-php5
</Files>


Ten post edytował Villentre 24.05.2009, 23:58:04
Go to the top of the page
+Quote Post
gg1985
post
Post #7





Grupa: Zarejestrowani
Postów: 174
Pomógł: 3
Dołączył: 23.02.2008

Ostrzeżenie: (0%)
-----


Też nie pomaga (IMG:http://forum.php.pl/style_emoticons/default/sad.gif)
Go to the top of the page
+Quote Post
wookieb
post
Post #8





Grupa: Moderatorzy
Postów: 8 989
Pomógł: 1550
Dołączył: 8.08.2008
Skąd: Słupsk/Gdańsk




Wpisz jakies bzdety do htaccess i jezeli nie wywali bledu jak wchodzisz na strone tzn ze nie masz lwaczonej interpretacji htaccess.
A o tym jak wlaczyc znajdzeisz na forum.
Go to the top of the page
+Quote Post
gg1985
post
Post #9





Grupa: Zarejestrowani
Postów: 174
Pomógł: 3
Dołączył: 23.02.2008

Ostrzeżenie: (0%)
-----


Interpretuje jednak, bo jak wpisałem głupoty to po wejściu mam

Internal Server Error
Go to the top of the page
+Quote Post
erix
post
Post #10





Grupa: Moderatorzy
Postów: 15 467
Pomógł: 1451
Dołączył: 25.04.2005
Skąd: Szczebrzeszyn/Rzeszów




A co w dokumentacji konta?
Go to the top of the page
+Quote Post
mls
post
Post #11





Grupa: Zarejestrowani
Postów: 677
Pomógł: 89
Dołączył: 31.08.2003
Skąd: Warszawa

Ostrzeżenie: (0%)
-----


W .htaccess dopisać:
Kod
Options MultiViews
Go to the top of the page
+Quote Post
konradg
post
Post #12





Grupa: Zarejestrowani
Postów: 15
Pomógł: 0
Dołączył: 10.06.2009

Ostrzeżenie: (0%)
-----


ModRewrite = http://www.drzewo-wiedzy.pl/?page=artykul&id=18 Choć faktycznie temat modRewrite'a jest maglowany odkąd go napisali (IMG:http://forum.php.pl/style_emoticons/default/smile.gif)
Go to the top of the page
+Quote Post

Reply to this topicStart new topic
2 Użytkowników czyta ten temat (2 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 25.08.2025 - 14:39