Front End Scripts Articles

Page 25 of 47

Can a user disable HTML5 sessionStorage?

Vrundesha Joshi
Vrundesha Joshi
Updated on 15-Mar-2026 2K+ Views

Yes, users can disable HTML5 sessionStorage in their browsers. When disabled, attempts to use sessionStorage will either throw errors or fail silently, depending on the browser implementation. How Users Can Disable sessionStorage Different browsers provide various methods to disable DOM storage, which affects both localStorage and sessionStorage: Firefox Type "about:config" in the address bar and press Enter Search for "dom.storage.enabled" Right-click and toggle to "false" to disable DOM Storage Chrome Go to Settings → Privacy and security → Site Settings Click "Cookies and site data" Select "Block third-party cookies" or "Block all cookies" ...

Read More

Set image for bullet style with CSS

Chandu yadav
Chandu yadav
Updated on 15-Mar-2026 552 Views

The list-style-image CSS property allows you to replace default bullet points with custom images, giving you complete control over list styling. Syntax list-style-image: url('path/to/image.png'); list-style-image: none; /* Default */ Basic Example Here's how to set a custom bullet image for an unordered list: .custom-bullets { list-style-image: url('/images/arrow-bullet.png'); } ...

Read More

How to take a snapshot of HTML5-JavaScript based video player?

Ankith Reddy
Ankith Reddy
Updated on 15-Mar-2026 883 Views

You can capture a still frame from an HTML5 video player by drawing the current video frame onto a canvas element. This technique is useful for creating thumbnails, implementing pause screens, or saving video snapshots. How It Works The process involves using the drawImage() method to copy the current video frame to a canvas. The canvas acts as a snapshot buffer that can be manipulated or saved. Example Your ...

Read More

Usage of CSS list-style-image property

karthikeya Boyini
karthikeya Boyini
Updated on 15-Mar-2026 86 Views

The list-style-image CSS property allows you to replace default list markers (bullets or numbers) with custom images. This property is commonly used to create visually appealing lists with custom icons or graphics. Syntax list-style-image: url(image-path) | none | inherit; Parameters Value Description url() Specifies the path to the image file none No image is used (default behavior) inherit Inherits the value from parent element Example: Basic Usage ...

Read More

HTML5 and Amazon S3 Multi-Part uploads

Chandu yadav
Chandu yadav
Updated on 15-Mar-2026 263 Views

Amazon S3 multi-part uploads allow you to upload large files in smaller chunks, providing better reliability and performance. When combined with the HTML5 File API, you can create powerful client-side upload functionality. Overview of S3 Multi-Part Uploads Amazon S3 multi-part upload is a feature that enables you to upload a single object as a set of parts. Each part is a contiguous portion of the object's data, and you can upload these parts independently and in any order. How HTML5 File API Works with S3 The HTML5 File API provides interfaces for accessing files from web ...

Read More

Atomics.isLockFree() function in JavaScript

Samual Sam
Samual Sam
Updated on 15-Mar-2026 191 Views

The Atomics object in JavaScript provides atomic operations for use with SharedArrayBuffer objects in multi-threaded environments. The Atomics.isLockFree() method determines whether the JavaScript engine can perform atomic operations on a given byte size without using locks. This method helps optimize performance by checking if atomic operations are lock-free for specific data sizes, which is crucial for high-performance concurrent programming. Syntax Atomics.isLockFree(size) Parameters size: An integer representing the size in bytes. Valid values are typically 1, 2, 4, or 8 bytes corresponding to Int8, Int16, Int32, or BigInt64 array types. Return Value ...

Read More

Websocket for binary transfer of data & decode with HTML5

Nitya Raut
Nitya Raut
Updated on 15-Mar-2026 928 Views

WebSockets can handle binary data transfer using base64 encoding/decoding. Modern browsers provide built-in methods window.btoa() for encoding and window.atob() for decoding base64 data. Base64 Encoding for Binary Transfer When transferring binary data through WebSockets, encode it as base64 on the client side before sending: // Create WebSocket connection const socket = new WebSocket('ws://localhost:8080'); // Convert ...

Read More

Detection on clicking bezier path shape with HTML5

Ankith Reddy
Ankith Reddy
Updated on 15-Mar-2026 277 Views

To detect clicks on Bezier path shapes in HTML5 Canvas, you need to use pixel-based detection since Canvas doesn't have built-in shape hit testing. This technique draws the shape invisibly and checks if the clicked pixel contains color data. How Pixel-Based Detection Works The method involves drawing the Bezier shape to a hidden canvas context, then checking if the clicked coordinates contain any pixels. If the alpha channel is greater than 0, the click hit the shape. Complete Click Detection Example const canvas = document.getElementById('myCanvas'); const ctx = canvas.getContext('2d'); // Sample Bezier ...

Read More

How to prevent text select outside HTML5 canvas on double-click?

Smita Kapse
Smita Kapse
Updated on 15-Mar-2026 390 Views

When users double-click on or near an HTML5 canvas element, browsers may inadvertently select surrounding text. This creates a poor user experience, especially in interactive applications. Here's how to prevent this behavior. The Problem Double-clicking near a canvas element can trigger text selection in surrounding elements, highlighting unwanted text and disrupting the user interface. Solution: Disable Text Selection Set the onselectstart event handler to return false, which prevents the browser from starting text selection on the canvas element. var canvas = document.getElementById('myCanvas'); // Prevent text selection on double-click canvas.onselectstart = ...

Read More

DataView.byteLength property in JavaScript

karthikeya Boyini
karthikeya Boyini
Updated on 15-Mar-2026 194 Views

The byteLength property of the DataView represents the length of the current DataView in bytes. This property is read-only and returns the number of bytes from the start of the DataView to the end. Syntax Its syntax is as follows: dataView.byteLength Parameters This property takes no parameters as it's a read-only property, not a method. Return Value Returns a number representing the length of the DataView in bytes. Example 1: Basic Usage JavaScript Example ...

Read More
Showing 241–250 of 465 articles
« Prev 1 23 24 25 26 27 47 Next »
Advertisements