DNN Forums

Ask questions about your website to get help learning DNN and help resolve issues.

Survey Monkey Variable Help

 3 Replies
 2 Subscribed to this topic
 40 Subscribed to this forum
Sort:
Author
Messages
New Around Here
Posts: 2
New Around Here

I need to collect the current page as a variable and then pass that variable into a link that goes to Survey Monkey.  Here's how it used to work in our SharePoint environment.

document.getElementById('__smlink').href = "https://www.surveymonkey.com/r/myform?url=" + window.location.pathname

What do I need to do in order to get that to work in DNN?  Is there a script or something I need to get the URL to populate with this information?

 

 

Veteran Member
Posts: 1246
Veteran Member
MVP
MVP
You're an MVP!

You should be able to get something similar to that working in DNN, presuming that your page names are in the right form as evidenced by the URL.

If the link is in a Text/HTML module, you could use one of DNN's replaceable tokens (in this case [Tab:TabName]) to insert the page name appropriately.

If the link is built into your skin, you can use some ASP to call a tab method to place the page name appropriately. I think that there is a method to return the current tab's name:

                     <%= Server.HtmlEncode(PortalSettings.ActiveTab.TabName) %>
 

New Around Here
Posts: 2
New Around Here

Hi Joe,

I'm still struggling with this.  I would like to use this in the footer so whenever a user clicks on the link, it sends them to survey monkey with the current page as a variable.  Is that possible in DNN?  If so, please provide the URL nomenclature.  I tried the following...didn't work.  Could I do this in an HTML module or footer link?  I don't have access to the skin scripting.

https://www.surveymonkey....#91;Tab:TabName]

Growing Member
Posts: 51
Growing Member
Joe's suggestion is for use inside an HTML module.

If you want it to appear in the footer then you'll need a skin that has a panel in the footer to allow placing an HTML module there.

DNN Tokens list - https://docs.dnncommunity...nt-tokens/index.html

These Forums are for the discussion of the open source CMS DNN platform and ecosystem.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. If you have (suspected) security issues, please DO NOT post them in the forums but instead follow the official DNN security policy
  2. No Advertising. This includes the promotion of commercial and non-commercial products or services which are not directly related to DNN.
  3. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  4. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  5. No Flaming or Trolling.
  6. No Profanity, Racism, or Prejudice.
  7. Site Moderators have the final word on approving / removing a thread or post or comment.
  8. English language posting only, please.

Would you like to help us?

Awesome! Simply post in the forums using the link below and we'll get you started.

Get Involved