We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 8168
    • 1,118 Posts
    Does anyone in the core team have a solution for this??? Quip really needs to work with reCaptcha v2 as v1 will cease to work very soon!
      • 8168
      • 1,118 Posts
      Quote from: waivor at Jan 30, 2018, 06:49 PM
      Quote from: mediengaarage at Jan 13, 2018, 09:01 AM
      Is there no way to integrate the extra RecaptchaV2 as preHooks, as it does with formit?

      https://modx.com/extras/package/recaptchav2

      I'm afraid there is none. At least nothing that could be called "official". But the changelog says: "New in 2.0.0 [...] [#3519] Add pre and post Hooks to Quip".

      Hi - did you manage to get it working with recaptcha v2?
        • 8168
        • 1,118 Posts
        Quote from: lizardx at Dec 26, 2017, 01:24 AM
        I can answer only one part of the question above, and am working on the actual reality of switching Quip to use recaptchav2.

        As noted, first install the RecaptchaV2 package. Then add your new Recaptcha api v2 public and private keys to the RecaptchaV2 settings. You got those from your google account:
        https://www.google.com/recaptcha/admin

        To add to template for Quip:

        [[!recaptchav2_render]]


        Note the ! which the poster had left off.

        This will make the recaptcha box appear, but so far I have not been able to get any further due to a complete lack of documentation about recaptcha and quip.

        In the main quip chunk, I have:

        [[!Quip? 
        &thread=`thread-[[*id]]` 
        &threaded=`0` 
        &useGravatar=`0`
        &tplComment=`tplQuipComment`
        &useCss=`0`]]
        [[$quip-top-1]]
        [[!QuipReply? 
        &thread=`thread-[[*id]]`
        &useGravatar=`0`
        &tplAddComment=`tplQuipAddComment`
        &recaptcha=`1`
        &disableRecaptchaWhenLoggedIn=`0`
        &autoConvertLinks=`0`
        &moderate=`1`
        &closeAfter=`0`
        ]]


        However this does NOT appear to have any connection the recaptcha v2, it's the old recaptcha, which have settings as well in the settings manager.

        The Quip doc page has no reference to the recaptcha v2 at all:

        https://docs.modx.com/extras/revo/quip
        https://modx.com/extras/package/recaptchav2

        So I think maybe it's time to update the docs here so that we can fairly easily figure out how to upgrade quip to using recaptcha v2.

        I've been experimenting here a bit, but as far as I can tell so far, while you can get the recaptchav2 box to appear and function superficially, so far I've found no way to make the recaptcha actually work in terms of showing the error messages and blocking form submit. In fact, form submit doesn't work at all in my tests.

        I may be missing some key error messages due to the total absence of docs however.

        [Update:] Because Quip simply does not work so far with RecaptchaV2 plugin, I've rolled it back to use v1, but given v1 expires on March 31, 2018, I'd say it's reasonably pressing to get the docs updated, and make sure these things all work together. Or switch the internal modx stuff to use recaptcha v2, not sure how those things hang together.

        Hi - did you manage to get it working with recaptcha v2?
          • 17301
          • 932 Posts
          What's the issue with just using it out of the box as its intended to be used?

          https://developers.google.com/recaptcha/docs/display
            ■ email: [email protected] | ■ website: https://alienbuild.uk

            The greatest compliment you can give back to us, is to spend a few seconds leaving a rating at our trustpilot: https://uk.trustpilot.com/review/alienbuild.uk about the service we provided. We always drop mention of services offered by businesses we've worked with in the past to those of interest.
            • 39053
            • 34 Posts
            That's the problem. It doesn't work out of the box.
            When i put the recaptchaV2 in the addCommentTpl then you can send the form without the right captcha.
            Perhaps there should be a callback?

            <html>
              <head>
                <title>reCAPTCHA demo: Simple page</title>
                 <script src="https://www.google.com/recaptcha/api.js" async defer></script>
              </head>
              <body>
                <form action="?" method="POST">
                  <div class="g-recaptcha" data-sitekey="your_site_key"></div>
                  <br/>
                  <input type="submit" value="Submit">
                </form>
              </body>
            </html>

              • 13226
              • 953 Posts
              Sorry if this doesn't help one bit, BUT, it might be a starting point for someone to convert for REVO

              reCAPTCHA V2 is a built in option used in FormLister for Evo

              FormLister documentation can be found here

              FormLister tutorials can be found here

              Specific reCAPTCHA V2 tutorial is here

              The FormLister Snippet can be found here
                • 8168
                • 1,118 Posts
                Quote from: lkfranklin at Feb 26, 2018, 03:35 PM
                What's the issue with just using it out of the box as its intended to be used?

                https://developers.google.com/recaptcha/docs/display

                I am not sure I follow what you mean? I need it integrated into the Quip comments form so that on click of submit a comment, the recaptcha is validated to make sure has been completed correctly.

                Actually getting the v2 recaptcha to display is easy - but it is not then integrated with the standard quip comment system so it doesnt get checked - its just ignored

                It looks like the "core/components/quip/model/recaptcha/recaptcha.class.php" file needs to be updated to work with the recaptcha v2 systems to me.

                Anyone fancy updating it as per > https://blog.sendsafely.com/migrating-to-googles-nocaptcha-recaptcha [ed. note: dubbs last edited this post 6 years, 1 month ago.]
                  • 8168
                  • 1,118 Posts
                  Quote from: mediengaarage at Feb 26, 2018, 06:16 PM
                  That's the problem. It doesn't work out of the box.
                  When i put the recaptchaV2 in the addCommentTpl then you can send the form without the right captcha.
                  Perhaps there should be a callback?

                    
                      <title>reCAPTCHA demo: Simple page</title>
                       <script src="https://www.google.com/recaptcha/api.js" async="" defer=""></script>
                    
                    
                      <form action="?" method="POST">
                        <div class="g-recaptcha" data-sitekey="your_site_key"></div>
                        
                  
                        <input value="Submit" type="submit">
                      </form>
                    
                  


                  Use https://modx.com/extras/package/recaptchav2 tp display the recaptcha
                    • 39053
                    • 34 Posts
                    For the usage of recaptchaV2 you need: &hooks=`recaptchav2`
                    I think in quip there is no possibility of hooks, is it?
                      • 8168
                      • 1,118 Posts
                      Quote from: mediengaarage at Feb 27, 2018, 12:07 PM
                      For the usage of recaptchaV2 you need: &hooks=`recaptchav2`
                      I think in quip there is no possibility of hooks, is it?

                      That's the issue.. Quip doesnt have hooks (as far as I am aware) - https://docs.modx.com/extras/revo/quip/quip.quipreply
                      By default it includes the option to include a recaptcha element - e.g. using recaptcha=1 - but that means it will render the v1 recaptcha... and not v2 - hence my note above about editing the PHP that quip uses to display the recaptcha - if that could be edited to work with the v2 markup / approach - then it would work... i think!