-
Author
-
November 19, 2014 at 19:42 #35985topdogParticipant
I have set up a Gravity Form to take new user registration instead of the default BP form. Everything is working fine except the field values from the homepage registration form and modals are not passing values to my G-form.
I went into /general-register-modal.php and /home-register-form.php to get the field names and have entered them into G-form which is working properly. The issue I’m having is passing the information from your forms to G-form.
It can be done via GET by adding the field parameters to the URL when users are redirected to the new G-form registration page (example: http://mysite.com/register?username=sweetdate) or it can be done using PHP using code similar to code below:
COPY CODE<?php add_filter("gform_field_value_date", "populate_date"); function populate_date($value){ return "10/10/2010"; } ?>
In the code above the variable ’10/10/2010′ is added to the G-form field ‘Date’. The code is working but in the example above the date field is a constant and I need the variable information that a user enters in the Username, Name, Email & Password fields.
My problem is that I’m a PHP newbie and can’t figure out how to get the values from your registration forms into the code above.
I also tried using the GET method to pass variables via the URL and didn’t even get close with that method.
Hoping you can help.
November 26, 2014 at 00:01 #36615topdogParticipantHey guys, it’s been 6 days since my support request. Does anyone have any assistance they can provide on this?
November 26, 2014 at 00:28 #36627AbeKeymasterHi, sorry for the late reply.
You will have to edit those templates from the theme home-register-form.php and general-register-modal.php and change the field names with the names as in your gravity forms like name=”signup_username” or name=”field_1″ so they will past the POST values to your page. If you are using GET then change that in your form, see method=”post” to method=”get”
Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution---
@ SeventhQueen we do our best to have super happy customers. Thanks for being our customer.November 28, 2014 at 05:53 #36941topdogParticipantAbe,
Can you give any guidance on how to past the POST values to my page. That’s what I’m having issues with. I’ll settle for guidance on the GET method instead if you prefer.
December 3, 2014 at 12:49 #37457AbeKeymasterhi, I told you in my last response: “…If you are using GET then change that in your form, see method=”post” to method=”get””
Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution---
@ SeventhQueen we do our best to have super happy customers. Thanks for being our customer.December 3, 2014 at 13:06 #37464topdogParticipantAbe, I fixed this issue already. I’m sorry, I thought I had marked this thread as resolved.
December 3, 2014 at 13:07 #37465AbeKeymasterok, great
have a nice day. Closing this topic then
Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution---
@ SeventhQueen we do our best to have super happy customers. Thanks for being our customer. -
AuthorPosts
The topic ‘Pass Field Values To Gravity Form On Registration’ is closed to new replies.