Showing posts with label on. Show all posts
Showing posts with label on. Show all posts

How to turn on/off wifi using command line on Ubuntu

In case the wifi access points have been saved, it will automatically connect. 

Turn on/off wifi:
- nmcli nm wifi on
- nmcli nm wifi off

Newer version (e.g., 18.04):
- nmcli radio wifi on
- nmcli radio wifi off

jQuery - on() method

.on() method can be though of .on() as a general handler that takes the event, its selector, and an action as inputs.

 $(document).ready(function(){  
   $('#button').click(function(){  
     var toAdd = $('input[name=checkListItem]').val();   
     $('.list').append("<div class='item'>"+toAdd+"</div>");  
   });   
   $(document).on('click','.item',function(){  
     $(this).remove();    
   });  
 });