Articles on Trending Technologies

Technical articles with clear explanations and examples

modal(options) method in Bootstrap

Alex Onsman
Alex Onsman
Updated on 11-Mar-2026 1K+ Views

If you want to set content as a Bootstrap modal, then use the .modal(options) method.For this, use jQuery to set the model on the click of a button as in the following code snippet −$(document).ready(function(){   $("#button1").click(function(){     $("#newModal1").modal({backdrop: true});   }); });Let us now implement the modal(“options”) class. Here, we have two buttons that would generate different types of modals on click. One of them would close on clicking outside the modal, but another one will not close.Here is the complete example −Example Bootstrap Example      Sample   ...

Read More

Align media objects with Bootstrap

Ankith Reddy
Ankith Reddy
Updated on 11-Mar-2026 215 Views

To align media objects, use the .align class in Bootstrap. You can try to run the following code to implement the .align class.Use the .align-left class to align media to the left −Example           Bootstrap Example                                          Google Tag Manager Tutorial                                                                              Introduction                Google Tag Manager (GTM) is a free tool that makes it easy for marketers to add and update website tags.                                

Read More

Remove float from an element in Bootstrap

Alex Onsman
Alex Onsman
Updated on 11-Mar-2026 466 Views

Use the float-none class in Bootstrap to remove float from an element.The default for a text is always left; therefore removing float will place the text on the left −You can try to run the following code to remove float from an element −Example       Bootstrap Example                             Demo           This text is on the left (on small screen).       This text is on the left (on medium screen).       This text is on the left (float removed).       This text is on the left (on extra large screen).       This text is on the left (float removed).    

Read More

Media object in Bootstrap

Nitya Raut
Nitya Raut
Updated on 11-Mar-2026 216 Views

Use the .media-object class in Bootstrap to set the media object −Example           Bootstrap Example                                          Lolcode Tutorial                                                                              Introduction                LOLCODE is an esoteric programming language inspired by the funny things on the Internet. It is designed to test the boundaries of programming language design.                                

Read More

Stretch a flex item on different screens in Bootstrap 4

Ricky Barnes
Ricky Barnes
Updated on 11-Mar-2026 183 Views

To stretch a flex item on different screens in Bootstrap 4, use the .align-self-*-stretch class.To strect in on different screens, you need to use align-self-sm-stretch, align-self-md-stretch, align-self-lg-stretch, etc. Below is an example for small screen size −   A-one   B-one   C-one   D-one You can try to run the following code to stretch a flex item on different screen sizes −Example       Bootstrap Example                             Align Specific Flex Item and Stretch           A-one       B-one       C-one       D-one       Small Screen Size       A-one     B-one     C-one     D-one     Medium Screen Size         A-one     B-one     C-one     D-one     Large Screen Size         A-one     B-one     C-one     D-one      

Read More

Change the size of Bootstrap input groups

George John
George John
Updated on 11-Mar-2026 2K+ Views

Change the size of the input groups, by adding the relative form sizing classes like .input-group-lg, input-group-sm, input-group-xs to the .input-group itself.You can try to run the following code to change the size of input groups in Bootstrap:Example           Bootstrap Example                                                                   @                                                       @                                                       @                                

Read More

Bootstrap Event when the modal is about to be shown

Alex Onsman
Alex Onsman
Updated on 11-Mar-2026 316 Views

The show.bs.modal event in Bootstrap fires when the modal is about to be displayed. Here, I have added a script to generate an alert − $(document).ready(function(){   $("#button1").click(function(){     $("#newModal").modal("show");   });   $("#newModal").on('show.bs.modal', function () {     alert('The modal will be displayed now!');   }); }); Above, on button click, the modal generates. After that, I have used the show.bs.modal event to generate an alert when the modal is just about to be visible.The following is an example to demonstrate how to fire show.bs.modal event in Bootstrap when the modal is about to be displayed −Example ...

Read More

Assigning long values carefully in java to avoid overflow

karthikeya Boyini
karthikeya Boyini
Updated on 11-Mar-2026 396 Views

In case of having the operation of integer values in Java, we need to be aware of int underflow and overflow conditions. Considering the fact that in Java, The int data type is a 32-bit signed two's complement integer having a minimum value of -2, 147, 483, 648 and a maximum value of 2, 147, 483, 647. If a value goes beyond the max value possible, the value goes back to minimum value and continue from that minimum. In a similar way, it happens for a value less than the min value. Consider the following example.Examplepublic class Tester {   ...

Read More

Bootstrap alert-danger class

Nitya Raut
Nitya Raut
Updated on 11-Mar-2026 421 Views

The alert-danger class in Bootstrap is used to set danger action.You can try to run the following code to implement the alert-danger class in Bootstrap −Example           Bootstrap Example                                 This is danger action!    

Read More

Set blue outlined Bootstrap 4 Button

Ricky Barnes
Ricky Barnes
Updated on 11-Mar-2026 171 Views

To set blue outlined Bootstrap 4 button, use the .btn-outline-primary class.Add a blue outline to a button −   Blue outline You can try to run the following code to implement the btn-outline-primary class in Bootstrap −Example       Bootstrap Example                             Bootstrap 4     You can see blue outline below:     Blue outline

Read More
Showing 29831–29840 of 61,297 articles
Advertisements