Iframe and its content - problem

Iframe and its content - problem

Hi,
I'm stuck with the irame and jquery.
This is what i want to do:
I create iframe:

      
var ifr_tag = jQuery("<iframe></iframe>");
ifr_tag.attr("id","iframeid");
ifr_tag.attr("frameborder",0);

textarea1_div.append(ifr_tag);

The iframe creation is working with the id and frameborder as well.

Then what i want to do is to modify head:


      var head_tag = jQuery("iframe#iframeid > html > head");
      head_tag.attr("xmlns","http://www.w3.org/1999/xhtml");

The above doesn't work for some reason, why is that?

Then also adding the content to the body tag of the iframe.
However, it seems nothing can be modified within body as well.

What am i doing wrong?

thanks, for any help