cross-browser

Discrepancy between outputs from firefox and chrome for 'console.log'

Why would firefox give me the correct output but Chrome doesn't ? I am trying to find the height of a div that has not been specified in the stylesheet or anywhere else. Chrome gives me the integer value of '20', but firefox gives me the correct value (using firebug) of 516. This is the code I am using to generate the console.log: va...

Floating menu does not work in Chrome?

I am trying to build a floating menu that follows the user when he scrolls the screen: menuYloc = parseInt($("#floatMenu").css("top").substring(0,$("#floatMenu").css("top").indexOf("px"))); $(window).scroll(function() { var offset = menuYloc+$(document).scrollTop()+"px"; $("#floatMenu").animate({top:offset},{du...

Easiest way to embed flash videos in Rails - must be cross browser compatible

Hi, I need to embed flv, mp4 and possibily other videos in a rails 2.3.5 application. I'm having quite a lot of problems making the videos show up in Safari 5 and Firefox 3.5. Is there an easy way to achieve a cross-browser video player and embed it in a rails app? I tried swfobject 1.5 and 2.2 with jw_player and also flowplayer but ...

jQuery cross-browser issue

I have this code that works great in all browsers but not IE6, and I have no idea why, can anyone shed any light on this? $("#handle").toggle( function () { $('#login').animate({ marginTop: '0', }, 1000); $("#handle").addClass('opened'); return false; }, function () { ...

Lucida Grande renders differently on Chrome and FF

Screenshot: http://imm.io/Wwr or http://gasa.jaeh.net It is pretty evident that my site renders different on Chrome5 and FF3 on my Ubuntu. Does anybody can point me how can I even these diffs? I don't want fonts with different 'feelings' on each browser. Another point is, the elements seems smaller on chrome, the font size mainly. Any...

Online Internet Explorer Simulators

(Tried to find simular questions / duplicates, failed) I develop on a mac. I love my mac. I develop using Chrome, Firefox, and Safari. I love them all for different reasons. But I have to develop for Internet Explorer users as well. I know, I am not unique here. I enjoy using the webkit inspector / firebug to mess with CSS. One of t...

Why is JavaScript inconsistent across browsers?

Here's something I've been pondering after countless hours fixing JS to be cross-browser compatible (mostly IE): Why isn't Javascript consistent accross browsers? I mean, why can't JS be nice like Java and Flash? Instead, we have to resort to frameworks like jQuery. Don't get me wrong, they make my life easier - but why do they even exi...

Browser Detection using java/J2EE

In order to achieve browser compatibility in application I am in need of Java class/Bean/Jar which will return the following information current browser of user its Name,version and also the OS of the user. Any thought on this will be really helpful, this should work well in latest versions of all the Modern Browsers such Chrome, Safar...

How to normalize padding and margins across browsers

Hi, How do other designers normalize padding and margins across browsers. I have tried CSS Resets (currently using the YUI one), but I still run into a lot of inconsistencies. It seems for some elements, with some browsers, setting a padding or margin to 0px will trigger the browser to use a default padding and margin determined by that...

Why does IE8 display a whitespace GAP between my menu bar and page content?

The page in question Please open the page in whatever browser you normally use and confirm that the menu bar immediately precedes the map. Next, open the page in IE8 and see that it inserts whitespace (roughly the height of the menu bar). Even if you use IE7, the whitespace doesn't appear. This has been bothering me for a while and I...

how to get web page size, browser window size, screen size in a cross-browser way?

how to get windowWidth, windowHeight, pageWidth, pageHeight, screenWidth, screenHeight, pageX, pageY, screenX, screenY in IE/FireFox/Chrome/Opera? or jquery, GWT? as showed in picture above! thanks! ...

Border-Spacing problem in IE7

I've a table on where I need a spacing between two rows of table. I did it in following way. table.fltrTbl { margin:0px; padding:0px; border-collapse:separate; border-spacing:0 11px; } table.fltrTbl td { vertical-align:middle; padding-right:14px; padding-left:0; padding-top:0; padding-bottom:0; ...

IE6 input button image background

Is it possible to make your own background image for input type="button" for IE6? ...

jQuery - Counting table rows not working in IE7

Hello, I'm coding an application that adds rows to a table without refresh using javascript and jquery. In order to append to the table, I need to do a count of the rows that are currently in the table. I'm using this code... var count = $('#columns tr.FIELD').length; The code works fine in Firefox and Chrome, but I am required to bui...

IE 8 doesn't scroll to fragment on initial page load

I'm having a problem with IE where it doesn't scroll to a fragment (#foo on the URL) when the page loads. The anchor for the fragment is part of the base HTML, it isn't dynamic or anything. The page is pretty heavy. If I go into the location bar and hit enter, it scrolls to the anchor as expected (and as observed in other browsers). ...

Developing custom buttons with "drop-down" feature but having problems in - what else - Internet Explorer 7+

I'm trying to create a set of custom buttons that include a button with a "down arrow" icon to indicate that when you click it a drop-down menu will appear underneath it. The functionality works fine in all the browsers I'm supporting (IE7+, FF3+, Chrome, Safari 4+, Opera 10+), but the appearance is screwed up in IE7. I can deal with th...

Performance comparison of AJAX requests: XML vs. JSON

I'm considering two different ways of completing the same task of displaying dynamic HTML using AJAX. The first method is to simply generate the HTML server-side and then insert it via. the DOM (jQuery's $().load() actually). The second method is to generate JSON server side and then use that data to inject elements into the DOM. I woul...

What CSS should I use to get a border around an option tag in both Firefox and IE?

Right now I am using the following CSS: option { border-width: 1px; border-style: solid; } Which works fine in Firefox but not in IE. I'm not sure if it makes a difference but the option tags are generated by an ASP.NET ListBox control. ...

How do I fix inconsistent Textarea bottom margin in Firefox and Chrome?

I'm trying to eliminate the extra bottom margin that both FF and Chrome seem to give to Textareas. Surprisingly IE seems to do it correctly. I would like to avoid using conditional includes but CSS3 tweaks are ok. TIA! Screen Shots Sample Code <!DOCTYPE html> <html> <head> <style> .red-box { background-color...

Cross Browser Selection Range Library?

Does any one know of any cross browser user selection range libraries written in javascript? I have a found a few jquery plugins, (which quite frankly are too limiting and very buggy). I have already implemented and am using the following to pull off some of my tricks: http://plugins.jquery.com/project/wrapSelection http://perplexed.co...