你可以在jquery确认对话框中加粗文本吗?(can you bold text in a jquery confirm dialog box?)

编程入门 行业动态 更新时间:2024-10-25 20:27:26
你可以在jquery确认对话框中加粗文本吗?(can you bold text in a jquery confirm dialog box?)

我有以下jquery代码:

<script type="text/javascript"> $(document).ready(function() { $(".deleteuser").click(function(){ return confirm("Are you sure you want to delete this user?")}); }); </script>

我希望能够在确认对话框中加粗文本...所以类似于:(伪代码)

$(".deleteuser").click(function(){ return confirm("Are you sure you want to delete this user? <b>Note:</b> It can't be undone!")});

谢谢!

I have the following jquery code:

<script type="text/javascript"> $(document).ready(function() { $(".deleteuser").click(function(){ return confirm("Are you sure you want to delete this user?")}); }); </script>

I'd like to be able to bold the text inside the confirm dialog box ... so something like: (pseudocode)

$(".deleteuser").click(function(){ return confirm("Are you sure you want to delete this user? <b>Note:</b> It can't be undone!")});

Thank you!

最满意答案

您无法使用标准的javascript弹出窗口执行此操作。

您需要使用自定义库,例如下面之一:

jQueryUI的 MooTools的 原型 Scriptaculous的 雅虎用户界面

You can't do this with standard javascript popups.

You'll need to use a custom library such as one of the below:

jQueryUI MooTools Prototype Scriptaculous Yahoo User Interface

更多推荐

本文发布于:2023-07-22 12:13:00,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1219918.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:你可以   文本   加粗   对话框中   jquery

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!