Try to search your question here, if you can't find : Ask Any Question Now ?

The Delay property of a toast in Jquery, does not work on a site built in PHP

HomeCategory: stackoverflowThe Delay property of a toast in Jquery, does not work on a site built in PHP
Avatarbhawya asked 2 months ago

I have a mysql database connection built with PHP. At the frontend level I have included Bootstrap and Jquery, to be able to include toasts among many things. These notifications are shown after entering the data to the database, but the time in which they are visible is very short, not being able to modify the time with delay.

I already tried including the toast script inside the body and the head of the form, as in an external file called with defer, so as not to cause conflicts in the order of loading scripts, but still I cannot modify the toast delay.
I am working on a local installation with Debian.

I. The toast code:

     $("#enter_data").toast({ delay: 5000 });

II. Part of the form code (currently invoking it from an external file // with defer):

<input id="btnEnter" type="submit" name="enter_data" value="Enter Card" class="btn btn-primary">



<div aria-live="polite" aria-atomic="true" class="d-flex justify-content-center align-items-center" style="min-height: 200px;">

  <!-- Then put toasts within -->
  <div class="toast" id="enter_data" role="alert" aria-live="assertive" aria-atomic="true">
    <div class="toast-header">

I do not understand why if the toast is displayed correctly, its delay property does not work correctly.

1 Answers
Best Answer
Avatarnaveen answered 2 months ago
Your Answer

18 + 11 =

Popular Tags

WP Facebook Auto Publish Powered By :