need some more help...

D

D2CAD

function productprice(img,titel,path,bestand1) {
features =
'toolbar=yes,location=no,directories=no,status=no,menubar=no,' +
'scrollbars=yes,resizable=no,width=680,height=600'
dlg = window.open ("","",features)
dlg.document.write ("<HTML>")
dlg.document.write ("<HEAD>")
dlg.document.write ("<TITLE>Try & Buy applicatie :
",titel,"</TITLE>")
dlg.document.write ("<script>")
dlg.document.write ("function showText()")
dlg.document.write ("theText =
window.textFile.document.body.innerHTML.replace(/\<[^\>]+\>/gm, '');")
dlg.document.write ("}")
dlg.document.write ("</script>")
dlg.document.write ("</HEAD>")
dlg.document.write ("<link rel=stylesheet href='d2cad.css'
type='text/css'>")
dlg.document.write ("<body onload='window.textFile.location =
\"",bestand1,"\"'>")
dlg.document.write ("<CENTER><H3>",titel," </H3></CENTER>")
dlg.document.write ("<CENTER><img src='",img,"'></CENTER>")
dlg.document.write ("<BR><BR><BR><FONT size='2'>")
dlg.document.write ("<iframe id='textFile' onLoad='showText()'
align=center width=640 height=240></iframe>")
dlg.document.write ("<FORM><CENTER><INPUT type='button' value='Close'
onClick = 'self.close()'></CENTER></FORM>")
dlg.document.write ("</BODY>")
dlg.document.write ("</HTML>")
}

This script creates a new window, but not the contents of the
bestand1-file...

<a href="#" onclick="productprice('plaatswand03.jpg','Plaatswand','download/','plaatswand.txt')">test</a>

JW suggested to use opener.showtext(), but I am new at this, so I need
some more explenation or examples...
Thanks
 
S

steve stevo

what is the html code of the opened window ?


D2CAD said:
function productprice(img,titel,path,bestand1) {
features =
'toolbar=yes,location=no,directories=no,status=no,menubar=no,' +
'scrollbars=yes,resizable=no,width=680,height=600'
dlg = window.open ("","",features)
dlg.document.write ("<HTML>")
dlg.document.write ("<HEAD>")
dlg.document.write ("<TITLE>Try & Buy applicatie :
",titel,"</TITLE>")
dlg.document.write ("<script>")
dlg.document.write ("function showText()")
dlg.document.write ("theText =
window.textFile.document.body.innerHTML.replace(/\<[^\>]+\>/gm, '');")
dlg.document.write ("}")
dlg.document.write ("</script>")
dlg.document.write ("</HEAD>")
dlg.document.write ("<link rel=stylesheet href='d2cad.css'
type='text/css'>")
dlg.document.write ("<body onload='window.textFile.location =
\"",bestand1,"\"'>")
dlg.document.write ("<CENTER><H3>",titel," </H3></CENTER>")
dlg.document.write ("<CENTER><img src='",img,"'></CENTER>")
dlg.document.write ("<BR><BR><BR><FONT size='2'>")
dlg.document.write ("<iframe id='textFile' onLoad='showText()'
align=center width=640 height=240></iframe>")
dlg.document.write ("<FORM><CENTER><INPUT type='button' value='Close'
onClick = 'self.close()'></CENTER></FORM>")
dlg.document.write ("</BODY>")
dlg.document.write ("</HTML>")
}

This script creates a new window, but not the contents of the
bestand1-file...

<a href="#"
onclick="productprice('plaatswand03.jpg','Plaatswand','download/','plaatswan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,774
Messages
2,569,598
Members
45,149
Latest member
Vinay Kumar Nevatia0
Top