WebsiteBaker Logo
  • *
  • Templates
  • Help
  • Add-ons
  • Download
  • Home
*
Welcome, Guest. Please login or register.

Login with username, password and session length
 

News


WebsiteBaker 2.13.6 is now available!


Will it continue with WB? It goes on! | Geht es mit WB weiter? Es geht weiter!
https://forum.websitebaker.org/index.php/topic,32340.msg226702.html#msg226702


The forum email address board@websitebaker.org is working again
https://forum.websitebaker.org/index.php/topic,32358.0.html


R.I.P Dietmar (luisehahne) and thank you for all your valuable work for WB
https://forum.websitebaker.org/index.php/topic,32355.0.html


* Support WebsiteBaker

Your donations will help to:

  • Pay for our dedicated server
  • Pay for domain registration
  • and much more!

You can donate by clicking on the button below.


  • Home
  • Help
  • Search
  • Login
  • Register

  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.12.x) »
  • General Help & Support »
  • Captcha not loading
  • Print
Pages: [1]   Go Down

Author Topic: Captcha not loading  (Read 12134 times)

Offline tobyw7

  • Posts: 77
  • Gender: Male
    • Toby White
Captcha not loading
« on: November 11, 2020, 10:13:40 PM »
Hi!

I have noticed the captcha has stopped loading

https://www.frantik-web.co.uk/pages/contact.php

I'm using MPForm for the form module.

Any ideas at all? I can't immediately see any errors in web console in Firefox.

Thx
Logged

Offline dbs

  • Betatester
  • **
  • Posts: 8915
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: Captcha not loading
« Reply #1 on: November 11, 2020, 11:34:17 PM »
Hi, what are your versions of WB, PHP and MPform?
What have you done before or what was your last changes?
Logged
https://onkel-franky.de

Offline Martin Hecht

  • Betatester
  • **
  • Posts: 608
  • Gender: Male
    • meine Homepage
Re: Captcha not loading
« Reply #2 on: November 12, 2020, 09:49:30 AM »
there is a php warning from the captcha generator:
Code: [Select]
<br /><b>Deprecated</b>:  Array and string offset access syntax with curly braces is deprecated in <b>.../include/captcha/captchas/create_ttf_image.php</b> on line <b>60</b><br />With this output in the png file it is a corrupt image which the browser doesn't know how to render...
Logged

Offline Luisehahne

  • WebsiteBaker Org e.V.
  • **
  • Posts: 4548
  • Gender: Male
Re: Captcha not loading
« Reply #3 on: November 12, 2020, 01:32:27 PM »
in PHP 7.4 curly braces are deprecated. There are 2 files you have to fix.

search in /include/captcha/captchas/create_calc_ttf_image.php following line (should be line 70)
                $res = imagettftext($image, $ttfsize, $angle, $x, $y, $textcolor, $ttf, $text{$i});
and change to
                $res = imagettftext($image, $ttfsize, $angle, $x, $y, $textcolor, $ttf, $text[$i]);

and the same in /include/captcha/captchas/create_ttf_image.php following line (should be line 60)

Dietmar
Logged
Note: Once the code has been generated, it is easy to debug. It's not a bug, it's a feature!

Offline tobyw7

  • Posts: 77
  • Gender: Male
    • Toby White
Re: Captcha not loading
« Reply #4 on: November 12, 2020, 07:18:47 PM »
Quote from: Luisehahne on November 12, 2020, 01:32:27 PM
in PHP 7.4 curly braces are deprecated. There are 2 files you have to fix.

search in /include/captcha/captchas/create_calc_ttf_image.php following line (should be line 70)
                $res = imagettftext($image, $ttfsize, $angle, $x, $y, $textcolor, $ttf, $text{$i});
and change to
                $res = imagettftext($image, $ttfsize, $angle, $x, $y, $textcolor, $ttf, $text[$i]);

and the same in /include/captcha/captchas/create_ttf_image.php following line (should be line 60)

Dietmar


Thanks Dietmar, this fixed the problem :)
Logged

Offline tobyw7

  • Posts: 77
  • Gender: Male
    • Toby White
Re: Captcha not loading
« Reply #5 on: November 12, 2020, 07:21:20 PM »
Quote from: dbs on November 11, 2020, 11:34:17 PM
Hi, what are your versions of WB, PHP and MPform?
What have you done before or what was your last changes?

For reference,

WB 2.12.2 r379
PHP 7.4
MPform 1.3.21
Logged

Offline dbs

  • Betatester
  • **
  • Posts: 8915
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: Captcha not loading
« Reply #6 on: November 12, 2020, 07:30:22 PM »
Our next WB version will support PHP 7.4.
WB 2.12.2 is only for max PHP 7.3
Logged
https://onkel-franky.de

  • Print
Pages: [1]   Go Up
  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.12.x) »
  • General Help & Support »
  • Captcha not loading
 

  • SMF 2.0.19 | SMF © 2017, Simple Machines
  • XHTML
  • RSS
  • WAP2