Author Topic: Duplicated captcha on registration page after upgrade  (Read 6219 times)

ufo_hk

  • Jr. Member
  • **
  • Posts: 82
    • 4success Ltd
Re: Duplicated captcha on registration page after upgrade
« Reply #15 on: April 28, 2022, 23:29:15 pm »
Found this after upgrading a Virtuemart 2 site to Virtuemart 3.8.8 and thanks to mcambou1 it fixed my issue.

Why is this still occurring - shouldn't it be fixed permanently?

Thanks

jenkinhill

  • UK Web Developer & Consultant
  • Global Moderator
  • Super Hero
  • *
  • Posts: 28456
  • Always on vacation
    • Jenkin Hill Internet
Re: Duplicated captcha on registration page after upgrade
« Reply #16 on: April 29, 2022, 12:26:23 pm »
VM3.8.8 is from January 2021 and was the version containing the error. It's fixed in later versions.   
See news of the latest version here: https://virtuemart.net/news/506-virtuemart-4
Kelvyn

Jenkin Hill Internet,
Lowestoft, Suffolk, UK

Unsolicited PMs/emails will be ignored.

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

Currently using VirtueMart 4.0.12 10777  J 3.10.11 PHP 7.4.30

semen_123

  • Beginner
  • *
  • Posts: 5
  • A beginner
Re: Duplicated captcha on registration page after upgrade
« Reply #17 on: November 20, 2022, 20:59:44 pm »
Why did they add it?
\www\components\com_virtuemart\helpers\shopfunctionsf.php
line ~ 1195
Code: [Select]
$output = $dispatcher->trigger('onDisplay', array($reCaptchaName, $id, 'class="g-recaptcha required"'));
class="g-recaptcha required" causes a bug:

Code: [Select]
<div id="dynamic_recaptcha_1" class="class="g-recaptcha required" g-recaptcha" data-sitekey=....."
Please write a solution here

Jumbo!

  • 3rd party VirtueMart Developer
  • Full Member
  • *
  • Posts: 870
  • Full-stack Web Developer
    • www.virtueplanet.com
  • VirtueMart Version: Always the latest
Re: Duplicated captcha on registration page after upgrade
« Reply #18 on: November 21, 2022, 14:33:17 pm »
Why did they add it?
\www\components\com_virtuemart\helpers\shopfunctionsf.php
line ~ 1195
Code: [Select]
$output = $dispatcher->trigger('onDisplay', array($reCaptchaName, $id, 'class="g-recaptcha required"'));
class="g-recaptcha required" causes a bug:

Code: [Select]
<div id="dynamic_recaptcha_1" class="class="g-recaptcha required" g-recaptcha" data-sitekey=....."
Please write a solution here

Replace the code with the following.

Code: [Select]
$output = $dispatcher->trigger('onDisplay', array($reCaptchaName, $id, 'g-recaptcha required'));