November 2001

11/29/2001 Thursday

Are you an e-bore? (via Tijs.org)
09:30 permalink

Tempest for Eliza controls your monitor to send out AM band radio signals. Reminds me of the C64 program that would use your disk drive to play Bicycle Built For Two. (via Blogdex)
09:10 permalink

Something is up with the flash detect scripts - getting bug reports from people with IE6. Will try to get to fixing the issue today. Bear with me. Update: I fixed the problem. Was a variable scoping thing from when I rewrote the scripts a month ago. Damn. Sorry. As an aside, I played around with doing an all-Javascript detect. Currently, the IE portion of the detection is in VBScript and, because it is logically separate from the Javascript portion of the script, this is why there was a scoping issue - the variable that tracked the Flash version number had to be global, not local. In VBScript, you attempt to create an ActiveX component with CreateObject("ShockwaveFlash.ShockwaveFlash.5") and then check to see if the result is an object (which denotes success and that version of Flash is installed). The Javascript equivalent is new ActiveXObject("ShockwaveFlash.ShockwaveFlash.5"). If the ActiveX component isn't installed, you get an error when you try to create the object. In VBScript, you force the browser to ignore the error with the famous on error resume next. In Javascript, you can do the same by using a try-catch block but this requires IE5+. And if you are interested to limiting support to IE5+, you might as well use the clientCaps method for ActiveX component detection. So I ended up keeping the VBScript method which is supported on IE4+.
09:00 permalink

11/26/2001 Monday

In a recent Jobs Telegraph survey of people on their opinions and experiences of office Christmas parties:

  • 33% of respondents said that they or someone they know has left an office party in tears.
  • 20% will make up excuses so that they can avoid going.
  • 10% have "started relationships" at an office party.
  • 8% have handed in their resignation or know someone who has quit at an office party.
  • 6% have been fired or know someone who was fired at an office party.

(via As It Happens)
10:05 permalink

Liorean reminded me of Aaron's Sleight which fixed PNGs in IE5.5+.
09:45 permalink

11/23/2001 Friday

Testing PNG support on IE6 and Mozilla 0.9.6.
09:45 permalink

11/21/2001 Wednesday

The Nike iD site appears to have some display issues in IE5 MacOSX. Firstly, the scrollbar on the iframe is very flaky: sometimes it appears and sometimes not; if it does appear, sometimes you can interact with it and sometimes not; if it doesn't appear, sometimes it shows up later; if it appears and is active, sometimes it'll stop being active. Secondly, sometimes during a screen-refresh between choice selections, the content of the iframe is drawn to the left of the iframe. The content area in the iframe is still active as rollovers still occur and choices can still be made. After a new choice is made, the display fixes itself. It looks like a redraw problem and my hunch is that it's a bug in OSX as opposed to the browser. Now that a posting to the webdesign-L list indicates that Mozilla for OSX has redrawing issues for images in divs, I'm even more convinced that OSX has some issues.
10:20 permalink

IE5+ Win limits chaining of stylesheets using the @import to three (ie. a document can @import a stylesheet, which @imports another, which @imports another). See an example at reprocessed.org. Other browsers (Mozilla, IE5 Mac, NS6, Opera) allow unlimited chaining. (via Matt Patterson on the webdesign-L list)
10:00 permalink

How to label internal scripts and stylesheets as CDATA (as you should for XHTML) while still supporting older browsers:

<script type="text/javascript"><!--//--><![CDATA[//><!-- 
   // script contents
   //]]>
</script>
                        

(via Andrew Clover on the webdesign-L list)
09:55 permalink

To disable IE6's automatic image-save popup menu (the one that appears onmouseover), add <meta http-equiv="imagetoolbar" content="no"> to the head of your document. To disable it on a single image, add galleryimg="no" to the <img> tag. (via the ADV-HTML list)
08:45 permalink

