We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 16702 ☆ A M B ☆
    • 536 Posts
    Hello,

    &subscribe=`1`


    this is for subscribe for author of document?
    But how make subscribe for comment`s authors???
    My idea is like WordPress when somebody post comment and after this "body"another post first "body" get mail with info for second or third...message`s.

    10x
      palma non sine pulvere
      • 1122
      • 209 Posts
      Subscription to Jot’s comments is a feature accessible for users that were registered on your site (i.e. users that have valid either manager or web accounts). In order to make notification of a new comment, Jot needs to know visitor’s e-mail, right? These e-mails are provided to your site during registration process -- you can manually create manager accounts for some users you wish to invite to subscription or you can implement autoregistration for web accounts through Weblogin or WebloginPE snippets. Only the logged users can subscribe to comments.

      In order to make subscription feature working, you need three things: 1) create/give accounts for users, 2) set &subscribe=`1` in Jot’s call, 3) assure that [+jot.html.subscribe+] placeholder is present in your template (if you are running Jot with &placeholders=`1` &output=`0`).
        • 16702 ☆ A M B ☆
        • 536 Posts
        Hello alik,

        nice succession, but i thing is hard way to make something easy...like comment subscriptions. Wonder if another way...easy way smiley
        In another hand your suggestion is more safely... (in all PROBABILITY - NO SPAM and unreal users)
        Continue to find easy way smiley

        !0x
          palma non sine pulvere
          • 16702 ☆ A M B ☆
          • 536 Posts
          I have second question...maybe is easy smiley
          again like WOrdpress (heeey, i use modx smiley but...) how show users IP but mask last 2 symbols?
            palma non sine pulvere
            • 1122
            • 209 Posts
            As regards your post #3 (i.e. easy way for subscriptions), adding RSS feature to Jot would be such an easy way -- everybody would be able to subscribe/unsubscribe without registration. Unfortunately, I have not enough time to deal with this issue. But I can help you with #4.

            In order to show IP that the comment was submitted from, you need to insert into your comment’s template [+comment.secip+] placeholder that will reveal entire number. Masking two last digits might be regarded as beginner’s exercise in regular expressions:
            <?php
            /* 
             MaskIP Snippet - hides two last digits of IP
             Written by http://setpro.net.pl/
             Parameters:
               ip -> self-explained
               mask -> character to hide a single digit (default: '*')
            */
            $mask = isset($mask) ? $mask : '*';
            return isset($ip) && preg_match('/^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/', $ip) ? preg_replace('/(\d)(\.)?(\d)$/', $mask . '$2' . $mask, $ip) : '';
            ?>
            

            So, finally you need to insert into your template this:
            [[MaskIP? &ip=`[+comment.secip+]`]]
            

            Good luck.
              • 28042 ☆ A M B ☆
              • 24,524 Posts
              Or you could use phx in the placeholder.
                Studying MODX in the desert - http://sottwell.com
                Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
                Join the Slack Community - http://modx.org