Solved

Pop Bootstrap Modal On Load MVC

Posted on 2016-08-23
2
43 Views
Last Modified: 2016-08-24
I use to use this using webforms to pop a modal on load

    Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
        ScriptManager.RegisterStartupScript(Me, [GetType](), "Show Modal Popup", "$('#modalSearch').modal('show');", True)
    End Sub

Open in new window


Can anyone tell me how to do it using MVC
0
Comment
Question by:edjones1
2 Comments
 
LVL 11

Accepted Solution

by:
louisfr earned 500 total points
ID: 41768284
I would put it in the page directly.
<script type="text/javascript">
    $(function() {
        $('#modalSearch').modal('show');
    });
</script>

Open in new window

0
 

Author Closing Comment

by:edjones1
ID: 41768341
Perfect
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

In my previous two articles we discussed Binary Serialization (http://www.experts-exchange.com/A_4362.html) and XML Serialization (http://www.experts-exchange.com/A_4425.html). In this article we will try to know more about SOAP (Simple Object Acces…
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now