Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing hook in image_verification.tpl #106

Open
mcer12 opened this issue Mar 25, 2018 · 2 comments
Open

Missing hook in image_verification.tpl #106

mcer12 opened this issue Mar 25, 2018 · 2 comments

Comments

@mcer12
Copy link

mcer12 commented Mar 25, 2018

Hi, i found out that the hook "common:image_verification" is missing in image_verification.tpl, therefore the recaptcha plugin doesn't work in boilerplate. There is also missing condition. See fixed code below:

@mcer12
Copy link
Author

mcer12 commented Mar 25, 2018

{if $option|fn_needs_image_verification == true}
{hook name="common:image_verification"}
{assign var="is" value=$settings.Image_verification}
{assign var="id" value="iv_"|uniqid}

{if $app.antibot->getDriver()|get_class == "Tygh\Web\Antibot\PhpCaptchaDriver"}
    <div class="captcha form-group">
        <label for="verification_answer_{$id}" class="cm-required control-label">{__("image_verification_label")}</label>
        <p class="captcha-code">
            <img id="verification_image_{$id}" src="{"image.captcha?verification_id=$id&no_session=Y&$id"|fn_url}" alt="" onclick="this.src += '|1' ;"  width="{$is.width}" height="{$is.height}" class="cursor-pointer" />
            <i class="glyphicon glyphicon-refresh fa fa-refresh cursor-pointer" onclick="document.getElementById('verification_image_{$id}').src += '|1';"></i>
        </p>
        <input class="form-control cm-autocomplete-off" type="text" id="verification_answer_{$id}" name="verification_answer" value= "" />
        <input type="hidden" name="verification_id" value= "{$id}" />
        <div class="cm-field-container"></div>
        <span id="helpBlock" class="help-block {if $align}{$align}{/if}">{__("image_verification_body")}</span>
    </div>
{/if}

{/hook}
{/if}

@mcer12
Copy link
Author

mcer12 commented Apr 4, 2019

This issue is fixed on my fork of the repository since this rep seems to be abandoned.
https://github.com/mcer12/cscart-boilerplate

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant