Archive for the ‘Browsers’ Category

The Elusive Chrome 9 Blank Page Problem

Thursday, March 3rd, 2011

AKA the images with negative margins problem.

Prior to our most recent update of Intervals we started to get bug reports from customers telling us that when they tried to view certain tasks, certain parts of the page would be blank. The reports ranged from the task summary being blank, up to nearly the entire page being blank. The only common thread to all these reports was that the users were using Chrome 9, which had just been released. It wasn’t appearing on any other pages, just the task view page. Here is how the page is supposed to look, as viewed in Firefox (you are looking at a development version of Intervals, so I apologize for all the weirdness):

And for contrast, here’s what the page looked like in Chrome:

As you can see, with the exception of the footer, the page was essentially blank. Using Chrome’s developer tools I dove into the DOM tree and tried to figure out what I could. For the most part, Chrome was calculating element positions correctly.

Something had to be throwing them off wildly, and that was indeed the case. A particular element was being calculated with a height of -214748328 pixels. As some of you may already know, that particular number is telling because it’s the minimum number that can be expressed in the signed 32 bit integer range. Chrome was, for all intents and purposes, calculating this element’s height as negative infinity.

A bit of further digging revealed the cause. The element in question contained an image with a height of 1 pixel and a margin (imposed by the stylesheet) of -1px -3px -2px -3px.

Essentially, the negative margin on the images threw off computation of the element’s dimensions to an unacceptable level and affecting all the surrounding elements. Removing the image solved the problem. Unfortunately, this particular block of HTML came from the customer. In fact, it came from an Outlook email client, was pulled in from their email account, and was created as a task. In this case, this particular image was used for email tracking (most of the time you don’t even notice these in the emails you read, but they’re quite common).

The solution in our case was to remove the negative margins being applied to these images from the stylesheet. It fixed the problem in this case. Incidentally, we ran into similar issues with images lacking a src attribute. We fixed that by adding the following line to our CSS file:

img:not([src]) { display: none; }

CSS Vs Tables and rants in chronological order

Tuesday, February 3rd, 2009

I’ve been following some rants on hacker news and reddit dealing with CSS vs Tables, read in this order when you get a chance:

Why CSS should not be used for layout

http://www.flownet.com/ron/css-rant.html

Why CSS Should Be Used for Layout

http://www.newmediacampaigns.com/page/why-css-should-be-used-for-layout

Don’t Blame CSS For Your Incompetence

http://www.jemjabella.co.uk/blog/dont-blame-css-for-your-incompetence

The last article sums it all up in my opinion.

Toolbar buttons galore

Thursday, August 7th, 2008

Here’s a great time-saver extension. Toolbar Buttons is perfect for adding tough-to-find Firefox functions. They’re there BUT you have dig deep within Tools > Options to get to them. Need to quickly disable javascript, flash and images with just three quick clicks? No problem, just drag and drop the buttons. Here is my current setup:

PHP to Javascript Project: php.js

Thursday, July 24th, 2008

A lot of people are familiar with PHP’s functions, and though Javascript functions are often quite similar, some functions may be missing or addressed differently. The Javascript implementations should be as compliant with the PHP versions as possible, a good indication is that the PHP function manual could also apply to the Javascript version.

http://kevin.vanzonneveld.net/techblog/

Internet Explorer 7 and pirated versions of Windows XP

Thursday, November 29th, 2007

Is Microsoft quietly phasing out IE6? I think could mean the beginning of the end for IE6 installs and support.

Internet Explorer 7 now available for pirated version of Windows XP

Safari for Windows

Monday, June 11th, 2007

I am currently writing this post on Safari on XP. The first thing I did was to check the navigator.userAgent js property.

I don’t know about everyone else out there, but seeing “Windows NT” and “Safari” in a userAgent property is something that I didn’t expect. It gives me both the creeps as well as a little excitement on what’s to come. Excitement would be more users submitting bugs to apple on this browsers crappy editable html javascript implementation, maybe this will get AppleWebKit to fix the bugs faster. What gives me the creeps is it gives me another platform our websites should run under… bittter sweet.

You can download the public beta here.

Update: It seems like most of the showstopper bugs are fixed with this version. With just a little push this very might well be a very good release.

UPDATE II: So I can’t maximize Safari on my RIGHT MONITOR… it just dissapears. Is that Apple trying to send a political subliminal message? ;)

Firefox-like Inline Search for IE7

Monday, February 12th, 2007

From description:

Inline Search is an add-on for Internet Explorer that mimics Firefox’s search behavior, it turns searching into a Web page into a non modal research experience coupled with a search as you type facility. It integrates into IE, giving it that little extra that makes you a lot more efficient when you are looking for a specific piece of information. Version 1.3 may include unspecified updates, enhancements, or bug fixes.

Details

Flashblock

Wednesday, June 28th, 2006

I just installed this extension, it works pretty good when browsing ad-heavy sites.

The way it works is it overlays a clickable icon where ever there’s a flash movie. Installing is easy, just download and install this file.

Jaime

Http Headers Debugging with ieHTTPHeaders

Wednesday, April 26th, 2006

This one’s similar to LiveHTTPHeaders for FireFox. IE’s handling of headers is sometimes different than FireFox so it’s always nice to see what’s going on under the hood:

ieHTTPHeaders is an Explorer Bar for Microsoft Internet Explorer that will display the HTTP Headers sent and received by Internet Explorer as you surf the web. It can be useful in debugging various web-development problems related to cookies, caching, etc.

Tip: Once installed, the plugin can be accessed through the View > Explorer Bar menu.

Listamatic

Monday, February 27th, 2006

Listamatic is a list definitions repository.

You can view many different types of list definitions here. It just goes to show you the many different ways in which you can write a list through CSS. You can submit your own for others to use as well.