• Hi –
    I cannot find any documentation that shows whether or not this is possible, but I would love to figure out how to do it:

    I have a form that successfully interacts with salesforce. This form contains a hidden field named productId. What I would like to do is utilize this one form instance on all of my product pages, and have the hidden productId field get populated on page load of the product in question.

    Is there currently support, or can there be support for a variable being passed in the shortcode to the hidden fields? i.e.

    [salesforce form=”1″ productId=”00001234″]

    does anyone else have a need for this? if it’s just me i’ll find another way.

    https://www.ads-software.com/extend/plugins/salesforce-wordpress-to-lead/

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter bernbe01

    (@bernbe01)

    i guess if i was to take a different approach:

    in the form editor, can i set the “value” column to a php string or a get/post variable?

    Thread Starter bernbe01

    (@bernbe01)

    i did get it working by hardcoding the product values into the salesforce.php file

    look for the line:
    } else if ($input['type'] == 'hidden') {

    and replace the clause with

    if ($id === 'Product_Link__c') {                                                        $content .= "\t".'<input value="'. 'https://' . $_SERVER["SERVER_NAME"]  . $_SERVER["REQUEST_URI"] .'" id="sf_'.$id.'" class="w2linput hidden" name="'.$id.'" type="hidden"/><br/>'."\n\n";
                            } else {
                                    $content .= "\t\n\t".'<input type="hidden" id="sf_'.$id.'" class="w2linput hidden" name="'.$id.'" value="'.$val.'">'."\n\n";
                            }
                    }

    Thread Starter bernbe01

    (@bernbe01)

    i should have been more specific. the line above is specific to my salesforce/wordpress setup.

    i have a custom lead field in salesforce name Product_Link which i post to using the variable Product_Link__c

    in the code snippet above, when outputting the html of the form, php populates the value of this hidden field with the current server uri

    when a salesperson in salesforce is managing the lead, they can see what the page was being looked at when the contact form was activated.

    i would also be interested in making this dynamic to generate, and very interested in adding date field support with better error correction

    Plugin Author Nick Ciske

    (@nickciske)

    Sorry, not in the current version.

    I’ll mention the request and maybe it’ll make the next release.

    Thread Starter bernbe01

    (@bernbe01)

    I also integrated a date selector, which would be much easier to deploy if there was an option to do a “date”

    it’s storing as a text value, and is currently inserting into salesforce correctly, but it is hackish.

    someone with more skills than me could integrate that permentantly if it made sense

    https://www.brentjess.com/products/weddingbands/the-original-custom-fingerprint-ring-interior-wrap-print/

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘[Plugin: WordPress-to-lead for Salesforce CRM] How to Field Question’ is closed to new replies.