Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> Wycztanie index.php?id=news
Bladeq123
post
Post #1





Grupa: Zarejestrowani
Postów: 17
Pomógł: 0
Dołączył: 25.12.2008

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


Witam dalej mam ten problem, otóż:

Chce zeby jak wejde na stronę lala.pl, zeby mi czytało lala.pl/index.php?id=news, a nie lala.pl/index.php

Jak to zrobić kiedyś mi jeden user podał żeby wkleił to w head: <?php
header("Location: index.php?id=news");
?>

ale to nie działa.

Proszę o pomoc.
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi
kefirek
post
Post #2





Grupa: Zarejestrowani
Postów: 781
Pomógł: 256
Dołączył: 29.06.2008

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


O takie cos chodzi
  1. <?php
  2. if($_GET['id']=="galeria"){
  3. include("dane/galeria.html");
  4. } elseif($_GET['id']=="programy"){
  5. include("dane/programy.html");
  6. }elseif($_GET['id']=="ksiazki"){
  7. include("dane/ksiazki.html");
  8. } else {
  9. include("dane/galeria.html");
  10. }
  11. ?>


Ten post edytował kefirek 12.01.2009, 17:46:48
Go to the top of the page
+Quote Post

Posty w temacie


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: 3.10.2025 - 12:41