String mouseover

hi,

The string should be changed, if the mouse moves over the string. onmouseover must be executed by javascript. But how?

I got error.

<t:outputText onmouseover="this.value='ByeBye';" value="Welcome" />

Manu

[244 byte] By [Argonista] at [2007-11-27 11:49:43]
# 1

That is because JavaScript operates on the client side; the browser never sees your outputText component. It is transformed into HTML markup, probably a span or a div. Neither of these has a value attribute.

In the future please post the error you get as well. Just stating that you received an error is insufficient.

RaymondDeCampoa at 2007-7-29 18:26:58 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2

Have you any idea to be changed the text if the mouse is over the element?

ok, in the future will I post error as well.

Argonista at 2007-7-29 18:26:58 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3

I solved my problem.

<t:outputText id="test" forceId="true" onmouseover="document.getElementById('test').firstChild.replaceData(0,document.getElementById('test').firstChild.nodeValue.length,'Hallo');" value="Good morning" />

Thanks

Argonista at 2007-7-29 18:26:58 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...