Anvi Jain has Published 629 Articles

How do we add a single-line input field in HTML?

Anvi Jain

Anvi Jain

Updated on 30-May-2020 22:59:17

565 Views

Use the tag to add a single-line input field. The HTML tag is used for querying a document through a text field. The tag can be used anywhere but head tag is preferable. Note: It is a deprecated tag and should not be used.The following are the attributes ... Read More

Which event occurs in JavaScript when an element is getting dragged?

Anvi Jain

Anvi Jain

Updated on 22-May-2020 11:28:34

90 Views

Use the ondrag event in JavaScript to drag an element. The ondrag event is triggered when an element is dragged.ExampleYou can try to run the following code to learn how to work with ondrag event in JavaScript.                    .drag {     ... Read More

What is the usage of onscroll event in JavaScript?

Anvi Jain

Anvi Jain

Updated on 21-May-2020 07:48:28

139 Views

The onscroll event occurs when scrollbar is being scrolled for an element. You can try to run the following code to learn how to implement onscroll event in JavaScript.Example                    div {             border: 2px solid ... Read More

How to use placeholder attribute in HTML?

Anvi Jain

Anvi Jain

Updated on 14-May-2020 10:54:04

4K+ Views

If you want to set a hint for text area or input field, then use the HTML placeholder attribute. The hint is the expected value, which gets displayed before the user enters a value, for example, name, details, etc.ExampleYou can try to run the following code to learn how to ... Read More

How can I display an image inside SVG circle in HTML5?

Anvi Jain

Anvi Jain

Updated on 13-May-2020 11:09:15

9K+ Views

To display an image inside SVG circle, use the element and set the clipping path. The element is used to define a clipping path. Image in SVG is set using the element.ExampleYou can try to run the following code to learn how to display an image inside ... Read More

How do we create the title of the text track in HTML?

Anvi Jain

Anvi Jain

Updated on 03-Mar-2020 09:59:51

100 Views

Use the label attribute in HTML to create the title of the text track in HTML.ExampleYou can try to run the following code to implement the label attribute −                                                            Your browser does not support the video element.          

How to display text ruby annotation in HTML5?

Anvi Jain

Anvi Jain

Updated on 03-Mar-2020 06:23:49

176 Views

Use the tag to display text ruby annotation. The HTML5 tag is used for pronunciation of character in ruby annotations. These are for showing pronunciation of East Asian characters.ExampleYou can try to run the following code to display text ruby annotation −           HTML Rt Tag                        漢 (Kan)          字 (ji)          

How do we set the alignment according to surrounding elements in HTML?

Anvi Jain

Anvi Jain

Updated on 02-Mar-2020 12:40:23

598 Views

Use the align attribute to set the alignment. You can try to run the following code to implement align attribute in HTML −Note − The align attribute deprecated in HTML5. Use CSS instead.Example           A right-aligned paragraph.       Note: The align attribute is not supported in HTML5. Use CSS instead.    

What are postfix operators in C++?

Anvi Jain

Anvi Jain

Updated on 11-Feb-2020 07:41:18

4K+ Views

Postfix operators are unary operators that work on a single variable which can be used to increment or decrement a value by 1(unless overloaded). There are 2 postfix operators in C++, ++ and --.In the postfix notation (i.e., i++), the value of i is incremented, but the value of the ... Read More

The static storage class in C++

Anvi Jain

Anvi Jain

Updated on 10-Feb-2020 12:32:02

436 Views

The static storage class instructs the compiler to keep a local variable in existence during the lifetime of the program instead of creating and destroying it each time it comes into and goes out of scope. Therefore, making local variables static allows them to maintain their values between function calls.The ... Read More

Advertisements