Posts Tagged ‘shorten’

Javascript: Shortening a breadcrumb using JQuery

Wednesday, January 27th, 2010

A lot of sites these days use breadcrumb trails to make navigation easier for their users. This is essentially a list of every parent category/section of the page you're on, and might look something like this:

Home > About us > Meet the team

Each of these is typically a hyperlink back to the relevant section. Now these are great, but what happens if your breadcrumb isn't that small? It's easy to see a situation where you have a bunch of really long titles that cause the breadcrumb to span over two or three lines. This isn't always what you want, since it can make the breadcrumb look broken. You might just decide to make some of the titles smaller, but with content managed sites and page names stuffed with SEO keywords, this is often easier said than done.

(more…)