How do I style a <select> dropdown with only CSS?

Is there a CSS-only way to style a <select> dropdown? I need to style a <select> form as much as humanly possible, without any JavaScript. What are the properties I can use to do so in CSS? This...

JavaScript get clipboard data on paste event (Cross browser)

How can a web application detect a paste event and retrieve the data to be pasted? I would like to remove HTML content before the text is pasted into a rich text editor. Cleaning the text after...

Where can I get the CUR files for the Firefox cursor values?

I'm using some of Firefox's specially-defined values for cursor, in particular -moz-zoom-in -moz-zoom-out -moz-grab -moz-grabbing In order to display these on other browsers, I'd like to deploy...

Can I run multiple versions of Google Chrome on the same machine? (Mac or Windows)

This fabulous answer suggests there’s no way to run multiple versions of Google Chrome on one machine. Every now and then you’ll get a website user stuck on an old version of Chrome (no idea...

String length in bytes in JavaScript

In my JavaScript code I need to compose a message to server in this format: <size in bytes>CRLF <data>CRLF Example: 3 foo The data may contain unicode characters. I need to send them as...

Dynamically change a HTML element's type

I am wondering if its possible to change a HTML elements data type with javascript? For example change an img to a div? The reason I am doing this & not destroying the img & creating a div is...

How to add onclick="return func()" by addEventListener?

I have a link: <a href="/somelink" id="link_test" onclick="return func(event);">Link</a>. I want to remove this onclick attribute and add a click event listener by addEventListener. I...

How do I detect XML parsing errors when using Javascript's DOMParser in a cross-browser way?

It seems that all major browsers implement the DOMParser API so that XML can be parsed into a DOM and then queried using XPath, getElementsByTagName, etc... However, detecting parsing errors seems...

Foolproof way to detect if iframe is cross domain

I'm trying to determine if any iframe is cross-domain or not. According to the accepted answer in this question:...

Getting a browser's name client-side

Is there any object or method that returns data about the browser, client-side? For example, I need to detect if the browser is IE (Interner Explorer). Following is the code snippet. function...

How can I set the color for the progress element?

Is it possible to set the color of the "bar" for the <progress> element in HTML (when you specify a value, the bar is filled up to the point of the value)? If so, how? background-color and...

Silverlight accessing WCF serivce throws Crossdomain error

I understand this question has been answered many times but i could not resolve it for some reason. I hope some one can solve my problem which might be straightforward for many, but i some how...

How can I "mouse swipe" with plain Javascript?

I'm new to Javascript and I'm trying to "master" it somehow and in order for me to do so I don't want to use any library [like jQuery] yet. That being said, I have found several ways to implement...

Foolproof way to detect if this page is INSIDE a cross-domain iframe

An answer to "Foolproof way to detect if iframe is cross domain" describes a method to test if an iframe on a page points to a same-domain or cross-domain page, working around different browsers'...

CSS - How can I make a font readable over any color?

Assuming I have a set font color that I must maintain, and that it overlays content that can be of any color, how can I make sure the font is readable no matter what it's overlaying? Here is a...

How to realize when a browser tab has been duplicated

I'm having problems with a duplicate tab on Chrome (session's stuff) and I'd like to avoid the action of duplicating tabs (or lacking that close the duplicate one). I'm opening the tab as it was a...

Get scroll position in Javascript

I would like to retrieve the current scroll position in Javascript, after some research I found this: window.scrollY and window.scollTop. But the problem is that it does not work 100% on all...

XBAP Support in IE Edge

I was building an WPF Browser application as such it requires many client specific functionality. During debugging when i tried to run this application in IE Edge it starts behaving in buggy way...

Compilation error after including <map>

I just started with C++, trying to learn some basics. Right now compiling using gcc version 5.2.1 in Eclipse, project is compiled with c++11 parameter. Now the include problem occurs when I try to...

'toDataURL' on 'HTMLCanvasElement': Tainted canvases may not be exported

In Chrome I get the following error on jsfiddle when trying to test canvas drawing images from a remote url. Error: Failed to execute 'toDataURL' on 'HTMLCanvasElement': Tainted canvases may not...

Error while trying to access public stories from Medium API on client side

I'm trying to access Medium's API to get a list of public stories from a user. However, I'm getting a CORS error when I try to access it on the client side. Here's the...

How to remove cross on date and time HTML inputs in Firefox

How do I hide the cross icon that automatically appears on date and time type HTML inputs? eg. <input type="time></input> Shows with a cross like this. I worked out how to do it for Chrome, but...

A :focus-within workaround for edge

I am currently using the pseudo selector :focus-within in chrome however according to caniuse.com it's unavailable in Edge and IE, I found a neat workaround for it: .focus-within-class >...

Not able to do Jmeter UI recording due to CORS error

We are facing CORS issue in Jmeter UI recording: CORS request did not succeed We have website uat.torchmarkets.com which internally calls tradeuat.torchmarkets.com in which has security check...

CSS `height: calc(100vh);` Vs `height: 100vh;`

I'm working on a project where the former developer used: .main-sidebar { height: calc(100vh); } I have no way to contact him/her anymore, and I would like to understand what is the...

Same-origin request causes “Access-Control-Allow-Origin doesn’t match” error, though origin of course matches. Note: has CSP policy w/ "sandbox"

When the exact same URL is being used in both by CORS and its web pages' URL, I still get the same error messages in my Firefox development console. Browser console messages were: Cross-Origin...

Can I use SharedArrayBuffer on iOS?

According to Mozilla, there is no browser on iOS supporting the cross-origin-opener-policy, which is one of the security requirements for enabling a SharedArrayBuffer. Does this mean I cannot use...

How to use Hotjar on Electron?

According to Hotjar documentation, Hotjar does not support Electron because Since you use it to create desktop applications and not web applications the Hotjar tracking code cannot be used. Is...

Saleor Platform running, storefront wont start the server

I've used the saleor platform method, with docker and dashboard and everything else works properly, but not the frontend, any idea how to debug this, this is the output of the last...

How can I use emotion with react-native-web?

I develop a cross-platform react-native application inside a monorepo and want to render my app using react-native-web in the browser. To achieve that I followed this guide...