Tuesday, October 09, 2007
If you have floated boxes followed by a cleared box, firefox will not honor margin-top on that box.

Here is a page demostrating the firefox bug (pops)

I think Firefox is assuming that the extended margins of float left and right apply to cleared boxes, while the specs do not say or imply that. Here is the relevent section from the spec for the clear property:

left
The top margin of the generated box is increased enough that the top border edge is below the bottom outer edge of any left-floating boxes that resulted from elements earlier in the source document.
right
The top margin of the generated box is increased enough that the top border edge is below the bottom outer edge of any right-floating boxes that resulted from elements earlier in the source document.
both
The generated box is moved below all floating boxes of earlier elements in the source document..
none
No constraint on the box's position with respect to floats.

Here is a baseline html/css sample:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head>
<title>Firefox css bug</title>
</head>
<body>
<div id="container">
<div style="background-color: Orange; width: 100px; height: 35px; float: left">
</div>
<div style="background-color: green; width: 100px; height: 35px; float: left">
</div>
<div style="background-color: black; width: 100px; height: 35px; clear: both; margin-top: 30px;">
</div>
</div>
</body>
</html>


Posted By: Chris Burkhardt on October 9, 2007  #    Disclaimer  |  Comments [0]  | 
 Wednesday, October 03, 2007
I just spent about 4 hours trying to debug this problem.

Here is the setup, a user with a slow connection was not able to view a .wmv on a site. The .wmv was 250mb and he was timing out at 11:34. Different browser, different computer, all that jazz. Our site runs on iis 5 with .NET 2.0 and the file is "hotlinked". That is, we are not using any kind of Response.Write to write to the stream, just linking to it and letting the client stream or download it.

I got a hold of dialup computer and account, and I was able to reproduce the problem, getting the server to send a RST about 15 minutes after starting to download the file. This looked like the .NET  Connection Timout setting, which is set to 900 seconds, or 15 minutes, as a default in iis 5.

However, when I made a new site to test this theory, setting the timeout to 20 seconds did not affect it at all. In fact, in the test site, I was not even able to reproduce the error. Besides, why could the .NET Connection Timeout have anything to do with iis sending the file over the wire?

After a ton of debugging, I found the culprit, wildcard application mapping.





The wildcard application mapping was telling .NET to handle ALL files. Because .NET was handling the file, the 900 second timeout was coming into play. This was a requirement for another part of the site to function, so we could not turn it off. What we ended up doing was making the "media" folder, where the wmv lived, its own application, and removing the mapping from there.

This solution was a lot better than upping the timeout because we didn't not want abandoned connections sitting around for ever.

Posted By: Chris Burkhardt on October 3, 2007  #    Disclaimer  |  Comments [0]  | 
 Thursday, September 27, 2007
Yesterday I posted about how I got ScribeFire to work with dasBlog. Today I will go into a little more detail, complete with pictures.

To start, under the "Blog" section, choose Add.

Step 1 -- Choose "Manually Configure"
ScribFire step 1

Step 2 -- Choose "Custome Blog"
ScribFire step 2

Step 3 -- Choose "MetaWeblog API" and enter the url of your blog + "blogger.aspx"
 ScribFire step 3

Step 4 is login, you don't need an image for that, just enter your credentials.

Finally, you should see your blog added to ScribeFire:
ScribFire step 4


Next, remove the auto-inserted ad "Powered by ScribFire". Click the "<<" in the upper left like so:
ScribFire step 5

This will open the options. Choose settings and uncheck"Automatically insert 'Powered by ScribFire'", like this:
ScribFire step 6

I really enjoy this firefox add-on. I added and edited this post from within firefox, and it seems a little snappier that the default editor in dasBlog.

Posted By: Chris Burkhardt on September 27, 2007  #    Disclaimer  |  Comments [0]  | 
According to the Live Search blog the live search I was complaining about before should be updated. Let's see if its fixed.

I guess the answer is, it depends...

Here is a shot on a search I just did for "your doing it wrong"


