Javascript, new window

deicistdeicist Manchester, UK
edited November 2005 in Internet & Media
Hi all, I've just started dabbling in javascript and basic web design, and I'm trying to do something for a project I'm working on but can't figure out how to do it. What I want to do is open a new window from a script, but pass a string to the open window function and have that string be the html source of the page. ie: I want a function that when called with:

openwindow("< h t m l ><h e a d >< b o d y >< a h r e f = 'http://google.com''>Google&lt; / a >< / b o d y >< h e a d >< h t m l >")

opens a new window with a link to google in it.

can anyone give me some pointers?

edit: spaces added to stop the html being parsed...grrr...

Comments

  • deicistdeicist Manchester, UK
    edited November 2005
    heh, never mind, I figured out how to do it.... then discovered you can't use javascript on the site I wanted to do this on anyway. Doh.
Sign In or Register to comment.