Hi, I'm Ray

BSDialog4

BSDialog4 is a JavaScript helper for improving Bootstrap 4 modals. Add (and remove) modals to a page dynamically and load content with jQuery-AJAX. Bootstrap 4 is required.

 

Download Source Repository
 

Current version: 0.1.0.001

Features

  • Add (inject) and remove modals into a page
  • Load modal-content or modal-body from URL with jQuery-AJAX
  • Stack multiple modals

 

Usage

  • Create(id, title, url, size)
    id string Unique identifier for the modal, so you can refer to multiple modal
    title string Label at the top of the modal
    url string URL to load into the modal body
    size string Initial size of modal (xs, sm, md, lg, xl). Default is medium.

    Creates the Modal on the page and loads the body from a URL. An existing box will be reused if the ID already exists.


    BSDialog.Create("123", "My Modal Box 123", "/my-modal-box.html");
    BSDialog.Create("123", "My Modal Box 123", "/my-modal-box.html", "xl");
     

  • Close(id)
    id string Unique identifier for the modal, so you can refer to multiple modal

    Close the Modal box by the box identifier.

    BSDialog.Close("123");
     

  • Clear()
    Close all Modal boxes on the page.BSDialog.Clear();

 

Releases

  • 0.1.0.001 (27/12/2019)
        – Downloads: minJS | JS | GitLab

 

Change Log

  • 0.1.0.001 (27/12/2019)
        – Forked from BSDialog, upgraded for BS4

 

Acknowledgements

This software uses a number of dependencies and assets from third-parties. These developers and artists deserve due credit for their work and for their commitment to sharing their work freely. Each product is released under their own particular license, for more information please visit their websites.

Copyright © 2014-2020 Ray Lam. All Rights Reserved.