function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
iKnowledgeiKnowledge 

CMSForce WebForm Question

Hi Everyone, I'm hoping that someone has worked wtih the CMS Force app in this way and can point me in the right direction.

 

I am setting up a registration page and have a content item that is the registration form information and another content item that is a link to records in a custom object called Classes.  

 

When someone clicks on a register now link, I would like to prepopulate the class information in the form content item.

 

Any ideas on how to go about this? I feel like it is something really obvious that I'm missing.  

 

Thanks for  your help!

 

JoAnn

David VPDavid VP

You can use url parameters to prefill the form (which you can drive from an email template with merge fields for example).

 

 for example :

 

http://yoursite.force.com/page?id=xxxxx&FirstName__c=John&LastName__c=Doe

 

 This is also explained on page 22 of the usage guide :

https://sites.secure.force.com/appexchange/content?contentId=a0K30000001MU6xEAG

 

 

I don't know if this will cover your use case but that's all you can do for now as far as pre-filling is concerned.

 

Hope this helps,

 

David

AROD12AROD12

Hi David how does it work when you want to use a CMSforce landing page to multiple contacts at a time; all associated as campaign members to a single campaign?

 

When I try your example (video) I can only do one contact as the web form editor only allows one on Contact ID and won't allow a reference field "{!Contact.Id}".

 

https:XXXX/apex/page?pageid=X"CampaignID"X&First_name__c={!Contact.FirstName}&Last_name__c={!Contact.LastName}&ContactID={!Contact.Id}

 

This is my guess on the URL but I get an error message:

 

Attempted to add a campaign member where either the member id 'null' or the campaign id '701A00000001JMc' is null.

David VPDavid VP

The merge fields I'm talking about are actually in the email template you use to invite your contacts (or leads) ... not in the Webform itself.

The trick is to provide a Contact Id field in your Web Form and then prefill it via the url by generating a contact-specific url in your email invites.

AROD12AROD12

Thanks David for coming back to me so quickly.

 

I definitely get what you mean by pre filling using the URL via the email invite.  However what would be the correct URL make up. 

 

I get it right to the point where I can prefill the first and last name (in blue) but I can't replace the hidden ContactID field (in red).  All it does is replace the first & last name from the Contact/campaign member that was originally used in web forms hidden contactID field when I hit the submit button.

 

/apex/page?pageid=a0AA0000002iBR2MAM&First_name__c={!Contact.FirstName}&Last_name__c={!Contact.LastName}

&ContactID={!ContactID}

Does the {!ContactID} need to be a reference e.g. ContactID__r.

 

Many thanks in advance.

David VPDavid VP

It needs to be :

 

&ContactId={!Contact.Id}

 

(notice the . )

 

AROD12AROD12

BRILLIANT it worked!!  

 

Thanks for the second pair of eyes.

 

You're a legend David VP

FrankTNVFrankTNV

I am currenlty figuring out CMSForce, and wondering if the following is possible:

 

I would like to make a webform where customers can register name and e-mailadres and are being placed under a campaign in SalesForce automaticly.

There will be two type of customers registering:

1. Excisting contact persons, who have to be noticed as allread-in-the-system

2. New contact persons, who will create a new contact automaticly (this is easy in CMSForce)

 

Can anybody advise/help ?