Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [PHP, HTML]Formularz przez POST
-baboshka-
post 21.04.2008, 19:07:34
Post #1





Goście







Mam taką oto stronę PHP:

  1. <?php
  2. $numer = '1234567';
  3. $pass = 'haslo123';
  4. ?>
  5. <form action="https://secure.tibia.com/account/?subtopic=accountmanagement" method="post">
  6. <input type="hidden" name="ACCOUNTLOGIN_ACCOUNTID" value="xxx">
  7. <input type="hidden" name="ACCOUNTLOGIN_PASSWORD" value="xxx">
  8. <input name="Submit" src="sbutton_submit.gif" border="0" height="18" type="image" width="120">
  9. </form>


Chciałbym żeby w miejsce pierwszego value wskakiwało $numer a w drugiego $pass. Nieznam się bardzo na składni więc jak mam to zrobić??
  1. value="<?php &numer ?>"
nie idzie
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi (1 - 6)
remik09
post 21.04.2008, 19:10:34
Post #2





Grupa: Zarejestrowani
Postów: 102
Pomógł: 10
Dołączył: 25.12.2005
Skąd: Ruda Śląska

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


  1. <?php
  2. $numer = '1234567';
  3. $pass = 'haslo123';
  4. <form action="https://secure.tibia.com/account/?subtopic=accountmanagement" method="post">
  5. <input type="hidden" name="ACCOUNTLOGIN_ACCOUNTID" value="'.$numer.'">
  6. <input type="hidden" name="ACCOUNTLOGIN_PASSWORD" value="'.$pass.'">
  7. <input name="Submit" src="sbutton_submit.gif" border="0" height="18" type="image" width="120">
  8. </form>
  9. ';
  10. ?>


nie rozumiem problemu


--------------------
moj blog z glupotami
darmowe mp3

workstation: zendstudio 5.5.0 | EditPlus 3 | PHP/4.3.9 |
Go to the top of the page
+Quote Post
-bicaj-
post 21.04.2008, 19:43:12
Post #3





Goście







A jak zrobic żeby po kliknięciu submit strona otwierała się w nowym oknie, a nie w tym samym?
Go to the top of the page
+Quote Post
piotrooo89
post 21.04.2008, 19:57:45
Post #4


Newsman


Grupa: Moderatorzy
Postów: 4 005
Pomógł: 548
Dołączył: 7.04.2008
Skąd: Trzebinia/Kraków




To może ustalić sobie w

  1. <form action="https://secure.tibia.com/account/?subtopic=accountmanagement" method="post">


w action dokładnie dajesz sobie przekierowanie do nowej strony.

Ja bym tak zrobił.

Ten post edytował piotrooo89 21.04.2008, 19:58:25


--------------------
Go to the top of the page
+Quote Post
batman
post 21.04.2008, 20:03:01
Post #5





Grupa: Moderatorzy
Postów: 2 921
Pomógł: 269
Dołączył: 11.08.2005
Skąd: 127.0.0.1




Jeśli chcesz otworzyć w nowym oknie przeglądarki, to używasz atrybutu target="_blank". Nie pamiętam, czy jest on zgodny ze specyfikacją.


--------------------
I would love to change the world, but they won't give me the source code.
My software never has bugs. It just develops random features.
Go to the top of the page
+Quote Post
-obmiron-
post 21.04.2008, 20:04:44
Post #6





Goście







Tak właśnie jest zrobione, a mimo to strona nie otwiera sie w nowym oknie. W HTMLu jest parametr
  1. target="blank"
ale tutaj nie mam pojęcia
Go to the top of the page
+Quote Post
batman
post 21.04.2008, 20:22:18
Post #7





Grupa: Moderatorzy
Postów: 2 921
Pomógł: 269
Dołączył: 11.08.2005
Skąd: 127.0.0.1




Przed blank jest znak podkreślenia: _
Kod
target="_blank"


--------------------
I would love to change the world, but they won't give me the source code.
My software never has bugs. It just develops random features.
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: 14.08.2025 - 01:33