473,395 Members | 1,696 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

display title when tag got focus

KS
If I have a button like this.
<input type="button" name="foo" value="HIT ME" title="HIT ME HARD" />
If I move the cursor over it the title get displayed.
I want the title to get displayed when the button get focus by keypress or
jusing the Tab button on the keyboard so it gets the focus.
Is this possible?
Jul 23 '05 #1
1 5355
"KS" <ka*****@hotmail.com> wrote in message
news:42********@news.broadpark.no...
If I have a button like this.
<input type="button" name="foo" value="HIT ME" title="HIT ME HARD" />
If I move the cursor over it the title get displayed.
I want the title to get displayed when the button get focus by keypress or
jusing the Tab button on the keyboard so it gets the focus.
Is this possible?


Will this help? Watch for word-wrap.
(Only tested under IE and FF.)

<html>
<head>
<title>HitMe.htm</title>
<script type="text/javascript">
function tooltips(s) {
(s != "") ? d = "block" : d = "none";
document.getElementById("tip").style.display = d;
document.getElementById("tip").innerHTML = s;
}
</script>
<style type="text/css">
..tooltip {
background-color: lightyellow;
border: 1px solid black;
display: none;
font-family: Arial;
font-size: 8pt;
left:60px;
position: relative;
text-align: center;
top:-10px;
width: 70px;
}
</style>
</head>
<body>
<form action="#">
<input type="button" name="foo" value="HIT ME" title="HIT ME HARD"
onfocus="tooltips('HIT ME HARD')" onblur="tooltips('')">
<span id="tip" class="tooltip"></span>
</form>
</body>
</html>
Jul 23 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: dmiller23462 | last post by:
I'm trying to create a submission page for users to request PC/LAN Access....If they select "Yes" in the field asking about if they need Non Standard Software, I want several other HTML fields to...
16
by: Picho | last post by:
Hi all, Is there any .NET way (I am not rulling out API usage) to add button(s) to a form's title bar? I found some non-.NET solutions that did actually work in VB6 but not in the ..NET...
3
by: John Dalberg | last post by:
Hi I have a form that opens a new window for the results. Because the results might take a few seconds due to server processing, I would like to display a message "please wait" in the new...
1
by: Jon W | last post by:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"> <html> <head> <title>rolly</title> <!-- The desired performance for this gem would be to: 1. click on table cells 2. edit in INPUT 3....
0
by: Jon W | last post by:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"> <html> <head> <title>rolly</title> <!-- The desired performance for this gem would be to: 1. click on table cells 2. edit in INPUT 3....
6
by: dale zhang | last post by:
Hi, I build a web form with a 4-cell table on the top (flawlayout), followed by some labels and textboxes (gridlayout). The web form is displayed well in dell m60 laptop with all resolution...
1
by: rbinington | last post by:
Hi, I am trying to write a DNN module that has the ability to insert articles into an article repository. I want the users to be able to move pages around and enter text into the FCKEditor. I...
9
by: tshad | last post by:
This was posted before but the message got messed up (all NLs were stripped out for some reason). I have 2 labels that hold the name of different images on my .aspx page. <asp:Label ID="Logo"...
4
by: jeddiki | last post by:
Hi, I have been tinkering with this for a few hours now, but I just can not see why the left hand side column extends past my footer div. You can see what I mean here: ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.