1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.4 add sweetalert javascript

Discussion in 'Styling and Customization Questions' started by Fawaz, Dec 8, 2014.

  1. Fawaz

    Fawaz Member

    Hello there , I plan to add this javascript alert http://tristanedwards.me/sweetalert
    into the xenforo , I open PAGE_CONTAINER and add the files after I uploading the sweetalert files into js folder

    <script src="js/lib/sweet-alert.min.js"></script>
    <link rel="stylesheet" type="text/css" href="js/lib/sweet-alert.css">

    then I try to add the alert code into footer

    swal({
    title: "Error!",
    text: "Here's my error message!",
    type: "error",
    confirmButtonText: "Cool"
    });


    still nothing happen , I'm newbie : )
     
  2. HWS

    HWS Well-Known Member

    I think you'll need to attach it to a page element with mouse click event to get triggered. But I am not familiar with it, just logical thinking... ;)
     
  3. Fawaz

    Fawaz Member

Share This Page