I have an html page with an image src and I want to pop up the image on page first load in mvc layout . I am struggling to get the popup working. Below is my html code
- <!DOCTYPE html>
- <html>
- <head>
- <title>CUI Page</title>
- <meta charset="utf-8" />
- <script src="/Scripts/jquery-1.10.2.min.js"></script>
- <link href="/Content/bootstrap.min.css" rel="stylesheet" />
- <script src="/Scripts/bootstrap.min.js"></script>
- </head>
- <body>
-
- <div class="container">
- <div class="col-md-12" id="hide">
- <img src="/Content/Images/warning.png" style="margin-left: auto; margin-right: auto; display: block;" alt="" />
-
- <button autofocus id="myButton" type="button" style="margin-left: auto; margin-right: auto; display: block;">OK</button>
- </div>
- </div>
-
- </body>
- </html>
- <script>
- $("#myButton").on('click', function () {
- $("#hide").hide();
- </script>