JavaScript toggle code

I’m just saving this for myself for future design possibilities… The script that goes in the head:

<script type="text/javascript">
<!-- 
// toggle visibility 

function toggle( targetId ){ 
  if (document.getElementById){ 
        target = document.getElementById( targetId ); 
           if (target.style.display == "none"){ 
              target.style.display = ""; 
           } else { 
              target.style.display = "none"; 
           } 
     } 
} 
-->
</script>

Sample code showing usage:

<h3>Blogs I Read <a href="#" onclick="toggle('outside2');return false;" title="Toggle BlogRoll">(show/hide)</a></h3> 

    <div id="outside2"> 
        <h1><a href="http://www.google.com" title="google.">Google Search</a><br /> 
        <a href="http://www.google.com" title="google.">Google Search</a></h1> 
        <div class="dailyphoto"><!--#include virtual="/daily/dailyphoto.inc"--></div> 
  </div> 

<h3>Blogs I Read <a href="#" onclick="toggle('outside3');return false;" title="Toggle BlogRoll">(show/hide)</a></h3> 

    <div id="outside3"> 
        <h1><a href="http://www.google.com" title="google.">Google Search</a><br /> 
        <a href="http://www.google.com" title="google.">Google Search</a></h1> 
        <div class="dailyphoto"><!--#include virtual="/daily/dailyphoto.inc"--></div> 
  </div></div>

(via Joel Blain)

iTunes: “World, The” by Quest from the album Essential Chillout (2000, 4:17).

I’m too sexy for my blog

New tagline for the blog went up today. Inspiration should be blatantly obvious (at least if you’re into early 90’s one-hit wonders). ;)

Besides, I was bored.

This did, however, inspire some new shirts now available for sale through CafePress:

I'm too sexy for my blogI'm too sexy for your blog

To the left, the “I’m too sexy for my blog” t-shirt. Let your ego go wild, show of just how good you are! You deserve it!

And on the right, for those people who don’t deserve to be graced by your presence — the “I’m too sexy for your blog” t-shirt! Face it, some blogs just aren’t worth your time. Don’t be shy about it — announce it to the world!

Or not.

You know.

Whatever. ;)

I just do these things because they amuse me.

iTunes: “I’m Too Sexy (Catwalk)” by Right Said Fred from the album I’m Too Sexy (1991, 7:51).

Blog of the Month

This was nice — I got picked as “Blog of the Month” by AndrewBlog:

This is a beatiful blog with amazing content and a superb layout. Michael Hanscom is bringing blogging to the next level with this site. He has a firm commentment to his blog (this is the guy whogot fired from Microsoft for his blog).

Thanks, Andrew!

Some slight design tweaks

I’ve done a little light fiddling with the design here in order to clean up some details that had been bugging me.

I started by adding a light grey background to blockquote elements in order to make them a bit more distinct from my babbling. That ended up making the page feel a bit heavier than I wanted, though, as the lightest grey I could use was the same grey that made up the background color in the lower section of each post’s title bar.

After fiddling with a few different approaches, I finally decided to use a slight gradient rather than a solid grey for the title bar, starting darker on the right and fading to white towards the left. The blockquote elements still felt a bit much, though, so I ended up creating a second, lighter gradient to use for their background as well. I’m not entirely sure I’m satisfied with the end result — while I like each effect individually, I’m not as sure about how they interact with each other on the page. Still, it’ll do for now.

Left and right floating elements (such as pictures and Amazon item links) have been nudged a few pixels outward in order to better align them with the outside borders of the post title bars.

Lastly, I removed the grey background behind the post titles and replaced that with a drop shadow effect behind the title text. The one downside to this approach is that it’s currently only visible in Safari (I believe), as Safari’s currently the only browser (that I know of) that supports that particular CSS attribute. The rest of you just need to upgrade. ;)

2004 Photography Calendar

2004 Wall Calendar

While I’m certainly not a professional photographer by any means, I do enjoy experimenting with photography, seeing what I can come up with, and occasionally coming up with a decent shot or two. I’ve just selected twelve photographs from my collection, and added two new items to my CafePress shop: a 2004 Wall Calendar featuring those photographs, and a full year calendar featuring a shot of Post Alley, near the Pike Place Market here in Seattle.

