document.write with CoolTips, OverLib or is there something better??

W

wesley_snipes1

Hello. Anyone feel free to help me as it would be greatly appreciated.
I am attempting to dynamically create tooltips using the likes of
CoolTips, OverLib or anything else out there that will do. I have been
unable to get code like this to go:

<script type="text/javascript">

document.write('<a href="javascript:;" onMouseOver="return
coolTip('CSSCLASS,TEXTFONTCLASS,\'fontClass\',FGCLASS,\'fgClass\',
BGCLASS,\'bgClass\',STICKY,CAPTIONFONTCLASS,\'capfontClass\',
CLOSEFONTCLASS, \'capfontClass\', CAPTION,\'<I>CSSCLASS</I> Example
#1\', SHADOW', WIDTH, 400, WRAP,
CSSCLASS,TEXTFONTCLASS,'fontClass',FGCLASS,'fgClass',
BGCLASS,'bgClass',STICKY,CAPTIONFONTCLASS,'capfontClass',
CLOSEFONTCLASS, 'capfontClass', CAPTION,'<I>HEADING</I> More Heading',
SHADOW);" onMouseOut="nd();">example</a> uses the following style rules
in the HEAD section:');

</script>


Without using document.write, the code works flawlessly. I simply need
to create this code on the fly in the .html pages where I can place the
'Tooltips' with varying text in numerous places in the page.

Thanks in Advance!!!!!!!!!!
 
J

jht5945

I do not know you how use the written script, but one thing you should
know that if a HTML page was loaded completely, then use document.write
output HTML codes, the full HTML page will be erased.

IF YOU WANT TO CREATE ELEMENT DYNAMIC, YOU SHOULD USE
document.createElemnt, (see W3C DOM).
 
W

wesley_snipes1

Is there anyway to launch one of these tooltips using a Button onClick
Event ?
 

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

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,535
Members
45,008
Latest member
obedient dusk

Latest Threads

Top