Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

Show text value on mousehover

CA5
Tera Contributor

<div >
<input id="abc" onmouseover="ShowToolTip(this.id)" title="" class="select2 form-control ev-field ev-field-reference"/>
</div>     

 

<script>

function ShowToolTip(txtbox)
{
var ToolTip = document.getElementById(txtbox);
ToolTip.title=ToolTip.value;
}

</script>

 

 

How to show value entered in input box when mouse is hover on textbox?

1 REPLY 1

Sagar Pagar
Tera Patron

Hi @CA5,

 

Try by adding tooltip.

 

<div >
<input id="abc" tooltip="add tool tip text here" title="" class="select2 form-control ev-field ev-field-reference"/>
</div>     

 

Take a look at old thread -

Mouse hover message on Service portal widget? 

 

 

Thanks,

Sagar Pagar

The world works with ServiceNow