
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Found 598 Articles for Front End Scripts

4K+ Views
In this tutorial, we will learn how to return the color of the text with JavaScript. In the Style (It is a rule of HTML, used to describe how a document will be presented in the browser.) we define the color under that rule of HTML. To return the color of the text in JavaScript, we have to use the color property of JavaScript. The Colour property is used for assigning the color of the text inside the HTML tags (like p, h1, h2, body, etc.), and with the help of the id of the tag we can return the ... Read More

137 Views
To set all outline properties in one declaration, use the outline property. It sets the following properties: outline-width, outline-style, and outline-color.ExampleYou can try to run the following code to learn how to work with outline properties −Live Demo #box { border: 2px dashed blue; } This is a div. Click to set Outline function display() { document.getElementById("box").style.outline = "5px solid red"; }

505 Views
To set outline color, use the outlineColor property in JavaScript. You can try to run the following code to learn how to implement outlineColor property − Example Live Demo #box { border: 2px solid red; } Demo Content Change outline color function display() { document.getElementById("box").style.outlineColor = "#FF5733"; document.getElementById("box").style.outline = "2px solid"; }

201 Views
Use the JavaScript backfaceVisibility property to set whether or not an element should be visible while not facing the screen.ExampleYou can try to run the following code to learn how to implement a backfaceVisibility property in JavaScript −Live Demo div { width: 200px; height: 300px; background: blue; color: black; animation: mymove 2s infinite linear alternate; } @keyframes mymove { to {transform: rotateY(180deg);} } Check below to display backface Demo backfaceVisibility Property function display(x) { if (x.checked === true) { document.getElementById("box").style.backfaceVisibility = "visible"; } else { document.getElementById("box").style.backfaceVisibility = "hidden"; } }

161 Views
This tutorial will teach us to set whether the border image should be repeated, rounded, or stretched with JavaScript. Use the borderImageRepeat property to set whether the image-border is to be repeated, rounded, or stretched. Borders are used to decorate or focus an element. You can define its width, color, and type of border. Various styles can be applied to the borders. But, these borders are without any special effects or any other designs. Using the border-image property, we can set an image as a border of an element. It does not look like a line. It will be an ... Read More

143 Views
To divide a div into three columns, use the columnCount property. Set the column count and divide the div.ExampleYou can try to run the following code to return the numbers of columns an element is to be divided into with JavaScript −Live Demo Click below to create 4 columns Columns This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This is demo text. This ... Read More

207 Views
This tutorial teaches us how to return which part of a positioned element is visible in JavaScript. Positioned element is an element in JavaScript or Html which have some defined position it could be absolute which means fixed, or any relative position. To make the defined part visible only we are going to clip, remove, or hide the not required area by using the ‘clip’ property of the ‘style’ property of any element. We are going to define an area as a rectangle and defined its portion how much we are required to trim and how much we need to ... Read More

1K+ Views
To set the width of an element’s border in JavaScript, use the borderWidth property. Set the width using this property. You can try to run the following code to learn how to set the width of an element’s border − Example Live Demo #box { border: thick solid gray; width: 300px; height: 200px } Demo Text Change border width function display() { document.getElementById("box").style.borderWidth = "thin"; }

263 Views
To set all the border top properties in a single declaration, use the borderTop property. With this property, you can set the border-top-width, border-top-style, and border-top-color property.ExampleYou can try to run the following code to learn how to work with border-top properties in JavaScript −Live Demo #box { border: thick solid gray; width: 300px; height: 200px } Demo Text Change top border function display() { document.getElementById("box").style.borderTop = "thick solid #000000"; }

200 Views
To set all the border right properties in JavaScript, use the borderRight property. Set the border color, style, and, width at once using this property.ExampleYou can try to run the following code to learn how to set all the border right properties at once −Live Demo #box { border: thick solid gray; width: 300px; height: 200px } Demo Text Change right border function display() { document.getElementById("box").style.borderRight = "thick solid #000000"; }