Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

 
Reply to this topicStart new topic
> [PHP]Przesłaniu parametru do innej podstrony
Zielonkawy18
post 8.12.2012, 08:15:48
Post #1





Grupa: Zarejestrowani
Postów: 152
Pomógł: 4
Dołączył: 4.10.2012

Ostrzeżenie: (10%)
X----


  1. header("Location: index.php?show=29")


Dodatkowo chciałbym przesłać date ( zmienną czyli mojego stringa)

index.php?show=29&zmienna w hrefie działa, Tutaj nie mogę się z tym uporać smile.gif


--------------------
C/C++/C#/JAVA/SQL ( funkcje, procedury, pakiety ).
Go to the top of the page
+Quote Post
s1518
post 8.12.2012, 09:21:40
Post #2





Grupa: Zarejestrowani
Postów: 22
Pomógł: 4
Dołączył: 3.12.2012

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


Jeśli metoda GET chcesz przeslac to w linku:
  1. header("Location: index.php?show=29&data=08.12.2012");

zczytywanie na stronie do ktorej prowadzi link:
  1. echo $_GET['data'];
Go to the top of the page
+Quote Post
Zielonkawy18
post 8.12.2012, 09:29:19
Post #3





Grupa: Zarejestrowani
Postów: 152
Pomógł: 4
Dołączył: 4.10.2012

Ostrzeżenie: (10%)
X----


Wiem, to wiem, ale w tym header-że

header("Location: index.php?show=9& i tutaj jakos moja zmienna $dataStart ale nie wiem jak to tu ulokować :-)


--------------------
C/C++/C#/JAVA/SQL ( funkcje, procedury, pakiety ).
Go to the top of the page
+Quote Post
s1518
post 8.12.2012, 09:48:14
Post #4





Grupa: Zarejestrowani
Postów: 22
Pomógł: 4
Dołączył: 3.12.2012

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


  1. header('Location: index.php?show=9&data='.$dataStart);
czyli łączenie zmiennych ze stringami
Go to the top of the page
+Quote Post
d3ut3r
post 8.12.2012, 09:49:05
Post #5





Grupa: Zarejestrowani
Postów: 709
Pomógł: 176
Dołączył: 24.10.2010

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


  1. header('Location: index.php?show=29&data='.urlencode($dataStart));


O to chodzi ?


--------------------
http://d3ut3r.wordpress.com/ | mysql_* jest przestarzałe UŻYWAJ PDO!
Go to the top of the page
+Quote Post

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

 



RSS Wersja Lo-Fi Aktualny czas: 28.04.2024 - 19:41