title attribute | title property

all
alt
ch
dir
id
min
rel
top
url
URL
urn
Expand Minimize
This topic has not yet been rated - Rate this topic

Sets or retrieves advisory information (a ToolTip) for the object.

HTML 4.01 Specification, Section 7.4.3

Syntax

HTML<element title="p" ... >
JavaScript

p = object.title

Property values

Type: String

the advisory text.

Standards information

Remarks

Renders the title as a ToolTip when the user hovers a mouse or finger over objects

Titles are limited to 512 total characters; this limit includes control characters, such as line feeds, carriage returns, and so on.

Examples

This example uses the title property to display advisory text when the user hovers the mouse pointer over the text.


<script type="text/javascript">
function boldAdvise(src) {
    src.title="this is bold text";
    return;
    }
</script>

: 

<span onmouseover="boldAdvise(this)">bold section</span> 

See also

a
abbr
address
area
article
aside
b
bdo
blockQuote
body
br
button
caption
cite
code
col
colGroup
custom
dd
del
div
dl
dt
em
embed
fieldSet
figcaption
figure
footer
form
head
header
hgroup
hn
hr
html
i
iframe
img
input type=button
input type=checkbox
input type=file
input type=hidden
input type=image
input type=password
input type=radio
input type=reset
input type=submit
input type=text
ins
kbd
label
legend
li
map
mark
nav
object
ol
optGroup
option
p
pre
q
rt
ruby
s
samp
section
select
small
span
strong
sub
sup
table
tBody
td
textArea
tFoot
th
tHead
tr
u
ul
var
title

 

 

Build date: 11/28/2012

Did you find this helpful?
(1500 characters remaining)
© 2013 Microsoft. All rights reserved.