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.

Integrate CRM Software - Leadmaster?

  1. Is it possible to integrate our CRM software for Leadmaster ( http://leadmaster.com/ ) ? We would need to be able to add custom code such as this:

    Add the following text following the <head> element:
    <script type="text/javascript" src="http://www.logincrm.com/login/lm_wfi.js"></script>
    Add the following text to the <body> element:
    onLoad="lm_InitWebForm()"
    Add the following text to the <form> element:
    onSubmit="return lm_SubmitWebForm()"
    Add the following text immediately following the <form> element:
    <input type='hidden' name="lm_CompanyID" value="xxxx">
    <input type='hidden' name="lm_FormID" value="xx">
    <input type='hidden' name="lm_FormKey" value="">
    <input type='hidden' name="lm_FormResponsePage" value="http://www.website.com/thank-you/">

    Is this easy to do with Gravity forms?

    Posted 11 years ago on Tuesday June 26, 2012 | Permalink
  2. David Peralty

    Everything but the change to the form element could easily be done. I am sure there is a way to cheat that as well, but I don't know it off the top of my head. I would have to defer that to one of our JavaScript experts.

    The other changes you want would just be in your WordPress theme. You could wrap them in PHP to only show on your form pages, or create a custom template for pages with forms to have those elements.

    Posted 11 years ago on Wednesday June 27, 2012 | Permalink
  3. draney
    Member

    Since GForms generates the entire form, how would you add the hidden form fields to your form?

    I have tried following these instructions http://www.gravityhelp.com/documentation/page/Gform_field_input

    First I added 4 hidden fields to my form and used the code example to insert a customized hidden field in place of one of the GForm hidden fields. I was successful replacing the first field, but I am having trouble extending the code sample to add multiple hidden fields. Here is the filter code I tried in my functions file:

    add_filter("gform_field_input", "company", 10, 5);
    function company($input, $field, $value, $lead_id, $form_id)
    {
    	if ($form_id == 1 && $field["id"] == 13)
    	{
    		$input = '<input type="hidden" name="lm_CompanyID" value="7327">';
    		return $input;
    	}
    	if ($form_id == 1 && $field["id"] == 14)
    	{
    		$input = '<input type='hidden' name="lm_FormID" value="261">';
    		return $input;
    	}
    	if ($form_id == 1 && $field["id"] == 15)
    	{
    		$input = '<input type='hidden' name="lm_FormKey" value="">';
    		return $input;
    	}
    	if ($form_id == 1 && $field["id"] == 16)
    	{
    		$input = '<input type='hidden' name="lm_FormResponsePage" value="http://www.mysite.com/">';
    		return $input;
    	}
    }

    This broke WordPress. Can you help me make this work?

    Posted 11 years ago on Thursday October 4, 2012 | Permalink
  4. Rather than trying to modify the form, with a 3rd party service it's sometimes easier to use the gform_after_submission hook to send all your collected data to your third party service via URL or API. http://www.gravityhelp.com/documentation/page/Gform_after_submission

    Posted 11 years ago on Thursday October 4, 2012 | Permalink