Autor | Zpráva | ||
---|---|---|---|
jarolim Profil |
#1 · Zasláno: 5. 3. 2007, 01:13:54
Nasel jsem na netu skriptik na kontaktni formular, potrebuji do neho zaclenit pole PRedmet a ADRESA - jake reseni navrhujete? diky
... <input type="text" name="jmeno" size="20" value="" /> <input type="text" name="email" size="20" value="@" /> <input type="text" name="predmet" size="20" value="" /> <input type="text" name="adresa" size="20" value="" /> <textarea name="zprava" cols="40" rows="10"></textarea> <input type="submit" value="Odešli vzkaz" /> </form> <? function to_7bit($txt){ $txt = Base64_Encode($txt); return($txt); } function send($sender, $msg) { global $receiver; global $subject; $headers = "MIME-Version: 1.0 "; $headers .= "Content-Transfer-Encoding: base64 "; $headers .= "Content-type: text/plain; charset=utf-8 "; $headers .= "X-Priority: 3 "; $headers .= "X-MSMail-Priority: Normal "; $headers .= "X-Mailer: php "; $headers .= "From: $sender "; return(mail($receiver, $subject, $msg, $headers)); } $action=0; if($_POST['zprava']){ $m=$_POST['email']; $s=$_POST['jmeno']." <".$m.">"; $m=to_7bit($_POST['zprava']); if(!send($s,$m)) $action=1; else $action=2; } switch($action){ case 1:print_error(); break; case 2:print_ok(); break; } |
||
t2001 Profil |
#2 · Zasláno: 5. 3. 2007, 01:48:00
adresa ceho?
a místo tohoto <input type="text" name="predmet" size="20" value="" /> napis toto <input type="text" name="subject" size="20" value="" /> a nezapomen si prejmenovat v tomto radku return(mail($receiver, $subject, $msg, $headers)); místo $subject, napiš $_POST['subject'] a bude ti fungovat predmet |
||
jarolim Profil |
#3 · Zasláno: 5. 3. 2007, 02:03:58
Ad adresa --> adresa odesilatel..., muze to byt i telefon...
|
||
jarolim Profil |
#4 · Zasláno: 5. 3. 2007, 02:17:24
Uz jsem problem vyresil :)
|
||
Časová prodleva: 17 let
|
Toto téma je uzamčeno. Odpověď nelze zaslat.
0