By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
428,558 Members | 1,607 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 428,558 IT Pros & Developers. It's quick & easy.

Show Title without mouseovering on it.

P: n/a
guys,
i am changing the title of a span.
what i want to also do is, as soon as i change the title of the span, i
want to display that title without moving my mouse over it.
i am trying to do this through javascript.

i dont know if this is in anyways possible, but experts on this group
might help me out and guide me in the right direction.

thanks

Feb 3 '06 #1
Share this Question
Share on Google+
3 Replies


P: n/a
ComfortablyNumb wrote on 03 feb 2006 in comp.lang.javascript:
guys,
i am changing the title of a span.
what i want to also do is, as soon as i change the title of the span, i
want to display that title without moving my mouse over it.
i am trying to do this through javascript.

i dont know if this is in anyways possible, but experts on this group
might help me out and guide me in the right direction.


<span title='aaa'id='s1'>my title is: <span id='s2'></span></span>

<script type='text/javascript'>
function show(){
document.getElementById('s2').innerHTML =
document.getElementById('s1').title
}
setInterval('show()',30)
</script>

not tested

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Feb 3 '06 #2

P: n/a
"Evertjan." <ex**************@interxnl.net> wrote in
news:Xn********************@194.109.133.242:
ComfortablyNumb wrote on 03 feb 2006 in comp.lang.javascript:
guys,
i am changing the title of a span.
what i want to also do is, as soon as i change the title of the span, i want to display that title without moving my mouse over it.
i am trying to do this through javascript.

i dont know if this is in anyways possible, but experts on this group
might help me out and guide me in the right direction.


<span title='aaa'id='s1'>my title is: <span id='s2'></span></span>

<script type='text/javascript'>
function show(){
document.getElementById('s2').innerHTML =
document.getElementById('s1').title
}
setInterval('show()',30)
</script>

not tested


i got the impression that the OP wanted to have the contents of the title
parameter displayed. ie: if you hover over a div like so:

<div id="party" title="We all love to party"></div>

Then you get a nice pop-up bubble on top of your mouse pointer that says
"We all love to party". However, I don't think its possible to display
the contents of a title parameter without mousing over the tag directly.

Your suggestion would be a good work-around.

Feb 3 '06 #3

P: n/a
Good Man wrote on 03 feb 2006 in comp.lang.javascript:
"Evertjan." <ex**************@interxnl.net> wrote in
news:Xn********************@194.109.133.242:
ComfortablyNumb wrote on 03 feb 2006 in comp.lang.javascript:
guys,
i am changing the title of a span.
what i want to also do is, as soon as i change the title of the
span, i want to display that title without moving my mouse over it.
i am trying to do this through javascript.

i dont know if this is in anyways possible, but experts on this
group might help me out and guide me in the right direction.


<span title='aaa'id='s1'>my title is: <span id='s2'></span></span>

<script type='text/javascript'>
function show(){
document.getElementById('s2').innerHTML =
document.getElementById('s1').title
}
setInterval('show()',30)
</script>

not tested


i got the impression that the OP wanted to have the contents of the
title parameter displayed. ie: if you hover over a div like so:

<div id="party" title="We all love to party"></div>

Then you get a nice pop-up bubble on top of your mouse pointer that
says "We all love to party". However, I don't think its possible to
display the contents of a title parameter without mousing over the tag
directly.

Your suggestion would be a good work-around.


The OP could display a "fake"-title with overlib:

<http://www.bosrup.com/web/overlib/>

And test every 50 milisecond for (title!=oldTitle)

However, since the changing of the title would be a JS DOM maniipulation,
why not trigger it by the same action?

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Feb 3 '06 #4

This discussion thread is closed

Replies have been disabled for this discussion.