AmitDiwan has Published 10744 Articles

How to create a browser window example with CSS?

AmitDiwan

AmitDiwan

Updated on 08-May-2020 14:24:13

276 Views

To create a browser window example with CSS, the code is as follows −Example Live Demo    body {       font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;    }    * {       box-sizing: border-box;    }    .menuBar {       ... Read More

How to create a download link with HTML?

AmitDiwan

AmitDiwan

Updated on 08-May-2020 14:15:52

809 Views

To create a download link with HTML, the code is as follows −Example Live Demo Download Link example Click on the image above to download it OutputThe above code will produce the following output −

How to create a flip box with CSS?

AmitDiwan

AmitDiwan

Updated on 08-May-2020 14:04:38

786 Views

To create a flip box with CSS, the code is as follows −Example Live Demo    body {       font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;       margin:20px;    }    .flipCard {       background-color: transparent;       width: 300px; ... Read More

How to find out if an element is hidden with JavaScript?

AmitDiwan

AmitDiwan

Updated on 08-May-2020 13:58:35

491 Views

To find out if an element is hidden with JavaScript, the code is as follows −Example Live Demo    body {       font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;    }    .hiddenDiv {       width: 100%;       padding: 20px;   ... Read More

How to detect whether the browser is online or offline with JavaScript?

AmitDiwan

AmitDiwan

Updated on 08-May-2020 13:55:22

433 Views

To detect whether the browser is online or offline with JavaScript, the code is as follows −Example Live Demo Online or offline with JavaScript example Click the button below to check if you are online or not Check online/offline    function checkOnlineOffline() {       if(navigator.onLine===true){ ... Read More

How to add an active class to the current element with JavaScript?

AmitDiwan

AmitDiwan

Updated on 08-May-2020 13:35:43

2K+ Views

To add an active class to the current element with JavaScript, the code is as follows −Example Live Demo    .btn {       border: none;       outline: none;       padding: 10px 16px;       background-color: #6ea2f0;       cursor: ... Read More

How to remove a class name from an element with JavaScript?

AmitDiwan

AmitDiwan

Updated on 08-May-2020 13:33:46

399 Views

To remove a class name from an element with JavaScript, the code is as follows −Example Live Demo    .newStyle {       font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;       width: 100%;       padding: 25px;       background-color: rgb(147, 80, ... Read More

How to add a class name to an element with JavaScript?

AmitDiwan

AmitDiwan

Updated on 08-May-2020 13:32:10

422 Views

To add a class name to an element with JavaScript, the code is as follows −Example Live Demo    .newStyle {       font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;       width: 100%;       padding: 25px;       background-color: rgb(147, 80, ... Read More

How to toggle between adding and removing a class name from an element with JavaScript?

AmitDiwan

AmitDiwan

Updated on 08-May-2020 13:29:47

215 Views

To toggle between adding and removing a class name from an element with JavaScript, the code is as follows −Example Live Demo    .newStyle {       font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;       width: 100%;       padding: 25px;     ... Read More

How to toggle text with JavaScript?

AmitDiwan

AmitDiwan

Updated on 08-May-2020 13:28:16

2K+ Views

To toggle text with JavaScript, the code is as follows −Example Live Demo    body {       font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;    }    .textDiv {       font-size: 20px;       background-color: rgb(199, 228, 157);       width: ... Read More

Advertisements