Hi guys,

I am working on my javascript to create the text in the html document. I want to know how I can write the text in html?

I tried to use this:

Code:
var test=myFunction();

function myFunction(test)
{
  var keycode;
  if (window.event) keycode = window.event.keyCode;
  {
    document.write("hello! this is a test");
  }
}


It did not write the text in the html. I tried to find the solution but i can't.

Can you please help me?

thanks in advance.