AnsweredAssumed Answered

Defining form value via script

Question asked by 6f80f6e4d6a0b4a4c88c33e6ee52658cae36aee7 on Feb 16, 2015
Latest reply on Feb 19, 2015 by 6f80f6e4d6a0b4a4c88c33e6ee52658cae36aee7
We are working on our new website which is on drupal. 

We are using a module on the drupal platform to bring over the data from 
our webforms into Marketo. 

We are using one form for all our content with one difference being that we have a different field value for Marketing Detail which we want to populate. This field will drive the separate programs for each peice of content.


Please see script below. I've checked the field api name and it is 
Marketing_Detail__c . Currently the value for Marketing Detail (in this case:fact sheet nuix collector 
suite) is nt coming over to Marketo. So we cannot differenciate one content download from the other.

We want to avoid creating mutiple forms with hidden values for each peice of content.


<script src="//app-sjf.marketo.com/js/forms2/js/forms2.js"></script> 
<form id="mktoForm_2128"></form> 
<script> 
MktoForms2.loadForm("//app-sjf.marketo.com", "957-JZE-399", 2128, 
function(form){ 
form.vals({ "Marketing_Detail__c":"fact sheet nuix collector 
suite"}); 
form.onSuccess(function(values, followUpUrl){ 
location.href = "/download/fact sheet nuix collector suite"; 
return false; 
}); 
}); 
</script> 

Please let me know if you need any more info. 

Regards 
Chris. 

Outcomes