Oh, and the full selection of “I’m just here to get laid.” shirts are, of course, still available. I thought for sure I’d have sold more than one by now — maybe it’s not as generally funny as I think it is…;)

The biggest cause of failure is success

Mike is doing some brainstorming on how to predict and cope with bandwidth spikes when a post or page suddenly becomes a popular destination.

When a blogger’s work becomes successful enough to, for a moment, graze the underbelly of commercial publishing, it threatens the very low-cost predicate of the publication itself.

>

Setting aside for the moment the absurdity of the situation, which is clear, it seems to me that over the past few years we’ve seen this exact phenomenon occur over and over again. I’m guessing, now that media people have integrated the blogosphere into their information gathering practices, we’ll see it with greater frequency and to more devastating effect over time.

My bandwidth as of 11/23/03As I recently discovered, this is a very real worry. I’d joked in the past about the “perfect post”, that one blog entry that suddenly exposes a site to the world and brings in all the traffic that so many people wish that they had — but actually stumbling upon that “perfect post” has made it very clear just how much of a double-edged sword that can really be.

In Mike’s ruminations on how things like this can be coped with, he mentioned something that sounded like a possibility…

…I think there is a proactive business opportunity for the right business to defray these transient bandwidth costs, probably in the form of short term ads on the sites that are experiencing the bolus. […] I will note that it might even be cooler yet if this feature enabled Google keyword ads. Maybe it should be an independent service, or a program that the keyword service provides for bloggers, who are currently more or less specifically discouraged from using it.

I applied for Google AdSense at one point, but they turned me down. While it was a bit of a bummer, it wasn’t much of a surprise, as Google doesn’t seem to want to accept most weblogs into their AdSense program. It seems that if you run a very tightly-focused weblog on a specific topic (such as PVR Blog or Daring Fireball) you’ve got a good chance of being accepted, but less-focused weblogs (such as mine, yours, the one you’re going to read next, or the other 99% of the blogosphere) will be denied. Unfortunately, the exact methodology or reasoning behind the approval/denial process is more than a little unclear.

There’s a far more serious problem with AdSense, though. The approval system is capricious, even arbitrary. It’s understandable that Google wants to make sure sites aren’t just ad farms, and it’s in everyone’s interest that quality be maintained, ideally by human verifiers. Nobody wants to see those sad Red Cross PSAs that take the place of house ads on poorly-indexed sites.

>

The human verification process at Google, though, is uncharacteristically opaque. I’d assume they factor in the ads which would run on a site before approving or denying an application, and if I take a look at , I see some of value. Ads specifically targeted to weblog software, Manhattan computer repair, New York hotels. These all seem relevant and valuable to me, but I’ve been repeatedly rejected.

>

It’s not just sour grapes on my part. Take NYC Eats, a great little niche weblog. Aaron’s brilliant little AdSense senser shows , which makes sense since the letters “NYC” by themselves cost two dollars a click. But no AdSense approval there. The problem is the wording in theprogram policies:

>

In general, we do not accept personal pages, chat sites, or blogs into the AdSense program. However, if a site contains targeted, text-based content and/or provides a product or service, we may consider it for participation.

In a perfect world (well, my perfect world, that is), of course, Google would open up their AdSense program to the weblogging world at large. While their AdSense ads might be a little random on the main page of a site due to the random nature of the main page posts not giving clear, concise keywords to work with, if a site design includes individual archive pages than each individual post should have enough keywords to target a specific ad category (my Mac-specific posts would get Mac-centric ads, my political posts would get political-centric ads, and so on).

If they don’t want to do that, though, what if Google set up an agreement with TypePad (or other for-pay hosting sites) in which, in order to offset the cost of bandwidth spikes, Google AdSense ads could be (semi-)automatically added to a site when they reached a certain bandwidth point (90% of their available monthly bandwidth per their agreement, for example)? Each auto-generated template could include code something along the lines of <$MTAdSense><!-- include "/ads/google/adsense.inc" --><$/MTAdSense$> that would be automatically triggered by the TypePad servers when bandwidth exceeded whatever the cutoff point was. Any revenue generated by clicks on the ads would automatically be siphoned to TypePad and applied to offset the costs of the extra bandwidth usage during the spike.

