当前位置:萝卜系统下载站 > 网页设计教程 > 详细页面

onmouseover事件

onmouseover事件

更新时间:2023-06-17 文章作者:未知 信息来源:网络 阅读次数:

网页的本质就是超级文本标记语言,通过结合使用其他的Web技术(如:脚本语言、公共网关接口、组件等),可以创造出功能强大的网页。因而,超级文本标记语言是万维网(Web)编程的基础,也就是说万维网是建立在超文本基础之上的。超级文本标记语言之所以称为超文本标记语言,是因为文本中包含了所谓“超级链接”点。

onmouseover事件

onmouseover事件与onmouseout事件是我们在做鼠标特效果常常用到的二个事件,当鼠标移入或移开时显示效果或做数据处理

定义:当鼠标光标信息停在某窗体元素上时,就会触发onMouseOver事件

语法:

onmouseover=”点击时要执行的脚本"

支持标签:

<a>, <address>, <area>, <b>, <bdo>, <big>, <blockquote>, <body>, <button>,

<caption>, <cite>, <code>, <dd>, <dfn>, <div>, <dl>, <dt>, <em>, <fieldset>,

<form>, <h1> to <h6>, <hr>, <i>, <img>, <input>, <kbd>, <label>, <legend>, 

<li>, <map>, <object>, <ol>, <p>, <pre>, <samp>, <select>, <small>, <span>, 

<strong>, <sub>, <sup>, <table>, <tbody>, <td>, <textarea>, <tfoot>, <th>, 

<thead>, <tr>, <tt>, <ul>, <var>

支持的JavaScript对象:

layer, link

举例说明:

<html>

<body>

Field1: <input type="text" id="field1" value="Hello World!">

<br />

Field2: <input type="text" id="field2">

<br /><br />

点击下面的按钮,把 Field1 的内容拷贝到 Field2 中:

<br />

<button onclick="document.getElementById('field2').value=

document.getElementById('field1').value">Copy Text</button>

</body>

</html>


网站建设是一个广义的术语,涵盖了许多不同的技能和学科中所使用的生产和维护的网站。

温馨提示:喜欢本站的话,请收藏一下本站!

本类教程下载

系统下载排行