🔔 Alert..!! Get 2 Month Free Cloud Hosting With $200 Bonus From Digital Ocean ACTIVATE DEAL

bootpop.js is a jQuery plugin designed for enhancing the default Bootstrap modal component that supports AJAX loading, JSON content handler, alert/confirm dialogs and image/html embedding.

Modal Bootstrap alert confirm ajax-modal

Documentation

bootpop.js

AJAX Enabled Bootstrap Modal jQuery Plugin Set

  • AJAX content by default with pre-loader
  • JSON content handler
  • Multi-modal (launch modals from inside modals)
  • Alert and Confirm modals with buttons
  • Image and HTML content modals

Demos

Click here to see the examples in action.

Usage

Bootpop('ajax.php'); 
Bootpop.alert('Some message'); 
Bootpop.ask('Some question'); 
Bootpop.image('/src/to/img.png'); 
Bootpop.html('<h1>Hello</h1><h2>World!</h2>'); 

Options

  • url: The url to submit query
  • method: Request method (get, post)
  • size: small or large (default: medium)
  • modalHeader: true or false (default: true)
  • title: The modal header title (default: null)
  • params: (Object) {keyName : value}
  • buttons: (Array)
[{     btnClass : 'btn btn-success',     btnLabel : 'YES',     btnValue : 'Y',     btnAction : function(data){         $('.modal').modal('hide')     }  }]
  • responseHandler: (Function) function(data){ return data}

Styles

  • modalClass: modal fade
  • dialogClass: modal-dialog
  • contentClass: modal-content
  • headerClass: modal-header
  • titleClass: modal-title
  • bodyClass: modal-body
  • footerClass: modal-footer
  • imageClass: img-responsive

Events

  • opened.bp.modal Triggered when modal is opened and visable.
  • closed.bp.modal Triggered when modal is fully closed.

You May Also Like