+ Start a Discussion

Web-to-lead and Campaign

Trying something that sounds simple but has been a headache so far... be gentle, I'm new at this.
All we want is a small form that sends info as a lead to salesforce - this form has a hidden Campaign_ID field.
First of all, when you generate the web-to-lead code it gives you the Campaign_ID and not the Campaign field as the one you should be sending to salesforce. We found out from salesforce that you actually have to use the "name" and not the "ID".
Everything works fine except for the auto-response rule that looks for the Campaign field to then send out an email with an attachment. We've tried "Campaign_ID", "Campaign" (name), with parenthesis, without parenthesis, and many other options - it just doesn't want to work.
Any suggestions? Anybody out there been able to do this? We've called salesforce and they've "escalated" the issue... just trying to get a faster answer to this...
Any help would be appreciated.
We found out from salesforce that you actually have to use the "name" and not the "ID".
This surprises me. As you noted, the generated form uses the Campaign_ID, and I am sure that the submittal to the Web-to-lead servlet uses this campaign id, not the name, for the generation of the lead.

That said, the campaign ID is not available to the auto-response rule.
I'd expect that you should use the campaign_id on the submitted form, but the campaign name in the auto-response rule.
We have implemented almost the same solution ... however our auto-response rule checks a different field -- not the campaign.
When you add a campaignID onto a web to lead form, the campaign number isn't actually stored within the lead record. What happens is that a new record is created in the CampaignMember object - the new compaign member record will contain the campaignID, and the LeadID of the lead record it's linked to.

I'm a bit confused by the statement that you have to use the campaign name - all of our web-to-lead forms use the campaignid, and it works fine.

If I understand what you want to do correctly, I think the only think you'll be able to do is create a custom field in lead, and then pass a value from your web-to-lead form into that custom field.  Then, write your auto-response criteria to look for the value in the custom field.

Take care...

You're absolutely right. We have gotten it to work.
The true issue is that you have to:
  • Use "Campaign_ID" on the web-to-lead form
  • Use "Campaign Name" on the auto-response rule
  • Remember to add: <input type="hidden" name="member_status" value="responded" /> on the web-to-lead form.

Thanks for the reply. Everything is working just fine now.

This might have just been miscommunicted... Name on auto-response rules and ID on web-to-lead form.
Hi rblino

There's an appexchange called Mass Converter, it may do something similar to what you're tryign to achieve.

Are your web2lead via email or via a webpage?

i've gotten the web2lead via email to work however having a few problems with trying to get a web link from to prepopulate the web2lead page.

any clueS?



Hi rblino,

Have you heard about the FormVester AppExchange application?
This application could help you easily generate leads from your website forms into salesforce.

If you already have your form ready on your website, you don’t need to replace it by a new one generated by the salesforce standard web-to-lead form functionally.
Just pastes a snippet code into your website, then, quickly map your form and you will be able to generate new leads from your existing online form directly into salesforce.

This application efficiently manages any king of field including hidden ones. And best of all, this application is free! Give it a try, look for FormVester in the AppExchange, this could be the solution you were looking for! Hope it can help!

Hi there -  I am hoping you can help me... I am a new SF admin and I am trying to setup the web to lead functionality. I can generate the web to lead form and put it in a landing page. The leads are received by SF no problem. What I cant seem to figure out is how to track leads coming from DIFFERENT landing pages... I have tried adding the "web source" , "campaign" , "correlation data" fields when creating the web to lead form -- but those areas are just left blank on new leads that come in. I called SF support and got no help at all. I am really hoping to figure this out. Seems simple, but I just cant get it to work :( I would love some guidance. THanks!!

You should take a look at this thread, you could find peices of solution to your problem:

Also, maybe you would be interrested in using PageVester. It's an appexchange application for landing pages creation. It is really easy to use and also it is totally integrated with Google AdWords and Google Website Optimizer:

PageVester in the AppExchange


Hope I could help!

Message Edited by Seb on 06-19-2008 09:35 AM

Message Edited by Seb on 06-19-2008 09:36 AM

Message Edited by Seb on 06-19-2008 09:37 AM