A query string is something you can add to the end of the URL your form lives at, e.g. www.example.com/formid?foo=bar
Primarily, query string values are used to pre-fill values in the form. The general format is that the first bit is the name of the form field, followed by an equals sign and then whatever data you wish to pre-fill that form field with. ActionTag assumes US formats for all fields (phone, postal code, amounts, etc.).
The way to add these onto a form is that the first one needs to use a question mark, and other subsequent ones use an ampersand, e.g. www.someurl.com/formid?sourceid=12345&ms=top-nav
Avoid using Query Strings with PII
It is not advised to put PII in your URL via query strings, as that can expose personal information to services like Google Analytics. SmartLinks should be used in Targeted Email instead of query strings.
Form Fields
The following are available visible fields to be filled via Query Strings:
Name | Parameter | Sample | Notes |
---|---|---|---|
Address Line 1 | add1 | add1=1250+Hancock+St. | |
Address Line 2 | add2 | add2=Ste.+202 | |
Additional Contribution Value | AdditionalContributionValue | AdditionalContributionValue=25 | Prefill the additional contribution amount on event forms only |
Amount | am | am=5 | This sets the default amount on a contribution form. |
Amount Options | amtOpts | amtOpts=3,5,20.16,50,100 | This sets the amount button options on a contribution form. To select a particular contribution amount upon loading the form, use the ‘am’ query string. |
City | ci | ci=Boston | |
Cover Costs | CoverCosts | CoverCosts=true | If the Cover Costs checkbox is enabled on the Contribution or Ticketed Event form, this query string checks that checkbox, adding the Cover Costs amount (configured in Online Actions) to the contribution amount selected by the donor. |
Currency | currency | currency=EUR | Works for Contribution forms that support international currencies; will not work for Ticketed Event forms • Valid values include USD , GBP , CAD , and EUR • Can be used in combination with am and amtOpts • If currency is passed without am or amtOpts , passed currency will be selected and amounts on form will be converted• If currency is passed with amtOpts , passed currency will be selected and amount options will be offered as passed• If supporter then selects a new currency, amounts will be converted to selected currency • If currency is passed with am , passed currency and amount will be selected |
Email Address | em | [email protected] | |
Email Signup | ae | ae=true or ae=false | |
Employer | ep | ep=ACME Industries | |
Ethnicity | ethn | ethn=1,2,3 | 1 • Afghani 2 • Arab 4 • Bangladeshi 5 • Bhutanese 6 • Brazilian 7 • Chinese 8 • East African 9 • Filipino 10 • Haitian 11 • Hmong 12 • Indo Carribean 13 • Lao 14 • Nepali 15 • Pakistani 16 • Somali 17 • Sri Lankan 18 • Tibetan 19 • Vietnamese 20 • Latino 21 • Arabian 22 • Armenian 25 • Indian 26 • English (British) 27 • French 28 • German 30 • Irish 31 • Italian 32 • Japanese 34 • Polish 35 • Native American 36 • Scottish 37 • Swedish 39 • Samoan 40 • Korean 44 • Czechoslovakian 45 • Norwegian 46 • Dutch 47 • Greek 48 • Hungarian 50 • Russian 51 • Ukrainian 52 • Welsh 54 • Bulgarian 55 • Burmese 56 • Cambodian 57 • Estonian 58 • Ethiopian 59 • Finnish 60 • Icelandic 61 • Indonesian 64 • Latvian 65 • Lithuanian 66 • Malaysian 67 • Manx 68 • Portuguese 71 • Swiss 72 • Thai 73 • Turkish 74 • Yugoslavian 75 • Danish 77 • Hawaiian 78 • African American 82 • Hispanic 83 • Mixed Ethnicity 85 • Other 86 • Persian 87 • Yemeni 88 • Egyptian 89 • Morrocan 90 • Lebanese 92 • Jewish 93 • Chamorro 96 • Mien 97 • Bengali 98 • Chin 99 • Karen 101 • Mongolian 103 • Okinawan 104 • Singaporean 105 • Taiwanese 106 • Tongan 109 • Colombian 110 • Salvadoran 120 • Unknown 136 • Not Listed 137 • Tagalog 138 • Native Alaskan 142 • Pacific Islander |
Facebook Profile Url | fb | fb=http://www.facebook.com/JohnAdamsPresident | |
First Name | fn | fn=John | |
Gender | gen | gen=1,2,3 | 1 • Androgynous 2 • Female 4 • FTM 5 • Gender Fluid 6 • Gender Non-conforming 7 • Genderqueer 8 • Male 11 • MTF 12 • Non-Binary 13 • Prefer Not to Say 14 • Questioning 16 • Transgender 18 • Agender 20 • Bigender 21 • Butch 22 • Femme 23 • Gender Questioning 24 • Gender Variant 25 • Genderless 27 • Intersex 28 • Masc 29 • Neither 30 • Neutrois 31 • Non-Op 32 • Other 33 • Pangender 34 • Polygender 35 • Queer 36 • Transfeminine 37 • Transgender Female 38 • Transgender Male 40 • Transgender Person 42 • Transmasculine 49 • Two Spirit 56 • Not Listed 57 • Third Gender 58 • Cisgender Male 59 • Cisgender Female |
Home Country | c | c=US; c=CA | |
Home Phone | hp | hp=6175551234 | |
Is Organization | is_org | is_org=true or is_org=false | This checks or unchecks the checkbox to submit the form on behalf of an organization (not available on all form types). |
Is Recurring | r | r=true | Use true or false to set an exposed recurring checkbox to be checked or not, respectively. |
Last Name | ln | ln=Adams | |
Middle Name | mn | mn=Quincy | |
Mobile Phone | mp | mp=6175551234 | |
Occupation | oc | oc=President | |
Organization Email | org_em | [email protected] | This pre-fills the Organization Email input. |
Organization Name | org_name | org_name=People+for+Good | This pre-fills the Organization Name input. |
Organization Phone | org_hp | org_hp=2025551000 | This pre-fills the Organization Phone input. |
Postal Code | pc | pc=02144 | |
Preferred Language | preflang | preflang=2 | 1 • Bengali 2 • Cantonese 3 • English 4 • French 5 • Gujarati 6 • Hindi 7 • Japanese 8 • Korean 9 • Malayalam 10 • Mandarin 11 • Nepali 12 • Punjabi 13 • Russian 15 • Spanish 16 • Tagalog 17 • Tamil 18 • Tibetan 19 • Urdu 20 • Vietnamese 22 • Armenian 26 • German 28 • Italian 30 • Polish 31 • Swedish 32 • Samoan 36 • Norwegian 37 • Dutch 38 • Greek 39 • Hungarian 42 • Bulgarian 43 • Burmese 45 • Estonian 47 • Finnish 48 • Icelandic 49 • Indonesian 50 • Hebrew 51 • Lao 52 • Latvian 53 • Lithuanian 55 • Portuguese 57 • Thai 58 • Turkish 60 • Danish 62 • Amharic 63 • Arabic 64 • Croatian 65 • Somali 66 • Tigrinya 67 • Hmong 68 • Bosnian 69 • Creole 70 • Serbian 71 • Ukranian 72 • Bhutanese 73 • Chamorro 74 • Ilocano 75 • Karenni 78 • Swahili 79 • Tokelauan 80 • Kannada 81 • Marathi 84 • Hakha Chin 88 • Malay 89 • Mandingo 111 • ASL 112 • Not Listed 113 • Khmer 115 • Simplified Chinese 116 • Czech 119 • Iu Mien 120 • Sinhala 121 • Filipino 122 • Traditional Chinese 123 • Slovak |
Prefix | p | p=Mr | |
Pronoun | pro | pro=1 | 1 • She/Her/Hers 2 • He/Him/His 3 • They/Them/Theirs 4 • Xe/Xem/Xyrs 5 • (F)ae/(F)aer/(F)aers 6 • E/Em/Eirs 7 • Ey/Em/Eirs 8 • Per/Per/Pers 9 • Sie/Sie/Hirs 10 • Tey/Ter/Ters 11 • Ve/Ver/Vers 12 • Ve/Ver/Vis 13 • Ze/Hir/Hirs 14 • Zie/Zim/Zis 15 • She/Them/Theirs 16 • He/Them/Theirs 17 • Name Only 18 • He/She/They 19 • Any/All Pronouns |
Race | race | race=1 | 2 • Black or African American 4 • Native American 5 • Native Hawaiian 6 • Other 7 • Pacific Islander 10 • Hispanic 12 • Middle Eastern 17 • Multi-racial 25 • Not Listed 26 • Asian or Asian American 27 • White |
Recurring Commitment Amount | recurringAm | recurringAm=5 | This sets the default amount for a recurring commitment on a contribution form. |
Recurring Commitment Amount Options | recurringAmtOpts | recurringAmtOpts=5,10,15,25,35,50 | This sets the amount button options for a recurring commitment on a contribution form. |
Recurring Commitment Frequency | SelectedFrequency | SelectedFrequency=4 | 0 • one-time 1 • weekly 2 • every two weeks 3 • every four weeks 4 • monthly 5 • quarterly 6 • yearly 7 • twice a year |
Recurring Commitment Duration | SelectedDuration | SelectedDuration=3 | 1 • until end of year 2 • until the election 3 • until I contact you 4 • until this date |
Sexual Orientation | sexorient | sexorient=1,2,3 | 3 • Asexual 5 • Bisexual 6 • Demisexual 21 • Gay 9 • Heterosexual 22 • Lesbian 19 • Other 14 • Pansexual/Omnisexual 18 • Prefer not to Say 16 • Queer 25 • Not Listed |
SMS Signup | SmsSubscribeMobilePhone | SmsSubscribeMobilePhone=true or SmsSubscribeMobilePhone=false | |
Spouse Name | sn | sn=Abigail+Adams | Supported in version 7 only. |
State Province | st | st=MA | |
Suffix | s | s=Esq. | |
Twitter Handle | tw | tw=the_real_adams | |
Work Address Line 1 | w1 | w1=1600+Pennsylvania+Ave | |
Work Address Line 2 | w2 | w2=Oval+Office | |
Work City | wc | wc=Washington | |
Work Country | wco | wco=US; wco=CA | |
Work Email | we | [email protected] | |
Work Phone | wp | wp=2025551234 | |
Work Postal Code | wz | wz=20500 | |
Work State Province | ws | ws=DC |
Form Submission Data
There are also elements that may not be visible, but have to do with how the form submission data is entered into the database:
Name | Parameter | Sample | Notes |
---|---|---|---|
Attributed Contact ID | attr | attr=109418764 | The contribution or event signup will have the specified contact attribution (if applied to the submission of a Contribution or Event form). The contact ID should be the VANID for an Online Actions form, or the NGP ID for a version 7 form. Since a single contribution can have more than one contact attribution, you may use a comma delimited list of IDs to attribute the contribution to more than one contact, i.e. attr=109418764,109419268 |
Host Committee | ac | ac=VN96C3TBX36 | The contribution or event signup will have the specified contact attribution (if applied to the submission of a Contribution or Event form). The contact ID should be the VANID for an Online Actions form, or the NGP ID for a version 7 form. Additionally, the ac query string will prefill the Host Committee member selection on the published form (if the query string value matches that of a Host Committee member configured for the Event). |
Kiosk Mode | kiosk | kiosk=true | Using this query string parameter disables FastAction and ActionProfile integration. This is useful if the user is using a form on a tablet or laptop in a public place and do not want the submission information remembered on that device. Notably, if you configure one form to redirect to another form (what we refer to as secondary ask), the form fields on the second fom will not be pre-populated by the submission info from the first form. If you are launching the form with knowledge of who a contact is, kiosk mode does still allow you to prefill form fields using other query string values, e.g. fn=Michelle as documented above. |
Market Source | ms | ms=201409_fb_birthday_v1 | Can be used to track different ad buys to the same form to compare ROI |
Source Code ID | sourceid | sourceid=57 | Either adds or overrides the defined source code on the form. You must use the source code ID, not the source code name. |
Source Code Name | source | source=e2106nd | Will attempt to match to an existing source code of that name. If none exist, it will create a new source code of that name under the parent code of "Forms Auto-generated" which can then be moved elsewhere in your code hierarchy if needs be. V8 only. |
Quick Sign | quick | quick=true | Automatically submits the form and segues to the next action (thanks page, secondary ask, or an arbitrary other URL) if all the required fields are prefilled by either a query string value or ActionProfiles. This does not work for contribution or event forms. |
Social Network Referral | snw | snw=1 Facebooksnw=2 Twitter | Indicates whether the user was referred to the form from Facebook or Twitter. |