We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 10877
    • 5 Posts
    Hi

    hope you can help me - I am fairly new to MODx...

    On my site http://www.gizmofaq.net I have a Feedback page, using Jot.

    The code that I am using is: [!Jot? &captcha=`2`!] .

    This works fine, but I want to be able to suppress the input form that appears above the existing comments, taking up most of the page.

    I would like to replace this form with a button or a link (’Add new comment’) which would open the input form, possibly in a new window, when clicked.

    This would mean that the existing comments would not be pushed down the page.

    I know a little php, and am ok with css, but would like some pointers please, as I am not yet familiar with MODx or Jot.

    Thanks
      • 7923
      • 4,213 Posts
      You could wrap the form into a div that is hidden by default and then do "add comment" link that uses javascript to make the div visible.


        "He can have a lollipop any time he wants to. That's what it means to be a programmer."
        • 10877
        • 5 Posts
        Hi Doze,

        thanks for your swift reply.

        Yes, that should do it. I had not thought of using Javascript - It is legitimate, because the site functionality will still be there for non-javascript browsers.

        I will do some testing and hopefully get it sorted.

          • 10877
          • 5 Posts
          Ok
          I have managed to get this to work using Javascript.

          See http://gizmofaq.net/g1/index.php?id=61

          If anyone is interested, please ask, and I will post the code...
            • 4195
            • 398 Posts
            use &placeholders=`1` &output=`0` this will create placeholders for you to use but will not output anything by default.
            Now on the page use:

            [+jot.html.navigation+] (this is for the navigation)
            [+jot.html.comments+] (this is for the comments)
            [+jot.html.moderate+] (this is for the moderator functions)

            and for the popup only use [+jot.html.form+]. You have to make sure that the popup (hidden div tag or some other method) is still part of the same page.

            I hope this gives you another push in the good direction.

            edit: lol you got it to work already smiley
              Armand Pondman
              MODx Coding Team
              :: Jot :: PHx