Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

 
Reply to this topicStart new topic
> plik index.php
pys1986
post
Post #1





Grupa: Zarejestrowani
Postów: 233
Pomógł: 0
Dołączył: 18.01.2005

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


mam adres http://localhost/index.php/strona1/
i chce zeby nie wyswietlal sie w adresie "index.php"
Go to the top of the page
+Quote Post
kriqs
post
Post #2





Grupa: Zarejestrowani
Postów: 148
Pomógł: 0
Dołączył: 31.05.2006

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


witam

poczytaj o tym : mod_rewrite
Go to the top of the page
+Quote Post
pys1986
post
Post #3





Grupa: Zarejestrowani
Postów: 233
Pomógł: 0
Dołączył: 18.01.2005

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


szukalem ale nie znalazlem (IMG:http://forum.php.pl/style_emoticons/default/sad.gif)
Go to the top of the page
+Quote Post
xmarcin
post
Post #4





Grupa: Zarejestrowani
Postów: 8
Pomógł: 0
Dołączył: 19.07.2006

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


mam nadzieje ze to pomoze (IMG:http://forum.php.pl/style_emoticons/default/smile.gif)
http://phppl.ezpublish.no/wortal/artykuly/.../przyjazne_urle
(przeczytaj caly art - warto)
Go to the top of the page
+Quote Post
pys1986
post
Post #5





Grupa: Zarejestrowani
Postów: 233
Pomógł: 0
Dołączył: 18.01.2005

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


juz to czytalem i nie pomoglo (IMG:http://forum.php.pl/style_emoticons/default/sad.gif)
Go to the top of the page
+Quote Post
Athlan
post
Post #6





Grupa: Developerzy
Postów: 823
Pomógł: 12
Dołączył: 18.12.2005

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


Super opisane:
http://home.pl/pomoc/kursy/rewrite

Zaawansowane przykłady:
http://haxite.org/index.php3?site=artykul&...view&id=589
Go to the top of the page
+Quote Post
pys1986
post
Post #7





Grupa: Zarejestrowani
Postów: 233
Pomógł: 0
Dołączył: 18.01.2005

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


i tak nie kumam (IMG:http://forum.php.pl/style_emoticons/default/sad.gif) chodzi mi tylko o to zeby w adresie ukryc "index.php"
Go to the top of the page
+Quote Post
kriqs
post
Post #8





Grupa: Zarejestrowani
Postów: 148
Pomógł: 0
Dołączył: 31.05.2006

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


nie rozumiem jak czytales (IMG:http://forum.php.pl/style_emoticons/default/questionmark.gif) przeciez to jest latwe jak budowa cepa (IMG:http://forum.php.pl/style_emoticons/default/smile.gif)
  1. <?php
  2. RewriteEngine On
  3. RewriteCond %{REQUEST_FILENAME} !-f
  4. RewriteCond %{REQUEST_FILENAME} !-d
  5. RewriteRule (.*) index.php [L]
  6.  
  7. $_SERVER["REQUEST_URI"]
  8. ?>


teraz juz wiesz (IMG:http://forum.php.pl/style_emoticons/default/questionmark.gif) co nalezy zrobic (IMG:http://forum.php.pl/style_emoticons/default/questionmark.gif)
Go to the top of the page
+Quote Post
pys1986
post
Post #9





Grupa: Zarejestrowani
Postów: 233
Pomógł: 0
Dołączył: 18.01.2005

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


no dobra a teraz jak mam taki adres http://adres.pl/as/df/ i chce z tego zrobic http://adres.pl/index.php/as/df/ poprostu zawsze po adresie dodac index.php przed zmiennymi (IMG:http://forum.php.pl/style_emoticons/default/sad.gif)
Go to the top of the page
+Quote Post
wipo
post
Post #10





Grupa: Zarejestrowani
Postów: 856
Pomógł: 19
Dołączył: 30.08.2005
Skąd: 100lica

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


A tak się zapytam co zamierzasz osiągnąć? bo jakoś nie czaje
Go to the top of the page
+Quote Post
pys1986
post
Post #11





Grupa: Zarejestrowani
Postów: 233
Pomógł: 0
Dołączył: 18.01.2005

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


mam strona ktora na serwerze uzywa linkow http://adres.pl/as/df/ a na localhoscie musze recznie dodawac index.php bo inaczej nie chodzi (IMG:http://forum.php.pl/style_emoticons/default/sad.gif)
Go to the top of the page
+Quote Post
kriqs
post
Post #12





Grupa: Zarejestrowani
Postów: 148
Pomógł: 0
Dołączył: 31.05.2006

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


no to przekopiuj sobie plik .htaccess i daj do glownego katalogu (IMG:http://forum.php.pl/style_emoticons/default/smile.gif)
Go to the top of the page
+Quote Post
pys1986
post
Post #13





Grupa: Zarejestrowani
Postów: 233
Pomógł: 0
Dołączył: 18.01.2005

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


problem w tym ze na serwerze niema tego pliku (IMG:http://forum.php.pl/style_emoticons/default/sad.gif)
Go to the top of the page
+Quote Post
strife
post
Post #14





Grupa: Przyjaciele php.pl
Postów: 2 605
Pomógł: 96
Dołączył: 22.10.2004
Skąd: UK

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


Cytat(pys1986 @ 5.03.2007, 13:05:48 ) *
problem w tym ze na serwerze niema tego pliku (IMG:http://forum.php.pl/style_emoticons/default/sad.gif)

Żarty sobie z nas robisz czy co ? Jak takiego pliku nie ma to go stwórz, to też mamy za Ciebie zrobić ?
Go to the top of the page
+Quote Post
pys1986
post
Post #15





Grupa: Zarejestrowani
Postów: 233
Pomógł: 0
Dołączył: 18.01.2005

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


no to tak: znalazlem ten plik ale gdy wrzuce go na localhosta to wyskakuje mi błąd:

"Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, admin@localhost and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.

Apache/1.3.33 Server at localhost Port 80"

a plik ma taką postac:

"RewriteEngine on
RewriteRule ^([^.]*)$ /index.php?url=$1 [NC,L]"

uzywam EasyPHP
Go to the top of the page
+Quote Post
Athlan
post
Post #16





Grupa: Developerzy
Postów: 823
Pomógł: 12
Dołączył: 18.12.2005

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


@pys1986, chyba żarty... daj sobie:

Kod
RewriteEngine On
RewriteBase /jakis/moj/folder/w/ktorym/jest/strona/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule (.*) index.php


Jeżeli strona jest w katalogu główym, wówczas parametr w drugiej linii ustaw na /

Pozdrawiam, Athlan (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: 23.08.2025 - 02:16