1.资源

http://www.jq22.com/jquery-info476

http://www.jq22.com/yanshi476

Nuget

Install-Package toastr

官网 http://codeseven.github.io/toastr/

2.简单使用步骤

Link to toastr.css

<link href="toastr.css" rel="stylesheet"/>

Link to toastr.js

<script src="toastr.js"></script>

use toastr to display a toast for info, success, warning or error

// Display an info toast with no title
toastr.info('Are you the 6 fingered man?')

3.BundleConfig

bundles.Add(new ScriptBundle("~/bundles/jquery")
.Include("~/Scripts/jquery-{version}.js", "~/Scripts/toastr.min.js")
);
bundles.Add(new StyleBundle("~/Content/css")
.Include("~/Content/bootstrap.css", "~/Content/site.css")
.Include("~/Content/toastr.min.css"));

4.abp集成

var abp = abp || {};
(function () { if (!toastr) {
return;
} /* DEFAULTS *************************************************/ toastr.options.positionClass = 'toast-bottom-right'; /* NOTIFICATION *********************************************/ var showNotification = function (type, message, title, options) {
toastr[type](message, title, options);
}; abp.notify.success = function (message, title, options) {
showNotification('success', message, title, options);
}; abp.notify.info = function (message, title, options) {
showNotification('info', message, title, options);
}; abp.notify.warn = function (message, title, options) {
showNotification('warning', message, title, options);
}; abp.notify.error = function (message, title, options) {
showNotification('error', message, title, options);
}; })();

jquery toastr introduction的更多相关文章

  1. jquery toastr弹窗的代码和使用

    <link href="toastr.css" rel="stylesheet" type="text/css" /> < ...

  2. jQuery toastr提示简单实现

    注:在学校平时做的小项目跳页都是用 Response.Write写脚本弹窗并跳页,每次点击登录成功,注册成功......然后点击确定,太麻烦了,这次的项目老师说让用这个插件,所以就简单搞了一下! 实现 ...

  3. Jquery toastr提示框

    toastr是一个基于JQuery的消息提示插件; 1. 下载toastr和jquery https://jquery.com/download/ https://codeseven.github.i ...

  4. toastr 通知提示插件

    table.sb-tb td,table.sb-tb th { padding: 5px 10px !important } jquery toastr 一款轻量级的通知提示框插件. 网页开发中经常会 ...

  5. 前端基础(七):Toastr(弹出框)

    Toastr 简介 jquery toastr 一款轻量级的通知提示框插件. 网页开发中经常会用到提示框,自带的alert样式无法调整,用户体验差. 所以一般通过自定义提示框来实现弹窗提示信息,而jq ...

  6. WebGrid Helper with Check All Checkboxes

    WebGrid Helper with Check All Checkboxes myEvernote Link Tuesday, September 13, 2011ASP.NET ASP.NET ...

  7. [Django 1.5] Django 开发学习资源链接

    jQuery : jQuery API introduction:http://api.jquery.com/ jQuery plugins: http://benalman.com/projects ...

  8. bootstrap table记录一下

    $(function() { // 刷新 talbe function refresh() { $("#table").bootstrapTable('refresh'); } $ ...

  9. 漂亮灵活设置的jquery通知提示插件toastr

    toastr是一款非常棒的基于jquery库的非阻塞通知提示插件,toastr可设定四种通知模式:成功,出错,警告,提示,而提示窗口的位置,动画效果都可以通过能数来设置,在官方站可以通过勾选参数来生成 ...

随机推荐

  1. 二叉树计数(codevs 3112)

    题目描述 Description 一个有n个结点的二叉树总共有多少种形态 输入描述 Input Description 读入一个正整数n 输出描述 Output Description 输出一个正整数 ...

  2. java向oracle数据库中插入当前时间

    public class Test{public static void main (String args []){ java.util.Date a = new java.util.Date(); ...

  3. lsof -ntP -i:端口取出 动行程序的PID 然后xargs kill -9 这个进程

    [root@ok ok]# lsof -ntP -i: [root@ok ok]# netstat -lnutp|grep tcp /dnsmasq tcp /sshd tcp ::: :::* LI ...

  4. MVC基础知识

    1.View中获取Control和View: //获取控制器名称: ViewContext.RouteData.Values["controller"].ToString(); / ...

  5. 【JAVA 文件概述】

    一.概述 使用此类的原因: 该类将文件或者文件夹封装成对象.方便对文件与文件夹的属性信息进行操作.File对象作为参数传递给流的构造函数.要求:使用File类的常用方法. windows平台下,目录分 ...

  6. .NET NLog 详解(一)

    安装NLog NLog 的源代码托管在Github 上,一般的人直接使用NuGet就可以了. 这里我们选择安装NLog.Config.当然最方便的还是直接使用命令行: Install-Package ...

  7. Uncaught ReferenceError: console is not defined

    今天写javascript代码遇到了这个极其神奇的问题,居然报错说内置的console不存在,而且后来我换成了alert也不行.照例说这些都是js代码内置的东西不应该出现这种错误.不过百度之发现貌似没 ...

  8. sublime text 2中Emmet8个常用的技巧

    原文链接:http://blog.csdn.net/lmmilove/article/details/9181323 因为开始做web项目,所以最近在用sublime编辑器,知道了一个传说中的emme ...

  9. sql篇 select from where group by having order by

    以前,自己总是记不住如何用group by,如何用order by,什么时候用group by,什么时候用order by,什么时候两者一起用,怎么用,谁先谁后,现在,我们就一起来说一下Select ...

  10. HDFS & MapReduce异构存储性能测试白皮书