PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

Form action customization

  1. Every form the client makes has a different form action code such as

    <form class="validator" method="post" action="http://v2.aanmelden.nu/aanmelden.php?optlist=yqhvostdkgdgpcw" target="_blank">

    how to accomplish this in a simple manner. I know it has somethingto do with using hooks, but I rather use something in the form itself, through a plugin, is that possible?

    Posted 11 years ago on Wednesday June 20, 2012 | Permalink
  2. David Peralty

    By default, Gravity Forms submits forms to itself for processing, and saving of the user data. If you want to send data to a third party page or whatnot, there are hooks for that. Can you tell me more about what you are trying to do?

    Posted 11 years ago on Wednesday June 20, 2012 | Permalink
  3. The user data will be post to an extern website, that is all. Thanks for replying so soon David.
    Greetz, Annet

    Posted 11 years ago on Wednesday June 20, 2012 | Permalink
  4. David Peralty

  5. Thanks David, but do I have to include this code into form_display.php?
    Why can't I write this code in every seperate form setting itself?

    (I'm not a programmer, sorry if this question is silly ;-)

    Posted 11 years ago on Wednesday June 20, 2012 | Permalink
  6. David Peralty

    Here is information on where code goes:
    http://www.gravityhelp.com/documentation/page/Where_Do_I_Put_This_Code%3F

    Posted 11 years ago on Wednesday June 20, 2012 | Permalink
  7. David Peralty

    Gravity Forms doesn't allow you to change where it submits information. It has to submit to itself to be able to generate the lead, create notifications, test to make sure requirements and conditions are met. You can extend Gravity Forms using hooks. If you need something custom developed by a PHP programmer, please post the job in our Job Forum.

    Posted 11 years ago on Wednesday June 20, 2012 | Permalink
  8. Hey David,

    I have a similar question. I am using different $_GET urls for each form. To give you an idea of what I am trying to accomplish, it is an action very similar to what is going on here: http://www.weddingchicks.com/freebies/invitation-suites/mason-jar-invitation-suite/

    Possible with hooks like the ones you linked to?

    Posted 11 years ago on Sunday July 8, 2012 | Permalink
  9. David Peralty

    awennerlind - Can you give me more information? You are using Gravity Forms redirect with query strings to another form and then using $_GET to pull date from the URL in another Gravity Form?

    Posted 11 years ago on Monday July 9, 2012 | Permalink
  10. David,

    You lost me at query strings. Haha. I'm a bit of a newbie to all of this, but what I think is going on on the site I linked to is that they are somehow using your forms to easily make forms with a different form actions for each one. For example, in the code below I am trying to use $GET to pass the data entered in the form through code on the page index.php. I have assigned each option a variable ie "TextColor," "FIrstLine" "SecondLine" etc using name="". I would want the ability to edit these names in the form and the form action for each form I just wasn't sure to go about doing that.

    <form enctype="multipart/form-data" form action="index.php" method="get">
    </select>Text Color<select name="TextColor">
    	<option value="Pink">Pink</option>
    	<option value="LightPink">Light Pink</option>
    	<option value="Yellow">Yellow</option>
    	<option value="Blue">Blue</option>
    </select>
    First Line <input type="text" name="FirstLine" />
    Second Line <input type="text" name="SecondLine" />
    Third Line <textarea rows="10" cols="30" name="ThirdLine" />
    </textarea>
    <input type="submit" value="Submit" />
    </form>

    Thanks!

    Posted 11 years ago on Monday July 9, 2012 | Permalink
  11. Also, I guess it would help if you knew that I am trying to use the GD Library and ImageMagick to return a final composite image using the form's inputted data. Thanks!

    Posted 11 years ago on Tuesday July 10, 2012 | Permalink
  12. David Peralty

    Gravity Forms doesn't let you change where a form is submitted. The easiest way to do this with no coding would be to use conditional logic. You could have images in HTML blocks remain hidden until an option is selected. So someone selects pink, and the pink image html block shows. You could use absolute positioning to stack transparent PNG's.

    That would probably be the easiest way to do this. As for query strings, if you go to your form, click on the title and go to confirmation, you can see you can select Redirect. You can choose to redirect it to another page, or to the same page, and then check off Pass Field Data Via Query String. Then you can do your name={name:8} or whatever the field name is.

    Posted 11 years ago on Tuesday July 10, 2012 | Permalink