Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [php] checkdnsrr() - błąd?
Ciap-Ciak
post
Post #1





Grupa: Zarejestrowani
Postów: 33
Pomógł: 0
Dołączył: 31.03.2006
Skąd: Muszyna

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


mam funkcje do sprawdzania poprawnosci emiala
  1. <?php
  2. function emailveryfication($email) 
  3. {
  4.  
  5. $wholeexp = '/^(.+?)@(([a-z0-9.-]+?).[a-z]{2,5})$/i';
  6. $userexp = "/^[a-z0-9~!#$%&()-_+=[];:'",./]+$/i";
  7.  
  8. if (preg_match($wholeexp, $email, $regs))
  9. {
  10. $username = $regs[1];
  11. $host = $regs[2];
  12.  
  13. if (checkdnsrr($host, MX)) 
  14. {
  15. if (preg_match($userexp, $username))
  16. {
  17. return true;
  18. else 
  19. {
  20. return false;
  21. }
  22.  
  23. }
  24. else 
  25. {
  26. return false;
  27. }
  28.  
  29. else 
  30. {
  31. return false;
  32. }
  33.  
  34. }
  35. ?>

gdy odwoluje sie do niej:
  1. <?php
  2. emailveryfication($email);
  3. if(emailveryfication($email)==false)
  4. {
  5. echo $lang['error']['wrong_emial_syntax'];
  6. register_form();
  7. }
  8. ?>

to na localhost'cie wyskakuje error: Fatal error: Call to undefined function checkdnsrr() in C:\Program Files\WebServ\httpd\includes\functions.php on line 311

dlaczego ten error wyskakuje?
Go to the top of the page
+Quote Post

Posty w temacie


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 - 06:55