Aaron pointed out that using document.documentElement.clientHeight to get the height of the window is not standards-compliant - it's just how you have to get the window height when IE6 is in standards mode. The real W3C-compliant method is to use document.defaultView.getComputedStyle(document.documentElement, null).getPropertyValue("height") which, apparently, works in Mozilla (though you should be able to use window.innerHeight in that browser).
08:40 permalink

11/20/2001 Tuesday

Also from Jason: the standards-compliant way to get the height of the browser window in ie6 is document.documentElement.clientHeight (instead of document.body.clientHeight).
16:55 permalink

The story so far: in Mozilla/NS6.x and IE6, the <!DOCTYPE> tag determines whether the browser uses standards or quirks layout mode. Standards mode adhers to W3C standards and quirks mode is consistent with earlier browsers. The problem with standards mode is that it adds another cross-browser authoring headache. I usually just use quirks mode to avoid dealing with having to write branching code. But I know of at least one instance where I've used a <!DOCTYPE> that should trigger quirks mode but IE6 uses standards mode and consequentially screws up the display. So it appears that you can't rely on the <!DOCTYPE> to absolutely set the layout mode. Jason McKeeman sent me a way to test for the layout mode in IE6: the document.compatMode property (read-only) will return BackCompat for quirks mode and CSS1Compat for standards mode.
16:50 permalink

Milov has a line-drawing bookmarklet that works like the drawing tool on Equill. Uses VML.
09:10 permalink

Last week, I was in a meeting with a client and we were deciding who would provide the resources that would allow our guys to work there with their guys. During this, one of their guys said matter-of-factly: "Of course, if you bring a computer, we will have to erase the hard drive when you leave." That's so insane it's cool.
09:05 permalink

Heard on the radio: "In my personal opinion, a turkey makes a lousy housepet."
09:00 permalink

11/16/2001 Friday

QA 101: A developer codes something. Said developer tests said code to satisfy themselves that it works. Developer gives code to QA. QA beats the hell out of the code to make it fail. If QA finds a problem with the code, they repeat the steps that were taken that resulted in the problem to make sure it can be duplicated. QA explores the bug by finding other ways that also trigger the problem. QA alerts the developer of the problem and includes all possible information about the problem. This includes what was expected to happen, what really happened, the steps taken to reproduce the bug, any error messages, specifics about the testing environment, variations of the bug, etc - any of this could be important. This information is needed because the developer didn't originally encounter the problem. If this information isn't present, then the developer will not be able to duplicate the bug. The developer will go through the same test procedure because they are accustomed to that procedure. And they won't find the bug because they didn't find it earlier. QA must make the developer think differently about their code.
10:00 permalink

11/14/2001 Wednesday

For some reason, clients will not be concerned about the download time of a site until after the site has been coded. File size isn't a concern when they see graphically-heavy mockups before coding begins. Based on a mockup, I can usually estimate page weight to within 20% and have warned about eventual filesizes. But it doesn't become a concern until after the mockup becomes the word of God and the pages are complete. Then I end up spending hours trimming bytes from the code. If you are lucky, you can shave about 10 - 15% of the weight off a page. This usually requires bending the design a bit and can result in code that is slower to render (which effectively nullifies your efforts). For those of you stuck in such a situation, I have written a parable:

Long ago, an Emperor summoned his greatest architects and engineers and when they had gathered, he commanded them saying: "Build me a tall tower so that I may see all of my lands and all of my peoples when I stand on the top of this tower." The architects and engineers then went away and selected a tall hill as the building site for the tower. And they collected a host of slaves and labourers to build the tower. The construction of the tower took eight years. At the end of the eighth year, the Emperor came to see the tower. When he saw the tower, he asked of the Chief Architect: "Is this tower tall enough so that I may see all of my lands and all of my peoples?" And the Chief Architect answered: "Yes, excellency." Then the Emperor asked: "How tall is this tower?" Proudly, the Chief Architect replied: "Excellency, a man must climb one thousand steps to reach the top of the tower." The Emporer was surprised. "One thousand steps? I do not wish to climb one thousand steps. Could you have not built such a tower with fewer steps?"

