I am trying to pass in a specific Picklist value that would be the default value for any Lead records created via the Web-to-Lead HTML form (integrated into Wordpress directly, no plugin used).

The Lead field is the default field "Lead Source" and this is the code I am trying to use in the servelet head:

<input type=hidden id="LeadSource" name="lead_source" value="Web-to-Lead">

The Bottom post at this Salesforce Forum link seems to suggest that I would need to find the multi-char string Id of the field but when I dig into setup, it does not appear that fields are assigned that kind of Id (e.g. 00QU000000a9cEl)

However, my Web-to-Lead form tests pass in all the correct values, except the value I am trying to pass in.

Why is this value failing to pass into the Lead Source picklist field?

1 Answer 1


As I recall the wordpress salesforce plugin was messing up the Org Id, so that contributed to this specific issue, but aside from that, the correct field input to use is the field 'id' as defined in the generated HTML from salesforce in this snippet:


When clicking on the field's 'Edit' link in Salesforce Admin/Setup, the field's id is included in the url string, but that id is only necessary for custom fields and is provided in the generated HTML from Salesforce anyway.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .