raver
raver

Reputation: 283

Bootstrap: How to show modal without animation just for first time?

In my current project i have a link that opens modal with login form inside. When user enters wrong credentials then I reload page and show again login modal with errors. Currently I am using following code to show modal on page load:

$(function() {
    $('#login-modal').modal('show')
});

Everything is OK, but I want disable modal animation just for first time. How can I do this?

There is nothing in documentation about disabling animation just for first time

Upvotes: 1

Views: 4337

Answers (2)

Yasir Ali
Yasir Ali

Reputation: 155

you should hard code the milliseconds inside modal function for quick response.

Upvotes: -1

Vucko
Vucko

Reputation: 20834

From the docs:

For modals that simply appear rather than fade in to view, remove the .fade class from your modal markup.

Upvotes: 8

Related Questions