There is a happy ending to the parable:

Dismayed but undaunted, the Chief Architect said: "Excellency, though a man must climb one thousand steps to reach the top, to climb the tower and decend again to it's base requires but one thousand and one steps." The Emperor was puzzled. "Show how this can be.", he said. So the Emperor and the Chief Architect climbed the one thousand steps to the top of the tower. After surveying all his lands and all his people from the top of the tower, the Emperor turned to the Chief Architect and said: "I have already taken one thousand steps to reach the top. How can it be that only one more may see me back on the ground?" The Chief Architect smiled and pushed the Emperor from the tower.

09:55 permalink

11/09/2001 Friday

Tim O'Dea also reports seeing images missing in IE5.5 Win2k. While trolling my archives yesterday, I came across what might be part of the same problem: replaced images with transparent sections show garbage through the transparent sections sometimes in IE5. At the time, I thought that IE5's caching might be screwed up. I do remember that it seemed to happen more often on Win2k than NT4. It's possible that it's a memory management bug in Win2k. If that's the case, the NS4.x layer accessing problem might be caused by this, too.
09:10 permalink

11/08/2001 Thursday

Employee-generated "culture": About two months ago, someone dumped a deer trophy on Ernie's desk. Not a full head - just the horns and a bit of the skull. Everyone thought it was Sang but he denies it. It ended up on the water cooler. After someone gently suggested that it was kinda gross, someone else added a bit of rice cake that looks surprisingly like brain. It then got decorated for Hallowe'en and two deer-related Far Side cartoons have been added. As we would say, it's "for the car".
09:25 permalink

11/05/2001 Monday

IE5.5 Win2k (and perhaps other browser version / platform combos) seems to have problems loading images on page load when the cache is full. Right-clicking a non-loaded image and selecting Show Picture will load the image successfully. The full cache may also prevent viewing the document source. This is all second-hand knowledge so I haven't been able to confirm it (I'm rocking it old-skool with NT4).
10:00 permalink

Glish: NS6 doesn't allow targetting of iframes with display: none.
09:20 permalink

A List Apart: Working With Alternative Style Sheets. (via Epiphany)
09:15 permalink

11/01/2001 Thursday

Seems that some browsers see the &s in url strings as the start of character entities. If the next couple letters are identical to a character entity that the browser recognizes (minus the terminating semi-colon), those characters will be converted to the character entity. So if you have a url string like foo.html?foo=bar&amperes=5, it will be converted to foo.html?foo=bar&eres=5 because &amp; is the character entity for &. XHTML requires you to write &s in url strings as &amp; which obviates the problem. (via a WebDesign-L list posting)
11:45 permalink

Nike iD: Javascript is sufficiently powerful enough to perform all the operations that are involved in the configuration of any of the product. However, one task that is best suited to server-side code is the validation of user-entered labels that appear on the shoes. If it were to be performed clientside, the entire database of invalid words (these consist mostly of profanities and trademarks) to the client. The configurator is a heavy enough application without this data. So the validation is done on the server and the response (valid or invalid) is returned to the application. However, Javascript's networking abilities are limited to loading arbitrary urls into windows or frames and setting the src attribute of an image. To be able to sent data to the server and receive data back requires something like Brent Ashley's Remote Scripting. The technique in Nike iD is based on Brent's RSLite. An Image object is created with the src property set to the url of the serverside script that will parse the data. The data is sent as a part of a get string (a millisecond date is also appended to prevent caching of the response). The Image object is then discarded - it's fulfilled it's job of allowing data to be sent to the server. The serverside script runs and writes it's response into a cookie (the body of the returned document will be ignored by the browser). The clientside script, in the meantime, has been waiting for the cookie. As soon as it is found, the script reacts based on the value of the cookie. As long as the returned data is less than 4k, this method is perfect for remote scripting.
10:45 permalink

Archives