Jquery Gritter set position

You can try...

//css

.gritter-center{
position:fixed;
left:33%;
right:33%;
top:33%
}

 

//Javascript

$.gritter.add({
 title: 'This is a centered notification',
 text: 'Just add a "gritter-center" class_name to your $.gritter.add or globally to   $.gritter.options.class_name',
 class_name: 'gritter-info gritter-center'  
});

 

ref: https://stackoverflow.com/questions/18461530/jquery-gritter-set-position

posted @ 2017-06-19 14:51  圆旭  阅读(755)  评论(0编辑  收藏  举报