seemannit/recaptcha 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

seemannit/recaptcha

最新稳定版本:v2.0

Composer 安装命令:

composer require seemannit/recaptcha

包简介

ReCaptcha module for OXID eShop.

README 文档

README

Implements Google's ReCaptcha into OXID eShops.

Installation

Download the latest release and copy the contents of the folder copy_this to your server. Do NOT download the source files and just upload them to your server, that won't work.

Generate a key pair on https://www.google.com/recaptcha/admin and set the values in the module settings in the OXID backend. Then activate the module.

for ROXID users

No further action required.

for users of other templates

In addition to that, for users of other templates, some additional blocks to the template. The following files have to be modified:

  • form/contact.tpl
  • form/pricealarm.tpl
  • form/suggest.tpl
  • form/privatesales/invite.tpl

Enclose the label in a block named captcha_label, for example in the form/contact.tpl, replace (around line 56)

<label class="req">[{ oxmultilang ident="VERIFICATION_CODE" suffix="COLON" }]</label>

by

<label class="req">
    [{block name="captcha_label"}]
        [{ oxmultilang ident="VERIFICATION_CODE" suffix="COLON" }]
    [{/block}]
</label>

and the actual captcha in a block named captcha_body

[{assign var="oCaptcha" value=$oView->getCaptcha() }]
[{if $oCaptcha->isImageVisible()}]
    <img src="[{$oCaptcha->getImageUrl()}]" alt="">
[{else}]
    <span class="verificationCode" id="verifyTextCode">[{$oCaptcha->getText()}]</span>
[{/if}]
<input type="text" data-fieldsize="verify" name="c_mac" value="" class="js-oxValidate js-oxValidate_notEmpty">
<p class="oxValidateError">
    <span class="js-oxError_notEmpty">[{ oxmultilang ident="ERROR_MESSAGE_INPUT_NOTALLFIELDS" }]</span>
</p>

by

[{block name="captcha_body"}]
    [{assign var="oCaptcha" value=$oView->getCaptcha() }]
    [{if $oCaptcha->isImageVisible()}]
        <img src="[{$oCaptcha->getImageUrl()}]" alt="">
    [{else}]
        <span class="verificationCode" id="verifyTextCode">[{$oCaptcha->getText()}]</span>
    [{/if}]
    <input type="text" data-fieldsize="verify" name="c_mac" value="" class="js-oxValidate js-oxValidate_notEmpty">
    <p class="oxValidateError">
        <span class="js-oxError_notEmpty">[{ oxmultilang ident="ERROR_MESSAGE_INPUT_NOTALLFIELDS" }]</span>
    </p>
[{/block}]

Similar modifications have to be performed for the other three files listed above.

统计信息

  • 总下载量: 497
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 6
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 6
  • Watchers: 3
  • Forks: 3
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2020-04-22

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固