If..Else Log

Quashing procrastination (and uncovering a bug)

Safari and unclosed tags

Here's a rather annoying little bug that I've just fixed. A few people kindly pointed out that the whole body text would be underlined when you hover over it in Safari.

Not the nicest thing to view and definitely not an intended effect. Without a mac at hand, I had to use a bit of deductive reasoning to track down the issue. However, the markup validated, the CSS had nothing suspicious and the only time underlines were used were for anchor elements. Firefox and IE had exhibited no such symptoms so it was not the easiest thing to hunt down.

And then my eyes opened

And it then occured to me that I had used a self closing tag for an anchor elements. There should be nothing wrong with this of course. XHTML allows the provision of self closing elements and I'd used this for a quick link to the top and bottom sections as thus:

<a name="top" />

But not Safari. Safari would treat it as unclosed and thus apply the hover rule to the whole block. Explicitly closing it as thus fixed things.

<a name="top" ></a>

Let me know if anyone still experiences any problems.

Update: It turns out that I'm an idiot and this anchor was unnecessary.

Waking up to deadlines

Khaled recently wrote about the value of deadlines in focusing your attention so as to get things done. In his case, the impending close date has brought with it a sharp, wake up call for him into a 2 day crunch session to get things ready.

Deadlines are not bad things. Used properly, They provide a goal to work towards, and provide a measure with which we can prioritise things. By placing a constraint on what we've got to work with, it gives an incentive to start deciding what is important, and what is not.

In the absence of…

But not all things in life have deadlines, or at least not fixed in the ground ones. Tidying up the house, working on a personal project, learning a foreign language, revision; being of a personal nature, there isn't the long and definite deadline that would provide the same sort of focus.

I've been guilty of this in the past. Attempting to set a deadline for these types of tasks is often self defeating. The very lack of an immediate and external grounding for that deadline means that they are easily and often ignored.

The only way to really overcome such procrastination is to keep moving. Everyday I do a little bit more than the last. Sometimes it's a lot more; sometimes it's a trivial amount. It might be stacking up a pile of books, learning one new phrase or tidying up a colour choice. Doesn't need to be a big step, as long as it is a step.

With every little step, we're getting a little further along.

-30-

7 Responses to “Quashing procrastination (and uncovering a bug)”

  1. Gravatar Mathias Bynens July 1st, 2005 11:51 am

    <a name="top"></a> sounds evil. What on earth would that be good for?

  2. Gravatar Phu July 1st, 2005 6:43 pm

    “What on earth would that be good for?”
    I’m using it as a “skip to content” link on the front page. There’s an equivalent “skip to navigation” link to jump to the bottom.

  3. Gravatar Shaun Inman July 1st, 2005 8:17 pm

    Did you know you don’t even need that anchor, Phu? You already have an element (a <div>) with an id of “top” in your mark-up. An link pointing to “#top” should go to that element in all modern browsers, no named anchor necessary.

  4. Gravatar Phu July 2nd, 2005 12:47 am

    “Did you know you don’t even need that anchor, Phu?”
    I guess the answer to that would be an embarrassing and sheepish no:-) Thanks Shaun.

  5. Gravatar Mathias Bynens July 2nd, 2005 8:29 am

    Yeah, that’s what I was saying. Oh well.

  6. Gravatar Phu July 2nd, 2005 11:20 am

    Ah sorry, Mathias, I didn’t realise. Cheers:-)

  7. Gravatar Jules September 6th, 2005 6:35 pm

    Shaun, unfortunately Safari seems to be the exception–targeting a specific anchor within a div does not seem to work in Safari.
    I’ve been looking for a fix, anyone?