
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 10483 Articles for Web Development

767 Views
Use the height property to set the height of an element. You can try to run the following code to set the height of a button with JavaScript −ExampleLive Demo Heading 1 This is Demo Text. Update Height function display() { document.getElementById("myID").style.height = "100px"; }

141 Views
Use the fontWeight property in JavaScript to set the font boldness.ExampleYou can try to run the following code to set the boldness of the font with JavaScript −Live Demo Heading 1 This is Demo Text. Set Font Family and Font Weight function display() { document.getElementById("myID").style.fontFamily = "verdana,sans-serif"; document.getElementById("myID").style.fontWeight = "800"; }

129 Views
To set the style of the font, use the fontStyle property. You can try to run the following code to set the style of the font to normal, italic or oblique with JavaScript −ExampleLive Demo Heading 1 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 is Demo Text. Set Font Family and Style function display() { document.getElementById("myID").style.fontFamily = "verdana,sans-serif"; document.getElementById("myID").style.fontStyle = "italic"; }

202 Views
To set the font in small capital letters, use the fontVariant property.ExampleYou can try to run the following code to set the font to be displayed in small capital letters with JavaScript −Live Demo Heading 1 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 is Demo Text. Set Font Family and Font Variant function display() { document.getElementById("myID").style.fontFamily = "verdana,sans-serif"; document.getElementById("myID").style.fontVariant = "small-caps"; }

1K+ Views
Use the left property to set the left position of a positioned element, such as a button.ExampleYou can try to run the following code to set the left position of a positioned element with JavaScript −Live Demo #myID { position: absolute; } Heading 1 This is Demo Text. Change Left Position function display() { document.getElementById("myID").style.left = "150px"; }

911 Views
To set the font size, use the fontSize property in JavaScript. You can try to run the following code to set the font size of the text with JavaScript − Example Live Demo Heading 1 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 is Demo Text. Set Font Family and Size function display() { document.getElementById("myID").style.fontFamily = "verdana,sans-serif"; document.getElementById("myID").style.fontSize = "smaller"; }

364 Views
To align the element horizontally, use the cssFloat property.ExampleYou can try to run the following code to set the horizontal alignment of an element with JavaScript −Live Demo 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 is Demo Text. Align Horizontally function display() { document.getElementById("myID").style.cssFloat = "right"; }

4K+ Views
To set the brightness, use the brightness property and for contrast, use the contrast property.ExampleYou can try to run the following code to use image filters with JavaScript −Live Demo Click below to change the brightness and contrast of the image. Edit Image function display() { document.getElementById("myID").style.filter = "brightness(50%)"; document.getElementById("myID").style.filter = "contrast(50%)"; }

173 Views
In this tutorial, let us look at the way to set whether the flexible items should wrap or not with JavaScript. We can use the flex-wrap property in JavaScript to set the item wrap value. Let us look into this in brief. Using the Style flex-wrap Property The flex-wrap property defines whether to wrap the items within a container element. The items must be flexible for the flex-wrap property to work. The default value is nowrap. Users can follow the syntax below to use the flex-wrap property. Syntax object.style.flexWrap = "nowrap|wrap|wrap-reverse|initial|inherit" The syntax above sets the flex-wrap value to ... Read More

229 Views
In this tutorial, we will learn how to know whether the border and background of empty cells are hidden or not with JavaScript. The JavaScript programming language can be used to create and modify DOM elements. There are two ways to incorporate HTML elements like tables into an HTML document. The first involves adding the HTML table tag straight to our HTML webpage, while the second involves writing the entire table as JavaScript code. The second approach is the most frequently used to create and include tables in the DOM. The tr abbreviation indicates the table row. This represents the ... Read More