Loading Get Satisfaction widget dynamically?
I'm trying to add the GetSatisfaction after the page is loaded in order to improve performance. I'm using jQuery and loading the .js via ajax after the page has finished loading. However, when I call GSFN.feedback from an external script file, the page redirects. It seems like this happens whenever I call GSFN.feedback from an external script, and I'm not sure how to resolve it. Any help would be appreciated.
1
person has this question
I have this question, too!
Tell me when someone answers.
The more people who ask this question, the more it gets noticed.
The more people who ask this question, the more it gets noticed.
The best answer from everyone
-
Hi USSR Lives On,
GSFN.feedback uses document.write to put it's content into your page. If that gets called outside of the initial html load (as in your case), it rewrites the whole document.
Obviously, that sucks; We've got support in another of our js embeds for specifying a container to write our html into, and i will transplant that support into the feedback widget code.
Then you should be able to specify:
GSFN.feedback('http://', {container:'my_id'});
I would expect this to get deployed over the next couple of days.
Thanks for the question,
Scott
The company and 3 other people say
this answers the question
-
Inappropriate?Hi USSR Lives On,
GSFN.feedback uses document.write to put it's content into your page. If that gets called outside of the initial html load (as in your case), it rewrites the whole document.
Obviously, that sucks; We've got support in another of our js embeds for specifying a container to write our html into, and i will transplant that support into the feedback widget code.
Then you should be able to specify:
GSFN.feedback('http://', {container:'my_id'});
I would expect this to get deployed over the next couple of days.
Thanks for the question,
Scott
The company and 3 other people say
this answers the question
-
Great, that's perfect. Thanks! -
Inappropriate?Hey,
Getting a bug ("trace is not defined") in your code in Firebug that seems to be related. It's on line 19 of feedback.js, which is the second line of this block:
if(this.tab_options.container) {
trace(this.tab_options.container)
var container_el = this.gId(this.tab_options.container);
trace(container_el);
container_el.innerHTML = this.tab_html + this.overlay_html;
}
Not sure what this is related to, but just in case, here's my code:
var tab_options = {};
tab_options.placement = "right";
tab_options.color = "#0075B8";
tab_options.container = 'feedback_widget';
GSFN.feedback('http://getsatisfaction.com/hellomovies/feedback/topics/new?display=overlay&style=idea', tab_options);
Any ideas? -
Whoops... my fault. go ahead and remove that line. I'll fix it momentarily for everyone else. -
Great! It works perfectly now. Thank you for the prompt response. -
Inappropriate?What was the resolution for this topic? Is it there an option to load the widget to a specific container with jQuery yet? I'm having the same issue as the person from the first comment.
Thanks! -
Inappropriate?Hey,
It should work if you just specity the extra "container" parameter in the tab options object. e.g.
var tab_options = {};
tab_options.placement = "right";
tab_options.color = "#0075B8";
tab_options.container = 'feedback_widget';
GSFN.feedback('http://getsatisfaction.com/hellomovies/feedback/topics/new?display=overlay&style=idea', tab_options);
Stan
Loading Profile...




CHAMP
