Don’t tell Sprint, but when I bought my Treo, the sales clerk was very cool. He made a point to inform me that it costs extra to download ringtones and games from the Sprint site, and then wrote the URL to mbuzzy.com on my receipt. I had never heard of it. Have you?Personally, I’m satisfied with the rings that came with the phone, and I deliberately steer clear of the games (I’d never get any work done. Really.), so the site’s not very useful to me. But I did finally check it out, and it does live up to his word. It’s a freeware/shareware site for cellphone users in a land where cellphone companies try to charge for every bell and whistle. They require that you sign up for an account before downloading, but most everything there is free. Of course, you need to have a way to get these items onto your cellphone, and if you don’t have a USB cable or internet access included in your system, freedom only goes so far. But really, it’s the thought that counts.Enjoy!p.s. (I recommend the “Sexy You Have Mail” ringer. Just to impress your friends.)
When I’m a fool, I feel the need to make a public announcement about it. Let the whole world know where I screwed up, so the rest of its inhabitants won’t make the same mistake. Here’s my confession: I doubted technology. And I was wrong to do so.My graphic designer approached me this week and asked me to build the navigational structure for a complex website. “Oh,” he added, “and the client wants Javascript breadcrumbs, so you should work that in.” What? Javascript breadcrumbs!? You can’t use Javascript to make breadcrumbs! You need to use a content management system, so a database knows where all your pages are in relation to each other and can regurgitate the info as needed. The only other solution is to hard-code the breadcrumbs! How can Javascript know what the hierarchy of your site looks like?! It can’t be done!I ate my words an hour later. Stuck my foot in my mouth while I was at it, too. Just for good measure. So let’s back up and make sure we’re all on the same page.What are breadcrumbs?What are breadcrumbs? Breadcrumbs are the “You Are Here” links you sometimes see at the top of a webpage. They might look something like this:
In this example, you’re probably looking at the “Our Staff” page. It doesn’t matter how you got there; these links will appear the same. The site wants to let you know that “Our Team” is under the category “About Us,” which is all under the big picture of “Home,” and you can click those links if you want to get to those pages. This is an important distinction because “breadcrumbs” is actually a misnomer. It’s not about leaving a trail so you can go back the way you came (although that’s often how it works out). It’s actually about being able to easily navigate to broader categories for the webpage you’re currently visiting. But enough theorizing. Let’s talk about how this works.How Do Breadcrumbs Work with Javascript?This is where I was completely caught off guard. In order for Javascript code to be able to display breadcrumbs, it needs to be able to see the structure of your website as it relates to that page. What’s the easiest way to show the structure of your site on each webpage? Use the URL! (Duh! I really should have seen that one coming!)So, back to our example. If we want our breadcrumbs to look like this:
We need our URL to look like this:
http://www.ourdomain.com/about_us/our_staff.html
The key is that the website needs to be organized in very specific folders that describe the categories. We define everything up to “.com” as “Home,” and then everything after that is named by folder and filename (or page title, as it turns out with this script). We tell the code to translate underscores as spaces, capitalize the first letter of each word, and take care of any other standard replacements we can see coming. The code takes care of the rest! Incidentally, if you want to see the “About Us” page, the URL could be this:
http://www.ourdomain.com/about_us/index.html
or this:
http://www.ourdomain.com/about_us.html
If “About Us” is a category for more things, it will make more sense to use to first one. Otherwise, the second will do. But these are just tips. Let’s get to the code.Javascript Breadcrumbs – The CodeI dug through the web and tried about 10 different versions of Javascript breadcrumbs code. This was the first code that actually worked well without glitches, and allowed for some good customization. I found it on a listserv discussion at the Louisiana Tech University website. I have no idea where this originated, except that Harry Love of the University of Washington is credited in the file.The code I’m using is rather long, so I’ll just post a link.
Wow, that late-night Castro adventure wiped me out for most of the week. I meant to get these up sooner. Here’s my set of Halloween pictures, available on flickr:http://www.flickr.com/photos/92992685@N00/sets/1284222/See if you can find me!
Posted in