cross-browser

Can I get away with testing sites using IE8 with IE7 compatibility on?

▼魔方 西西 提交于 2019-12-03 16:42:38
问题 As a developer, can I safely upgrade to IE8 and use its IE7 compatibility mode to test how sites look in IE7? For IE6, I have a virtual machine and it is quite inconvenient. I don't want to upgrade to IE8 and then have another virtual machine now for IE7. Or is IE7 compatibility mode really different and I can't rely on that? 回答1: Compatibility mode in IE8 is not a 100% emulation of IE7. Security changes were not versioned, and some DOM operations were not versioned. Check out this blog post

Alpha becomes black when coming from clipboard on Mozilla Firefox and MS Edge

浪尽此生 提交于 2019-12-03 16:36:43
I'm using a code from here to paste images from clipboard on a page. It works fine in all browsers (Chrome, Firefox, Edge and Opera). The problem is: when the image is a PNG or GIF with alpha channel (transparent areas), the alpha becomes black in Firefox and Edge. Here's the code snippet ( or jsfiddle if you prefer ): document.getElementById('pasteArea').onpaste = function (event) { // use event.originalEvent.clipboard for newer chrome versions var items = (event.clipboardData || event.originalEvent.clipboardData).items; console.log(JSON.stringify(items)); // will give you the mime types //

Test if page has a horizontal scrollbar (computer & mobile devices)

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-03 16:14:23
On a web page, I need to test if there is a horizontal scrollbar or not (so that I programmatically change the css of some other element). Is there some way to get that information using jquery (or pure javascript)? I tested function isHorizontalScrollbarEnabled() { return $(document).width()!=$(window).width(); } but it does not seem to work with all browsers (does not work for example with a recent Samsung phone I tested). I need it to work with all browsers, including recent mobile devices. Thank you! EDIT 1 I tested the solutions provided by plalx and laconbass, tested IE8, Firefox, Chrome

how to make css3 and html5 compatible website for all browsers including IE7 and later

别等时光非礼了梦想. 提交于 2019-12-03 16:05:50
Is there any single framework with which I can build a css3, html5 website that is compatible for all browsers including IE7 and later? Can http://html5boilerplate.com/ boilerplate help me in this? You will never get the IE7 or IE8 rendering engine to achieve full compatibility with HTML5, CSS3, and other modern technologies. They are simply not capable of it. However there are some hacks, tools and plugins which can get you part of the way. Tools like Modernizr will help you by allowing you to detect which features are supported, to give your site a chance to work around it. jQuery is a great

Open file input dialog and upload onchange possible in IE?

二次信任 提交于 2019-12-03 15:44:35
问题 This is basically and simplified what I have now: <style> form.noshow { height: 0; overflow: hidden; } </style> <form class=noshow target="SomeIframeThatExists"> <input type=file id=uf> </form> <a id=uflink href="/user/photo">Upload photo</a> <script> $('uf').addEvent('change', function(e) { // alert('oele'); // this would work fine this.form.submit(); // auch in IE > "Access denied" exception }); $('uflink').addEvent('click', function(e) { $('uf').click(); // opens file dialog in all

Is it possible to stream video p2p (or other technology) between iOS, Android, Browser

吃可爱长大的小学妹 提交于 2019-12-03 15:24:50
I'm just learingn mobile web development and thinking about task: Is there a way to make a videostream betwen iOS, Android and Browser. What architecture and technology it should use. I already read this quetion on SO Peer-to-Peer video from iOS to Android? but there is nothing about browsers. If it can't be p2p and crossplatfom at the same time. I thought i shoud use Red5 server or etc. or Xmpp So I'm asking your advice and opinion here. Any information would be valuable Yes, You can !!! There is new technology enforced by google is WEBRTC It is stands for "web real time communication" and is

Text input placeholders not displaying in IE and Firefox

早过忘川 提交于 2019-12-03 15:13:51
问题 My text input placeholders refuse to display in IE and Firefox despite having used the -moz-placeholder attribute. This can be viewed on the contact page here if you are using Firefox or IE. Can someone please help I have been trying to figure this out for weeks. A sample of my code is below: input::-moz-placeholder, textarea::-moz-placeholder { color: #aaa; font-size: 18px; } input:-ms-input-placeholder, textarea::-ms-input-placeholder { color: #aaa; font-size: 18px; } input::-webkit-input

Javascript: cross-browser serverless file upload and download

好久不见. 提交于 2019-12-03 14:53:49
So I'm working on a web app where a user will need to: provide a file full of data to work on save their results to a file All the manipulation is done in javascript, so I don't really have a need for server-side code yet (just static hosting), and I like it that way. In Firefox, I can use their file manipulation api to allow a user to upload a file directly into the client-side code (using a standard <input type=file/> ) and create an object URL out of a file so a user can save a file created by the client-side code. <input type="file" id="input" onchange="handleFiles(this.files)"> <a

How do I detect support for contentEditable via JavaScript?

允我心安 提交于 2019-12-03 14:51:51
I've been searching for this for a couple of days now and so far, the best I can come up with is checking the list below. I really don't like to check for support based on User-Agent, especially since it can be spoofed. I've also heard of at least one instance where the list below is incorrect (noted below). Is Internet Explorer? Is WebKit? (But I've read that mobile Safari doesn't support it) Is Opera? Is Gecko and version >= 1.9? (meaning Firefox 3 or later) Is there a better method based on testing for support directly via JavaScript, or is this pretty much the only way to test for support?

Browser agnostic C++ DOM interface

好久不见. 提交于 2019-12-03 14:11:34
When programming in C++ against the browser's DOM each engine has a different set of interfaces, IE has the COM based [MSHTML]( http://msdn.microsoft.com/en-us/library/aa752279(VS.85).aspx) , Mozilla has the XPCOM based Gecko DOM etc. Is there a common API that has adapters for major browsers (and versions)? As a clarification, the application in question is a desktop application written in C++ which interacts with browsers, currently we have separate code bases for support of IE and Mozilla and I'm trying to reduce duplications of logic and allow adding new browsers with less effort. A