javascript - making a noty notification a clickable hyperlink -


noty({ layout: 'topright', type: 'alert', text: 'number of alerts:'+count, template: '<div class="noty_message"><span class="noty_text"></span></div>', closewith: ['button'], dismissqueue: true,  animation: {     open: {height: 'toggle'},     close: {height: 'toggle'},     easing: 'swing',     speed: 500      },     timeout: false }); 

is there way of making notification clickable hyperlink. have considered callback onclose() don't want notification close can't use this. there callback onclick? or have way. putting hyperlink text?

you make use of buttons option create button open url in new window.

noty({     layout: 'topright',     type: 'alert',     text: 'number of alerts:'+count,     template: '<div class="noty_message"><span class="noty_text"></span></div>',     closewith: ['button'],     dismissqueue: true,      animation: {         open: {height: 'toggle'},         close: {height: 'toggle'},         easing: 'swing',         speed: 500      },     timeout: false,     buttons: [         {             addclass: 'css-class-for-the-btn', text: 'link', onclick: function ($noty) {                 window.open("http://yoururl/");             }         }     ] }); 

and customize css button defining class in addclass


Comments

Popular posts from this blog

c# - How to get the current UAC mode -

postgresql - Lazarus + Postgres: incomplete startup packet -

javascript - Ajax jqXHR.status==0 fix error -