Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 8 of 8
  1. #1
    New Coder
    Join Date
    Jul 2012
    Posts
    25
    Thanks
    3
    Thanked 0 Times in 0 Posts

    Contact form captcha FG_CaptchaHandler error

    I have setup a contact form from
    Code:
    http://www.html-form-guide.com/contact-form/php-contact-form-tutorial.html
    After setting on my server I am getting error
    Code:
     Fatal error: Class 'FG_CaptchaHandler' not found in captcha-creator.php on line 3
    line 3
    Code:
    class FGCaptchaCreator extends FG_CaptchaHandler
    It works fine on other host

    I guess it might be some hosting problem but cant figure out it

  • #2
    God Emperor Fou-Lu's Avatar
    Join Date
    Sep 2002
    Location
    Saskatoon, Saskatchewan
    Posts
    16,994
    Thanks
    4
    Thanked 2,662 Times in 2,631 Posts
    Its not a hosting issue, but it could be a configuration difference relating to the autoloads.

    The issue itself is simply that you cannot extend a non-existing class. The system cannot find the class FG_CaptchaHandler. Make sure that you have provided the path to the file to require, or that you have properly registered the path for the spl_autoload registers.

  • #3
    Senior Coder
    Join Date
    Apr 2011
    Location
    London, England
    Posts
    2,120
    Thanks
    15
    Thanked 354 Times in 353 Posts
    If you copied it exactly then this

    Code:
    require_once("./include/fgcontactform.php");
    is looking for the file in the sub-directory 'include' from your root directory. Is it saved in this location?

    But that file also requires class.phpmailer.php. Did you download this file to the include folder as well?

    And have you uploaded these files?
    "I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.
    Validate your HTML and CSS

  • #4
    New Coder
    Join Date
    Jul 2012
    Posts
    25
    Thanks
    3
    Thanked 0 Times in 0 Posts
    @ AndrewGSW
    Yes its exactly saved in this location and include folder has " class.phpmailer.php" too

  • #5
    New Coder
    Join Date
    Jul 2012
    Posts
    25
    Thanks
    3
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by Fou-Lu View Post
    Its not a hosting issue, but it could be a configuration difference relating to the autoloads.

    The issue itself is simply that you cannot extend a non-existing class. The system cannot find the class FG_CaptchaHandler. Make sure that you have provided the path to the file to require, or that you have properly registered the path for the spl_autoload registers.
    how do I register the path for the spl_autoload registers ?

  • #6
    New Coder
    Join Date
    Jul 2012
    Posts
    25
    Thanks
    3
    Thanked 0 Times in 0 Posts
    Is there a way I could disable captcha from this form ?

  • #7
    Senior Coder
    Join Date
    Apr 2011
    Location
    London, England
    Posts
    2,120
    Thanks
    15
    Thanked 354 Times in 353 Posts
    Quote Originally Posted by ska_defender View Post
    Is there a way I could disable captcha from this form ?
    The page you initially referenced has an example form without the captcha.
    "I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.
    Validate your HTML and CSS

  • #8
    New Coder
    Join Date
    Jul 2012
    Posts
    25
    Thanks
    3
    Thanked 0 Times in 0 Posts
    If you scroll below you will find " Contact form that emails based on a condition"

    this one

    http://www.html-form-guide.com/files...ontactform.php


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •