Embedding your Ratings page into an iframe on your website is an optional feature. The pros to doing this to provide your customers with a more integrated experience with your website. If you choose not to embed your ratings in an iframe on your website, you may use the default page which does not require any further configuration.

This process does require a bit of software development and HTML knowledge. The easiest way to do this is simply embed the call to the ratings page, with your organization ID, within the iframe tags. You need code on the top level page (the one that hosts the iFrame) which will pass the parameters from the main page to the iframe.

Your Ratings page URL is formatted the following way: https://portal.[ServerName].teamsupport.com/rating.aspx?OrgName=xxxx . Simply replace “xxxx” with your Organization ID which can be found in your account under Admin-> Account Settings -> Organization ID.

When For example, if your ratings page is at “http://www.acmeco.com/rating”, when a user clicks on a Rating selection on an e-mail they would attempt to go to

http://www.acmeco.com/rating.aspx?organizationid=11111&ticketid=22222&Rating=1&CustomerID=33333

The code on the page needs to change the iframe url so it reads

https://portal.[ServerName].teamsupport.com?organizationid=11111&ticketid=22222&Rating=1&CustomerID=33333

There are multiple ways to do this, but we’ve provided a sample below for JavaScript.

Don’t forget to tell TeamSupport where your iframe page is located. The setting for this is called “External URL” and can be found on the Agent Ratings Tab.

Now when an e-mail is sent to a customer asking for Rating feedback, the link will point towards your iframe embedded Ratings page!

JavaScript Code Sample

JavaScript is very sensitive to capitalization, so make sure that OrganizationID and TicketNumber are capitalized correctly.

Note: You’ll need to replace “xxxx” with your organization id.

<html>
<head>
     <title>Portal Example</title>
     <script language="javascript" type="text/javascript">
     function pageLoad() {
     var ticketID = getQueryParamValue("TicketID", window.location);
     var organizationID = getQueryParamValue("OrganizationID", window.location);
     var rating = getQueryParamValue("Rating", window.location);
     var customerID = getQueryParamValue("CustomerID", window.location);

     var url = "https://portal.[ServerName].TeamSupport.com/rating.aspx?OrganizationID=" + organizationID + "&TicketID=" + ticketID + "&Rating=" + rating + "&CustomerID=" + customerID;

     var frame = document.getElementById("frmPortal");
     frame.setAttribute('src', url);
     }

     function getQueryParamValue(name, url) {
     params = url.search.substring(1);
     name = name.toLowerCase();
     param = params.split("&");
     for (i = 0; i < param.length; i++) {
     value = param[i].split("=");
     if (value[0].toLowerCase() == name) {
     return this.unescape(value[1]);
      }
   }
} 
</script>
</head>

Need more help with this?
Customer Support

Was this helpful?

Yes No
You indicated this topic was not helpful to you ...
Could you please leave a comment telling us why? Thank you!
Thanks for your feedback.