Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

bootstrap 4 open tab when opening modal

$('#modal-sensory').on('show.bs.modal', function (event) {    
  // Button that triggered the modal
  var button = $(event.relatedTarget)

  // the modal
  var modal = $(this);

  //show tab
  modal.find('[href="'+button.attr("href")+'"]').tab('show');
});
Comment

PREVIOUS NEXT
Code Example
Javascript :: uiimage from assets 
Javascript :: java script add fields dynamically 
Javascript :: how to make data toggle=modal always active 
Javascript :: use different environment variables in production and development 
Javascript :: react native image from web 
Javascript :: javascript timeline 
Javascript :: angular singleton service example 
Javascript :: juqery get label text 
Javascript :: how to access node js server from another computer 
Javascript :: how to use mdbreact in react js 
Javascript :: pagination react 
Javascript :: pug iterate array 
Javascript :: option selected aotu value 
Javascript :: swiper js 
Javascript :: Create Dark And Light Mode Website Using jQuery 
Javascript :: momoent isafter or equal$ 
Javascript :: directive multiple input 
Javascript :: javascript atan2 
Javascript :: JavaScript Object Accessors 
Javascript :: how to fetch data from another website in javascript 
Javascript :: npm ERR! code EPERM 
Javascript :: truthy and falsy js 
Javascript :: javascript parallax effect 
Javascript :: convert positive to negative number javascript 
Javascript :: Program to find GCD or HCF of two numbers javascript 
Javascript :: json parse js 
Javascript :: .reduce mdn 
Javascript :: decode jwt token without library 
Javascript :: Iterate with JavaScript Do...While Loops 
Javascript :: trigger mouseover on element devtools 
ADD CONTENT
Topic
Content
Source link
Name
8+5 =