0

I am very new to PHP. I did a contact form using HTML and PHP and I keep getting this error:

Fatal error: Uncaught Error: Call to undefined function eregi() in F:\xampp\htdocs\hotel\include\fgcontactform.php:548 Stack trace: #0 F:\xampp\htdocs\hotel\include\fgcontactform.php(387): FGContactForm->validate_email('lyubo841@gmail....') #1 F:\xampp\htdocs\hotel\include\fgcontactform.php(129): FGContactForm->Validate() #2 F:\xampp\htdocs\hotel\contactform.php(26): FGContactForm->ProcessForm() #3 {main} thrown in F:\xampp\htdocs\hotel\include\fgcontactform.php on line 548

I've been trying to fix it for hours but no success. I haven't provided any code because the code is long and don't know which part to provide.

Please assist and ask for the code if required.

u_mulder
  • 54,101
  • 5
  • 48
  • 64

1 Answers1

0

ereg_replace function was DEPRECATED in PHP 5.3.0, and REMOVED in PHP 7.0.0. So you must have to use preg_replace() function instead of ereg_replace() Where You Define In The COde

RïshïKêsh Kümar
  • 4,734
  • 1
  • 24
  • 36