There could even be a toggle in the TypePad preferences that allowed a site author to insert a “registration key” if they were accepted by the Google AdSense program that would enable the AdSense ads on a full-time basis. In this case, Google would send any revenue to the site author as per their usual setup, instead of sending it to TypePad.

Just an idea. Workable? I haven’t got a clue — barriers include the coding of the feature (while I’m no program-level coder, it doesn’t strike me as being too terribly difficult of a feature to enable), inclusion of the feature into already-existing weblogs (not difficult for TypePad Basic, Plus, or Pro levels using the auto-generated templates, Pro levels using advanced templates would need to add the requisite code themselves), and — most importantly (and possibly most difficult) — Google and TypePad (or, of course, whatever other hosting service that might be interested) negotiating the partnership. Still, if it could be worked out, I think it could be useful and beneficial to the blogging community at large.

Just when things were starting to settle down

Earlier this week, I started noticing something odd. It had finally been long enough since my fifteen minutes of fame that traffic was starting to come back down to a more normal level. Oddly, though, for the past few days I’d been getting a lot of hits from the article in the Seattle P-I about my situation. Obviously, it had been linked somewhere with a decent amount of traffic — but where?

Today, the mystery was solved, thanks to an e-mail from Mike: It turns out that Blogger has posted a new tech support article entitled “How Not to Get Fired Because of Your Blog” which links to the Seattle P-I article.

Do you blog at work? Do you check your referrer logs and surf the blogosphere all day from your office? Do you think it might be funny to mock your co-workers publicly, or that it could be a good idea to post photos of sensitive corporate information on your blog? If only Blogger Support could have reached this unfortunate Blogger sooner. Folks, this doesn’t have to happen to you.

These days, many companies are blog-friendly because they recognize a valuable tool for communication and the sharing of ideas when they see it. However, as with any public medium, care should be exercised from time to time. Here at Blogger, we want you to keep your job and as always, ending your blog should be a last resort reserved only for woeful situations. Fret not gentle blogger, we’ve put together this document to help you keep those paychecks rolling in.

So, apparently I’ve been immortalized by Blogger’s tech support crew, which is resulting in a fair amount of traffic moving from Blogger to the Seattle P-I, and then from their article back to me. Well, hey, any traffic is good traffic, right? ;)

Additionally, I got this in my e-mail today:

From: sinta
Subject: Your blog on CNN
Date: November 22, 2003 11:53:20 PST
To: Michael Hanscom

Hiya Michael

Just want to point out to you that your blog was shown on CNN Global Business just today at 7:30 Swiss time :) It just finished a few minutes ago. They talked about that Microsoft incident you had a while back :)

Just thought you’d like to know ^_^

Bestest regards from Switzerland,
Sinta~

http://www.lockload.com
The one and only He Says, She says double blog.

Apparently, my story is (for the moment) the Energizer Bunny of blogging stories — it just keeps going, and going, and going, and going…

Update: Many thanks to Sudheer from in Beijing for sending me a link to the online version of the CNN piece: The Budding Blogs of Business! Here’s the relevant bit:

Microsoft has taken a benevolent attitude to blogging. But it balked when an employee revealed on his blog how the company had taken delivery of a shipment of Apple computers. He was quickly relieved of his duties.

GeoURL

Prompted by the Localfeeds Seattle service (which gives me an RSS feed of weblog posts from people close to me in the real world), I’ve just added my GeoURL location identification to my main page — I had it on my old Long Letter blog, but hadn’t thought to put it in here on Eclecticism yet. Silly me.

This post is mostly here to give me an excuse to post the GeoURL button, which allows me to see who’s near me in the real world.

Feed of the day

Nifty — I have no idea what the selection criteria is (quality? frequency? content? entirely random?) but it seems that I’m being highlighted as “Feed of the day” on Feedster. So…hello to all of you who wander my way!