Look at the results, the #1 result is from 2003 and doesn't even include my search terms! The 5th result, and the 3rd site returned, is from 2005, and it is a forum post from some second rate hit counter. The post is 2 messages long! Here is what you see if you follow the webstat link:


That is what happens if I go to live.com and search.

However, it looks like I can access the new search if you append &FORM=PRESS. So if you use this query you can see the new and improved results. And they are indeed new and improved. The results are more topical, and they include my search terms. However, you have to either follow a link from a press release with the &FORM=PRESS or you have to know enough to put it on. Anyone who just types live.com, or live.search.com gets the old stuff. I don't know why, but it is typical Microsoft in the past 5 years. Shout about some new, cool thing and then it doesn't work or it is inaccessible.

By the way, here is a picture of the kind of thing I was searching for. I think its funny, and I guess so do the people at this site



Posted By: Chris Burkhardt on September 27, 2007  #    Disclaimer  |  Comments [0]  | 
 Tuesday, September 25, 2007
I recently switched this blog to dasBlog and I had a nice little firefox addon called ScibeFire that I could not get to work with it. Thanks to Kelly Keeton for the tip that made the connection in my head.

My confusion was the end point on dasBlog is called Blogger.aspx, but the type (API) is MetaBlogAPI, so when setting up the blog in ScibeFire you have to choose Manually Configure-->Custom Blog-->MetaBlog API then put in <%yourBlogPath%>/blogger.aspx.

Then it works great. In fact, this is my first post from ScribeFire.


Edit: The only problem is ScribeFire appends an ad to your post. To disable the add/trackback, click the ">>" in the upper left, choose "Settings" and uncheck "Automatically insert' Powered by ScibeFire'"
Posted By: Chris Burkhardt on September 25, 2007  #    Disclaimer  |  Comments [0]  | 
 Thursday, September 20, 2007
I'm a Microsoft guy, a fan, supporter whatever. I've been programing with Microsoft for Microsoft almost since I got my start. I want MS to do well so I do well, which is why their live search pisses me off. It's not very good in general, but when I see things like this, it makes it worse:




It's fixed now, but a search for "Your doing it wrong" shows 0 results on Live (Live Search?) and 69 Million on Google. I was using IE7 with Live as the default provider, and immediately switched.

Even now that live search returns results, they suck. Compare Live Vs Google


Posted By: Chris Burkhardt on September 20, 2007  #    Disclaimer  |  Comments [0]  | 
 Saturday, March 24, 2007

It seems a new feature fo MSSQL 2005 is that any new accounts have to change their password at first logon. This is kind of a pain, since most people don't 'logon' to their accounts, at least for me because I do web programming. How is my website going to change its password?

Luckyliy I found a must change post with some tsql to do the trick:
ALTER LOGIN X WITH PASSWORD = 'Y'

That bit will unlock the account so you can use it.

I'm not a tsql guy, so maybe this is easy for some people, but for a guy just trying to store some information in a DB, this was a pain. It made a routine task of setting up a user into a 30 min hair tear.

Thanks to Peter for the tip.

Posted By: Chris Burkhardt on March 24, 2007  #    Disclaimer  |  Comments [0]  | 
 Wednesday, February 28, 2007

Maybe that is easy for some css gurus to remember, but I always have trouble getting it to work. Use the style vertical-align: top to align inline children elements of a block parent.

Here is a sample that should illustrate:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head >
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"></meta>
    <title>Text Align Test</title>
</head>
<body>
    <div>
   
    <div style="height: 100px; width: 300px; background-color: teal; vertical-align: top;">
            <span style="background-color: red; font-size: 28px;">Align This</span>
            <span style="background-color: #00A4FF;">Inline</span><br />
            Next Line
    </div>
   
    <div style="height: 100px; width: 300px; background-color: teal;">
            <span style="background-color: red; font-size: 28px;">Align This</span>
            <span style="background-color: #00A4FF; vertical-align: top;">Inline</span><br />
            Next Line
    </div>
    </div>
</body>
</html>

Posted By: Chris Burkhardt on February 28, 2007  #    Disclaimer  |  Comments [0]  |