Witam smile.gif

mam do Was kolejne pytanie z serii "problemy laika".

Sprawa dotyczy wysyłania formularzy ze strony mailem - oczywiście wykorzystując php.
Korzystam z gotowych skryptów ... i tu jest mały problem ...
Te najprostsze typu yoaimailer czy phpmail oprate tylko na jednym pliku i ewentualnie formularzu formatują tekst bez polskich znaków sad.gif
Zaś form2mail zwraca mi błąd Warning: mail(): SMTP server response: 550 Invalid recipient ... itd. sadsmiley02.gif

I tu moje pytanka:
1) jak się pozbyć tego błędu 550 Invalid ... z form2mail
2) względnie jak wymusić polskie litery w mailu np. z czegoś takiego (orginalna nazwa to romcomail - część creditsów wyciąłem teraz ze względu na przejrzystość kodu):


  1. <?
  2. $mailto=  "you@yourdomain.cpom";
  3. $subject= "subject";
  4. $from=  "you@yourwebsite.com";
  5.  
  6. /* Changing these is optional */
  7.  
  8. $opening= "Your webpage form sent the following information:";
  9. $footer= "Form processed by RomcoMail";
  10.  
  11. /* If set will go to this page after form is sent.
  12. * example: htp://yourdomain.com/thankyou.html */
  13.  
  14. $new_url= "http://yourdomain/thankyou.html";
  15.  
  16.  
  17. /**************************************************************/
  18.  
  19.  
  20. if (isset($Name)){
  21. if (!is_array($HTTP_POST_VARS)){
  22. return;
  23. reset($HTTP_POST_VARS);
  24. }
  25. while(list($key, $val) = each($HTTP_POST_VARS)) {
  26. $GLOBALS[$key] = $val;
  27. $val=stripslashes($val);
  28. $content= $content."$key = $val\n";
  29. }
  30.  
  31. $message= "$opening\n\n"."$content\n\n".$footer;
  32. mail($mailto, $subject, $content, "From: $from");
  33.  
  34.  if (isset($new_url)){
  35.  header ("Location: $new_url");
  36.  }
  37.  
  38. }
  39. ?>
  40. <html>
  41. <head>
  42. <title>RomcoMail Demo Form</title>
  43. </head>
  44.  
  45.  
  46. <body>
  47.  
  48. <h1>RomcoMail Demo</h1>
  49.  
  50. <!-- see part 2 above ->
  51. <form name="Demo" method="post" action="<? echo $PHP_SELF; ?>">
  52.  
  53. <table border="0" cellspacing="0" cellpadding="2" width="325">
  54. <tr> 
  55. <td width="156"> 
  56. <div align="right">Name:</div>
  57. </td>
  58. <td width="144"> 
  59.  
  60. <! -- one text field must be called "Name" --> 
  61. <input type="text" name="Name">
  62. </td>
  63. </tr>
  64. <tr> 
  65. <td width="156"> 
  66. <div align="right">Phone Number:</div>
  67. </td>
  68. <td width="144"> 
  69. <input type="text" name="Phone_Number">
  70. </td>
  71. </tr>
  72. <tr> 
  73. <td width="156"> 
  74. <div align="right">Email:</div>
  75. </td>
  76. <td width="144"> 
  77. <input type="text" name="Email">
  78. </td>
  79. </tr>
  80. </table>
  81. <br>
  82. <input type="submit" name="button1" value="Submit">
  83. <input type="reset" name="button2" value="Reset">
  84. </form>
  85.  
  86.  
  87. </body>
  88. </html>



Z tego co się orientuje to chyba trzeba dodać do mail() np. charset=ISO-8859-1, albo jakieś inne kodowanie, niestety coś mi to nie wychodzi ... jak dopisać ten fragment questionmark.gif?

To jak ? ktoś pomoże questionmark.gif

Pozdrawiam