Questions tagged [toastr]

toastr is a JavaScript library for non-blocking notifications. It uses jQuery and the goal is to create a simple core library that can be customized and extended.

toastr is a JavaScript library for non-blocking notifications. It uses jQuery and the goal is to create a simple core library that can be customized and extended.

You can see a demo here

Stack Snippet Starter Pack

HTML:

<link href="//cdnjs.cloudflare.com/ajax/libs/toastr.js/2.1.2/toastr.css" rel="stylesheet"/>
<script src="//cdnjs.cloudflare.com/ajax/libs/jquery/2.1.4/jquery.js"></script>
<script src="http://cdnjs.cloudflare.com/ajax/libs/toastr.js/latest/js/toastr.js"></script>

JavaScript:

toastr.success("Hello World", "Toaster Title")
348 questions
7
votes
4 answers

Toast notifications in ASP.NET MVC 4

I want to display notifications whenever a user click on the "Add to Cart" button using the Toastr plugin. Basically, when a user click on the button, it executes the action "AddToCart" then redirects to the index page. When the page shows up, it…
Tung Pham
  • 579
  • 4
  • 11
  • 29
6
votes
1 answer

toastrjs - renew timer after hovering

I can't find any right way to renew timer in toastrjs after hovering. I determinate a extendedTimeOut to 0, to not close the toastr when I hover over it. The timeOut of toastr is 10000 ms, but when I'm finished hovering, toastr is immediately…
6
votes
3 answers

Getting error "toastr is not a function error" when trying to use toastr

I want to use toastr to notify the user. I have followed this guide to set it up. But I get the error message: Uncaught TypeError: toastr is not a function. I have looked at the network tab and the files are loading properly. Tried with a cdn to be…
AllramEst
  • 1,319
  • 4
  • 23
  • 47
6
votes
2 answers

How to use toastr in Django for success or fail message

I have been using Django message framework to show the success or failure message in my application. But I want the UI to be good so I found out that toastr is a good way to display messages to the user. But I am not sure how to use it. Please guide…
Manish Ojha
  • 515
  • 1
  • 8
  • 26
6
votes
1 answer

toastr is not defined

Receiving the following error in developer console when loading the page: Uncaught ReferenceError: toastr is not defined Here are the html contents. Can someone please explain to me why toastr is undefined?
ontheroadmike
  • 107
  • 1
  • 1
  • 4
6
votes
3 answers

How to adjust toaster popup width

I'm using AngularJS-Toaster to popup notifications in my app. For the frontend I'm using bootstrap. Using the class 'container' I have a grid of 1200px. Inside I have a div with the popup notifications. I would like to adjust the width of the popup…
fgonzalez
  • 3,787
  • 7
  • 45
  • 79
6
votes
3 answers

Angularjs-toaster always displays toast notification on top-right

I have this sample html file. Here I am using angular-toast notification. Issue I am facing here is toast messages always appear on the top-right position. script.js file contains angular.module('main', ['ngAnimate',…
ng-R
  • 757
  • 2
  • 7
  • 14
6
votes
1 answer

toastr and ember.js

Is the popup library toastr not going to work with Ember because of direct dom manipulation that ember doesn't like? Are there any other libraries like this one that work nicely with ember? Edit Even through the working example posted below I could…
Rudi
  • 1,577
  • 3
  • 16
  • 42
5
votes
1 answer

How to install react-toastr

I installed react-toastr and integrated the example code. import React from 'react' import { ToastContainer } from 'react-toastr'; class Notifier extends React.Component { updateNotify() { this.refs.container.info('hola el mundo'); } …
messy
  • 224
  • 2
  • 10
5
votes
5 answers

how to show a confirmation dialog box in toastr

I have the below code for a delete button in the controller, $scope.removes = function (scope) { toastr.success("Delete all?","

",{ closeButton: false, …
shamila
  • 1,280
  • 6
  • 20
  • 45
5
votes
1 answer

Clear single toastr message

I would like to clear/hide a single toastr message among multiple toastr messages displayed at a time. Is there any workaround for that rather than clearing the entire/multiple toastr messages simultaneously. I have tried the following code, but…
ABHILASH SB
  • 2,122
  • 2
  • 21
  • 31
5
votes
1 answer

Is it possible to show multiple toastr messages in diferrent positions?