Article Categories
- All Categories
-
Data Structure
-
Networking
-
RDBMS
-
Operating System
-
Java
-
MS Excel
-
iOS
-
HTML
-
CSS
-
Android
-
Python
-
C Programming
-
C++
-
C#
-
MongoDB
-
MySQL
-
Javascript
-
PHP
-
Economics & Finance
Front End Technology Articles
Page 59 of 652
HTML Navigator product Property
The navigator.product property in HTML is a read-only property that returns the browser's engine name. In modern browsers, this property typically returns "Gecko" regardless of the actual browser engine being used. Syntax Following is the syntax for the navigator product property − navigator.product Return Value The property returns a string representing the browser engine name. For compatibility reasons, most modern browsers return "Gecko" even if they don't use the Gecko engine. Example Following example demonstrates how to access the navigator product property − ...
Read MoreHTML Window length Property
The HTML Window length property returns the number of elements (frames) in the current window or document. This property is read-only and provides a count of all frame elements present in the current context. Syntax Following is the syntax for the Window length property − window.length Return Value The window.length property returns a number representing the total count of iframe elements in the current document. If no iframes are present, it returns 0. Example − Single Iframe Following example demonstrates the Window length property with one iframe element − ...
Read MoreHTML Window innerHeight Property
The HTML Window innerHeight property returns the height of the browser window's content area in pixels, excluding toolbars, scrollbars, and other browser UI elements. This property is commonly used in responsive web design and dynamic layout calculations. Syntax Following is the syntax for accessing the innerHeight property − window.innerHeight Return Value The innerHeight property returns an integer representing the height of the browser window's content area in pixels. This value changes when the user resizes the browser window or when the browser's UI elements (like toolbars) are toggled. Basic Example Following ...
Read MoreHTML Window name Property
The HTML Window name property is used to get or set the name of the browser window. This property is particularly useful for identifying windows in multi-window applications, frame targeting, and inter-window communication. Syntax Following is the syntax for getting the window name − window.name Following is the syntax for setting the window name − window.name = "windowName" Return Value The window.name property returns a string representing the name of the window. If no name has been set, it returns an empty string (""). Getting Window Name ...
Read MoreHTML Window screenTop Property
The HTML Window screenTop property returns the vertical distance in pixels between the top edge of the browser window and the top edge of the user's screen. This property is useful for determining the window's position when creating popup windows or managing window layouts. Note − The screenTop property is not supported in Firefox browsers. Firefox uses the screenY property instead for the same functionality. Syntax Following is the syntax for the screenTop property − window.screenTop Return Value The screenTop property returns a number representing the vertical distance in pixels from the ...
Read MoreHTML Window pageXOffset Property
The HTML Window pageXOffset property returns the number of pixels the current document has been scrolled horizontally from the upper-left corner of the window. This read-only property is useful for tracking horizontal scroll position and implementing scroll-based functionality. Syntax Following is the syntax for the pageXOffset property − window.pageXOffset Return Value The property returns a number representing the horizontal scroll distance in pixels. If the document has not been scrolled horizontally, it returns 0. Example − Basic Usage Following example demonstrates how to use the pageXOffset property to track horizontal scrolling ...
Read MoreHTML Window top Property
The HTML Window top property returns a reference to the topmost browser window in the window hierarchy. This property is particularly useful when working with frames or iframes to determine if the current window is the main parent window or nested within another window. Syntax Following is the syntax for the window.top property − window.top Return Value The property returns a Window object reference to the topmost window. If the current window is already the topmost window, it returns a reference to itself. How It Works When a web page contains ...
Read MoreHTML DOM Object form Property
The HTML DOM Object form property returns a reference to the form element that contains an element. This property is read-only and provides a way to access the parent form from within JavaScript when working with object elements. Syntax Following is the syntax for accessing the form property − ObjectElement.form Return Value The property returns a reference to the HTMLFormElement that contains the object, or null if the object element is not enclosed within a form. Example Following example demonstrates how to use the Object form property to get a ...
Read MoreHTML DOM Time dateTime Property
The HTML DOM Time dateTime property is used to get or set the datetime attribute of a element. This attribute provides a machine-readable format for dates and times, making content more accessible to browsers, search engines, and assistive technologies. Syntax Following is the syntax for getting the dateTime property − timeObject.dateTime Following is the syntax for setting the dateTime property − timeObject.dateTime = "YYYY-MM-DDThh:mm:ssTZD" DateTime Format Components The datetime value follows the ISO 8601 standard format. Here are the components of YYYY-MM-DDThh:mm:ssTZD − Component ...
Read MoreHTML DOM TouchEvent altKey Property
The HTML DOM TouchEvent altKey property returns a Boolean value indicating whether the Alt key was pressed when a touch event was fired. This property is useful for creating touch interfaces that respond differently based on modifier key combinations. Syntax Following is the syntax for the TouchEvent altKey property − touchEvent.altKey Return Value The property returns a Boolean value indicating the state of the Alt key − Return Value Description true The Alt key was pressed when the touch event occurred false The ...
Read More