我需要知道如何为notify.js
警报应用$.notify({
message: "Alert!"
}, {
type: 'danger',
animate: {
enter: 'animated fadeInUp',
},
placement: {
from: "top",
align: "center"
},
offset: 20,
spacing: 10,
z_index: 1031,
});
个样式。
这是我的代码 -
<form name="form1" action="test1.php" method="post">
<table class="questiontable" border="0">
<tr><td><input type="submit" onclick="send()" name="previous_question" id="previous_question" value="Previous Question"></td></tr>
</table>
</form>
<script>
function send(){
this.disabled=true;
this.value='Please Wait...';
this.form.submit();
}
</script>
<?php
echo $_POST["previous_question"] ;
?>
我需要为此应用一些样式。
答案 0 :(得分:0)
$.notify({
message: "Alert!"
}, {
type: 'danger',
animate: {
enter: 'animated fadeInUp',
},
placement: {
from: "top",
align: "center"
},
offset: 20,
spacing: 10,
z_index: 1031,
style: 'addClassName'
});
然后这样的结构将在html中为notifiy
构建<div class="notifyjs-addClassName-base notifyjs-addClassNamesuccess">
<div class="clearfix">
<div class="title" data-notify-html="title">Would you like some Foo ?
</div>
<div class="buttons">
<button class="no">Cancel</button>
<button class="yes" data-notify-text="button">Confirm</button>
</div>
</div>
</div>
然后你可以根据需要创建1个css filr并添加css,使这个.notifyjs-addClassName-base
成为基类
.notifyjs-addClassName-base{
}