Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [PHP] Spacje w mejlu
--Cr3dO--
post
Post #1





Goście







hej, mam klaske :

  1. <?php
  2.  
  3.    class SendMailClass {
  4.        
  5.        public function SendMail ($subject, $message) {
  6.            $header = 'From: gość ze strony'."r\n";
  7.            $header .= "Content-type: text/plain; charset=UTF-8";
  8.            return mail("s.gasiewski@gmail.com", $subject, $message, $header);
  9.        }
  10.    }
  11.  
  12. ?>


i jak otrzymam mejla to w nadawcy nie mam : gość ze strony, tylko : gośćzestrony

razem, jak tam wstawic spacje ?


probowalem : gość ze strony ale niedziala
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi
novy85
post
Post #2





Grupa: Zarejestrowani
Postów: 123
Pomógł: 16
Dołączył: 31.10.2007

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


ja używam takiej funkcji do wysyłania maili

  1. <?php
  2. function SendEmail($from, $to, $subject, $text)
  3.    {
  4.       $headers = "MIME-Version: 1.0\n";
  5.       $headers .= "Content-type: text/html; charset=iso-8859-2\n";
  6.       $headers .= "From: $from\n";
  7.       $text = nl2br ($text);
  8.       $text = stripslashes ($text);
  9.       if(mail($to, $subject, $text, $headers))
  10.          return true;
  11.       return false;
  12.    }
  13. ?>


można nią wysyłać maile html
Go to the top of the page
+Quote Post
--Cr3dO--
post
Post #3





Goście







Cytat(novy85 @ 17.10.2008, 10:18:45 ) *
ja używam takiej funkcji do wysyłania maili

  1. <?php
  2. function SendEmail($from, $to, $subject, $text)
  3.    {
  4.       $headers = "MIME-Version: 1.0\n";
  5.       $headers .= "Content-type: text/html; charset=iso-8859-2\n";
  6.       $headers .= "From: $from\n";
  7.       $text = nl2br ($text);
  8.       $text = stripslashes ($text);
  9.       if(mail($to, $subject, $text, $headers))
  10.          return true;
  11.       return false;
  12.    }
  13. ?>


można nią wysyłać maile html



no i co?

nieodpowiedziales mi na zapytanie, offtop :\
Go to the top of the page
+Quote Post

Posty w temacie
- -Cr3dO-   [PHP] Spacje w mejlu   17.10.2008, 10:05:54
- - novy85   ja używam takiej funkcji do wysyłania maili [PHP...   17.10.2008, 10:18:45
|- - -Cr3dO-   Cytat(novy85 @ 17.10.2008, 10:18:45 )...   17.10.2008, 12:34:34
|- - pyro   Cytat(novy85 @ 17.10.2008, 11:18:45 )...   17.10.2008, 12:38:16
|- - -Cr3dO-   Cytat(pyro @ 17.10.2008, 12:38:16 ) T...   17.10.2008, 13:41:29
- - Maxik   Może zamiast spacji daj %20   17.10.2008, 14:21:31
|- - -Cr3dO-   Cytat(Maxik @ 17.10.2008, 14:21:31 ) ...   17.10.2008, 16:49:14
- - webdice   Dodaje tag w tytule, następnym razem tematy bez ta...   17.10.2008, 17:02:47
|- - Cr3dO   Cytat(webdice @ 17.10.2008, 18:02:47 ...   17.10.2008, 18:20:18
- - l0ud   Spróbuj tak: [PHP] pobierz, plaintext <?php$he...   17.10.2008, 19:44:30


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

 



RSS Aktualny czas: 5.10.2025 - 22:17