We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 14867
    • 65 Posts
    Yea... looks good.
    i will try to make that work for my situation.

    can i protect that from changes somehow?
    if someone typed in his mail and marked this as
    his item noone else should be able to edit this or to delete his
    mail... you understand. can i protect this with a password?

    how would this work ?



    ok but first of all i will have to build this smiley
    thank you very much.











      42
      • 20413
      • 2,877 Posts
      That is the tricky part.

      &protectSubmit(optional) defaults to 1 (on)
      Protects against submitting a form multiple times with the same data. Submitting the form becomes disabled after the first successful submit while the value from key form fields remains the same. This is achieved by setting (and comparing) a session variable with an md5 hash from these key fields. Which fields are compared depends on the value of &protectSubmit.Possible values are 0 (off), 1 (all ’required’ fields are used) or you can set a comma separated list of field names. To ensure that the session variable works separatedly for different forms the session variable name is based on &formid ({formid}_hash).
      &submitLimit (optional) off (0) by default
      Enforces a time limit (in minutes) between form submits. After the form has been submitted successfully it can not be submitted again for &submitLimit minutes irrespective of the form data. When used in combination with &protectSubmit submitLimit takes precedence, meaning that when the time limit has expired the form can be submitted again regardless of the setting of &protectSubmit (it will unset the session variable). As with &protectSubmit this parameter uses a session variable with a variable name based on &formid.

      Who wants this information and is it a demand everybody else see it?

      You could make custom db fields and have the form on each users restricted home page. Then on a public page call the fields. Then instead of posting new have the eform SNIPPET update the database fields... I haven’t looked in to that but sure that must be easy changeable.  :)


      //Yes simple change:

      // INSERT - $dbQuery = $modx->db->insert( $dbTable, $table_prefix . ’insertTableName’ );
      // UPDATE - $dbQuery = $modx->db->update( $dbTable, $table_prefix . ’updateTableName’ );
      // DELETE - $dbQuery = $modx->db->delete( $table_prefix . ’deleteFromTableName’, ’some_field = 1 AND name=\’’.$dbTable[name].’\’’, ’’ );
      // etc...

      http://modxcms.com/forums/index.php?topic=8111.0

      This is really cool stuff!! laugh
        @hawproductions | http://mrhaw.com/

        Infograph: MODX Advanced Install in 7 steps:
        http://forums.modx.com/thread/96954/infograph-modx-advanced-install-in-7-steps

        Recap: Portland, OR (PDX) MODX CMS Meetup, Oct 6, 2015. US Bancorp Tower
        http://mrhaw.com/modx_portland_oregon_pdx_modx_cms_meetup_oct_2015_us_bancorp_tower
        • 20413
        • 2,877 Posts
        Then I learned this ---> http://wiki.modxcms.com/index.php/DB_query_and_Placeholders

        //Modx is now extended to do everything in the world!!
          @hawproductions | http://mrhaw.com/

          Infograph: MODX Advanced Install in 7 steps:
          http://forums.modx.com/thread/96954/infograph-modx-advanced-install-in-7-steps

          Recap: Portland, OR (PDX) MODX CMS Meetup, Oct 6, 2015. US Bancorp Tower
          http://mrhaw.com/modx_portland_oregon_pdx_modx_cms_meetup_oct_2015_us_bancorp_tower
          • 14867
          • 65 Posts
          thats a very cool way. i think i will concentrate on this way.
          see you soon ;-)
            42
            • 14867
            • 65 Posts
            cool... that works.
            can i use that way to make a dropdown for each wish
            lets say 3 wishes ;-), a password field and an ok button?
            just for protection of that dropdown and when i delete
            my selection or change it to "unselect" the password sould be deleted too...

            somehow im stuck..
            i do flash but no JS so...


              42
              • 20413
              • 2,877 Posts
              I would used weblogin and maybe a temorarily user account for your guests to reach an restricted page.
              This can be done by .htpasswd or http://modxcms.com/DocPassword-1788.html as well.

              You need an eForm with specific ID for each database command you want to pass though you call
              the snippet in the eform call and also load it before. But you sure can use dropwown for the input data

              I.e
                  <p><label accesskey="s" for="department">Subject</label>
                  <select name="department">
                      <option value="1">Website feedback</option>
                      <option value="2">Support request</option>
                      <option value="3">Feature request</option>
                  </select></p
              


                @hawproductions | http://mrhaw.com/

                Infograph: MODX Advanced Install in 7 steps:
                http://forums.modx.com/thread/96954/infograph-modx-advanced-install-in-7-steps

                Recap: Portland, OR (PDX) MODX CMS Meetup, Oct 6, 2015. US Bancorp Tower
                http://mrhaw.com/modx_portland_oregon_pdx_modx_cms_meetup_oct_2015_us_bancorp_tower