Add To Favorites (IE)

<a href="http://site.com" onclick="window.external.AddFavorite(this.href,this.innerHTML);">Add Favorite and Go-To-There</a>

The first param to AddFavorite is the URL, the second the text to offer up for saving. So this inline JavaScript is reusable in the sense that it will pull those values dynamically from …

Avatar of Chris Coyier
Chris Coyier on

Responsive Data Tables

Tables of data can only squish horizontally so far, so they can be a pain to browse on small screens (like mobile devices) where you may need to scroll both horizontally and vertically to browse the information at readable text sizes. We'll explore a CSS-based possible-solution to this issue.
Avatar of Chris Coyier
Chris Coyier on (Updated on )

New Poll: Working Environment

The new poll (in the sidebar) asks:

In what environment do you primarily work?

I’ve worked from home for a lot of years but that will soon be changing. I’m interested to know the environment readers of this site work …

Avatar of Chris Coyier
Chris Coyier on (Updated on )

CSS Gradients from Image

Direct Link

Nicole Sullivan thinks “wouldn’t it be a nice if there was a tool to convert an image of a gradient into CSS code?” The community responds with some newly-created tools to do just that. I couldn’t get either of the …

Avatar of Chris Coyier
Shared by Chris Coyier on

CSS Stress Testing

Direct Link

Bookmarklet from Andy Edinborough which analyzes your page by removing class names one by one from all elements and testing the pages scroll performance. In other words, if you are having trouble scrolling a page and suspect it’s fancy CSS3 …

Avatar of Chris Coyier
Shared by Chris Coyier on

Fun With Blurred Text

We'll cover how to blur text with CSS3 and do it safely by feature-detecting first. Then we'll do a bunch of experiments with individual letter blurring and also some clever jQuery which gives us deeper access into specific values of a text-shadow.
Avatar of Chris Coyier
Chris Coyier on (Updated on )

CSS vs CSS3

Direct Link

Trent Walton designs a website then codes it up two ways: new school CSS3, and old school image slicing with no CSS3. Going new school meant 1) he could do it faster 2) the page size was smaller 3) less …

Avatar of Chris Coyier
Shared by Chris Coyier on

Move Clicked List Items To Top Of List

Assuming HTML like this:

<ul>
  <li>one</li>
  <li>two</li>
  <li>three</li>
</ul>

So if “Two” is clicked, move it to the top of the list.

$("li").click(function() {
     
  $(this).parent().prepend($(this));
  
});

Will work for multiple lists……

Avatar of Chris Coyier
Chris Coyier on