You need to use the Document Object Modle. You have different methods with JavaScript to create and insert elements into the DOM. As for example:
var element = document.createElement('p');
var body = document.body;
body.appendChild(element);
With that code you are creating an element, then appendig it into the body. And that is pure JavaScript. You could use Mootools or jQuery, and It is goign to be simpler. But JavaScript doesn't work like PHP for example, where you can use the variables mixed up with the HTML.
And if you want to trigger the function from the HTML you need to bind thtat function to an event. For example clicking on a link would be.
HTML
<a href="#" id="button"> Click Here </a>
JS
var b = document.getElementById('button');
b.click = function(){
GetFeedback();
}
GetFeedback(which should begetFeedbackas it's not a constructor) withvar. (And I'm going to just assume all of the other variables are declared). It sounds like you're looking for some form of HTML interpolation which doesn't exist. The closes would bedocument.writecalls which are ugly.