Passing a custom value to a Nanacast-hosted product offering via the API

Article Details
URL: http://support.nanacast.com/index.php?_m=knowledgebase&_a=viewarticle&kbarticleid=162
Article ID: 162
Created On: 02 Apr 2010 12:51 PM

Answer

We support up to 30 user-defined custom fields.  You can add one of your 30 user-defined custom fields to your product/membership. This would have the API name of "u_custom_1". You should make it a hidden field. You can then pass in that into the embedded form on your website by appending it to the JavaScript embedded code URL. "&u_custom_1=12345"

What you'll need to do is create a new page on your own website and copy/paste the embedded form code on to the page via the Create Button link, and then you can append the variables onto the JavaScript src URL.

The system will catch this and add it as the hidden field value. Note that it only works for your own sales pages and not those hosted by Nanacast:

Secret Fields are never shown on the actual form but are automatically added to the client's record when the form is submitted. Secret fields can be useful if you want to have a predetermined secret code in the notification email sent to an order fulfillment house as an additional security measure so the fulfillment house knows it is a legitimate order.

Hidden fields are placed on the form as a hidden HTML input tag. Hidden fields can be useful if you want to pass in variables to the embedded form. You can do this by appending variables onto the script src after creating your embedded form code for your website. This can also be done to all other types of fields on the form (except for check boxes because their values cannot be passed in). The field name of a particular variable is the "Field Name for Advanced API", which can be found when editing each field. For example, appending '&u_email=joe@example.com' onto the end of the script src URL will populate the email field with that variable. 

You can also pass variables in via text links (also created when using the Create Button feature)


Additional keywords: integration