Daniol Thomas has Published 197 Articles

Execute a script when the browser window is being resized in HTML?

Daniol Thomas

Daniol Thomas

Updated on 30-May-2020 23:28:32

283 Views

When the web browser window is resized, the onresize attribute triggers.ExampleYou can try to run the following code to implement onresize attribute −           Resize the window to trigger event.                function display() {             alert("Web browser window resized!");          }          

What is the role of Keyboard Event altKey Property in JavaScript?

Daniol Thomas

Daniol Thomas

Updated on 23-May-2020 11:00:45

151 Views

The altkey property is used to show whether ALT key is pressed or not when key event was triggered.ExampleYou can try to run the following code to learn how to implement altKey property in JavaScript.                 Press any key   ... Read More

Values to set page size in CSS

Daniol Thomas

Daniol Thomas

Updated on 16-Mar-2020 08:14:58

2K+ Views

There are four values that can be used to set page size −auto − The page box will be set to the size and orientation of the target sheet.landscape − Overrides the target's orientation. The page box is the same size as the target, and the longer sides are horizontal.portrait − Overrides the ... Read More

Explain the difference between RowSet and ResultSet in JDBC?

Daniol Thomas

Daniol Thomas

Updated on 09-Mar-2020 06:42:48

3K+ Views

Following are the differences between RowSet and ResultSet:ResultSetRowSetA ResultSet always maintains connection with the database.A RowSet can be connected, disconnected from the database.It cannot be serialized.A RowSet object can be serialized.ResultSet object cannot be passed other over network.You can pass a RowSet object over the network.ResultSet object is not a ... Read More

What is Result in JDBC? How to retrieve data from ResultSet object?

Daniol Thomas

Daniol Thomas

Updated on 09-Mar-2020 06:31:58

2K+ Views

A ResultSet interface in JDBC represents the tabular data generated by SQL queries. It has a cursor which points to the current row. Initially, this cursor is positioned before the first row.Moving the pointer throughout result setThe next() method of the ResultSet interface moves the pointer of the current (ResultSet) object ... Read More

How can I alter the color of an HTML5 canvas element using jQuery?

Daniol Thomas

Daniol Thomas

Updated on 04-Mar-2020 08:00:00

275 Views

To alter the color of an HTML5 canvas, use −document.getElementById("ID").style.background = red;You can also try the following −var ctx = canvas.getContext('2d'); ctx.fillStyle = "#FF0000"; ctx.fill();

Create a pattern with HTML5 Canvas

Daniol Thomas

Daniol Thomas

Updated on 04-Mar-2020 07:11:09

481 Views

Use the following method to create a pattern with HTML5 Canvas: createPattern(image, repetition)− This method will use an image to create the pattern. The second argument could be a string with one of the following values: repeat, repeat-x, repeat-y, and no-repeat. If the empty string or null is specified, repeat ... Read More

How do we define a dialog box in HTML?

Daniol Thomas

Daniol Thomas

Updated on 03-Mar-2020 12:39:33

245 Views

Use the tag to define a dialog box in HTML. The following are the attributes −AttributeValueDescriptionopenopenopens a dialog box and user can interact with itExampleYou can try to run the following code to learn how to work with tag −           HTML dialog ... Read More

How to specify an image as a client-side image-map in HTML?

Daniol Thomas

Daniol Thomas

Updated on 03-Mar-2020 12:26:12

582 Views

Use the usemap attribute to specify an image as a client-side image-map in HTML. You can try to run the following code to implement usemap attribute −Example           HTML map Tag                                              

How to store data in the browser with the HTML5 localStorage API?

Daniol Thomas

Daniol Thomas

Updated on 25-Feb-2020 07:02:41

254 Views

HTML5 localStorage saves string data in the browser and lasts beyond the current session. localStorage stores the data, with no expiration, whereas sessionStorage is limited to the session only. When the browser is closed, the session is lost.The Local Storage is designed for storage that spans multiple windows and lasts ... Read More

Previous 1 ... 5 6 7 8 9 ... 20 Next
Advertisements