dnnAlert jQuery Plugin

Return to previous page

  • 4/7/2015
  • 3678 Views

Comments

3678 Views

dnnAlert jQuery Plugin

Last updated 6 years ago

Comments

Common

(Enter the content of this article below)

Advanced

 
This article is for a specific plugin. Please be sure to read the Introduction and Overview to jQuery Plugins which provides an introduction to the plugins.

dnnAlert

This is a simple wrapper around the jQuery UI modal that sets all of the appropriate defaults – all that needs to be done is to pass it the text to display. Use the alert in situations where you just want to tell the user a message (they read it, click ok, and the dialog closes).

Note that this plugin differs from the rest in that operates off of the global jQuery object as opposed to operating off of a jQuery object that wraps one or more selected DOM elements.
There are three textual elements that will need to be passed in to create the alert.

Available Options and their Defaults

text: '' // message to display to user
okText: 'Ok', // confirm button text
dialogClass: 'dnnFormPopup' // css class for the dialog

In addition, the plugin can accept any of the "core" jQuery UI modal options:http://jqueryui.com/demos/dialog/. Please note that the "buttons" option will be overridden, however. As this plugin is meant to only display the one confirmation button.

Usage Example

$.dnnAlert({
okText: '<%= Localization.GetString("Ok.Text", this.LocalResourceFile)%>',
text: '<%= Localization.GetString("Message.Text", this.LocalResourceFile) %>'
});

Other jQuery Plugins

  • dnnConfirm - displays an "are you sure?" confirmation in a modal dialog (uses jQuery UI)
  • dnnPanels - displays content areas in regions that are expandable and collapsible
  • dnnExpandAll - works with panels to expand or collapse all regions
  • dnnTabs - Displays content areas in a tabbed format (uses jQuery UI)
  • dnnTooltip - Provides help/info tooltip functionality
  • dnnPreview - Helps preview skins and containers in a new window
Contents
No sections defined
Subscribe to DNN Digest

DNN Digest is our monthly email newsletter. It highlights news and content from around the DNN ecosystem, such as new modules and themes, messages from leadership, blog posts and notable tweets. Keep your finger on the pulse of the ecosystem by subscribing.  


Copyright 2017 by DNN Corp Terms of Use Privacy
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out