国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 編程 > JavaScript > 正文

純JavaScript基于notie.js插件實現消息提示特效

2019-11-20 10:46:31
字體:
來源:轉載
供稿:網友

本文實例介紹了純JavaScript實現消息提示特效是一款基于notie.js插件實現的可以制作Alert提示框,確認框和帶輸入的消息框,分享給大家供大家參考,具體內容如下

效果圖:

實現的代碼:
html代碼:

<br><br><br><br><br><br>  <article class="zzsc">    <div class="div-ext">      <div class="div-int">         <span>Test notie with these buttons:</span>        <br>        <button onclick="success();">Success</button>        <button onclick="warning();">Warning</button>        <button onclick="error();">Error</button><br>        <button onclick="info();">Information</button>        <button onclick="confirm();">Confirm</button>        <button onclick="input();">Input</button>        <br>        </div>    </div>  </article>

js代碼:

function success() {      notie.alert(1, 'Success!', 2);    }     function warning() {      notie.alert(2, 'Warning<br><b>with</b><br><i>HTML</i><br><u>included.</u>', 2);    }     function error() {      notie.alert(3, 'Error.', 2);    }     function info() {      notie.alert(4, 'Information.', 2);    }     function confirm() {      notie.confirm('Are you sure you want to do that?<br><b>That/'s a bold move...</b>', 'Yes', 'Cancel', function () {        notie.alert(1, 'Good choice!', 2);      });    }     function input() {      notie.input('Please enter your email address:', 'Submit', 'Cancel', 'email', 'name@example.com', function (value_entered) {        notie.alert(1, 'You entered: ' + value_entered, 2);      });    }

希望本文所述對大家學習javascript程序設計有所幫助。

發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表
主站蜘蛛池模板: 开原市| 黎平县| 吉安县| 祁阳县| 洱源县| 德令哈市| 三原县| 广丰县| 崇州市| 黄梅县| 玛多县| 襄垣县| 彰化县| 丹江口市| 岱山县| 延寿县| 古浪县| 五莲县| 武宁县| 大悟县| 区。| 同仁县| 沂源县| 琼中| 安塞县| 武夷山市| 库车县| 石河子市| 哈巴河县| 合作市| 云林县| 那曲县| 环江| 锡林浩特市| 娄底市| 多伦县| 鹤壁市| 剑河县| 裕民县| 阳城县| 高平市|