Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> PHP - formularz do wysyłania maila ze strony
tomas.rosicky
post
Post #1





Grupa: Zarejestrowani
Postów: 1
Pomógł: 0
Dołączył: 20.01.2008

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


Witam

potrzebuje na szybko pomocy. w którym miejscu poniżej należy
zdefiniować adres email (np: janek@mail.pl), na który będzie
wysyłany formualrz? Teraz wpisany jest on w dwoch miejscach, ale
niestety maile nie dochodzą. Dodam że po klinięciu na send - pojawia
się komunikat "form was successfully sent!" - maile jednak nie doc
ierają.
prosze o rade.dzieki!



<?php
Error_Reporting(E_ALL & ~E_NOTICE);

while ($request = current($_REQUEST)) {
if (key($_REQUEST)!="janek@mail.pl") {
$pre_array=split ("&777&", $request);

$post_vars[key($_REQUEST)][0]=preg_replace ("/<[^>]
*>/", "", $pre_array[0]);
$post_vars[key($_REQUEST)][1]=preg_replace ("/<[^>]
*>/", "", $pre_array[1]);
}
next($_REQUEST);
}



reset($post_vars);


$subject="From ".$post_vars['your_name'][0] ;
$headers= "From: ".$post_vars['your_email'][0] ."\n";
$headers.='Content-type: text/html; charset=iso-8859-1';
$message='';
while ($mess = current($post_vars)) {
if ((key($post_vars)!="i") && (key($post_vars)!
="your_email") && (key($post_vars)!="your_name")) {

$message.="<strong>".$mess
[1]."</strong> ".$mess[0]."<br>";
}
next($post_vars);
}

mail($_REQUEST["janek@mail.pl"], $subject, "
<html>
<head>
<title>Contact letter</title>
</head>
<body>
<br>
".$message."
</body>
</html>" , $headers);
echo ("form was successfully sent!");

?>
<script>
resizeTo(300, 300);
</script>
Go to the top of the page
+Quote Post

Posty w temacie
- tomas.rosicky   PHP - formularz do wysyłania maila ze strony   20.01.2008, 01:22:10
- - potreb   Zastosuj najpier bbcode.   20.01.2008, 01:53:25
- - -tomas.rosicky-   Kod<?php Error_Reporting(E_ALL & ~E_NO...   20.01.2008, 08:30:08
- - potreb   [PHP] pobierz, plaintext <?phpmail("ja...   20.01.2008, 09:53:11
- - Zen Vantalye   Prawdopodobnie ci sie przyda http://www.jaktozrobi...   21.01.2008, 00:56:59


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 Aktualny czas: 19.08.2025 - 16:07