<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <title>Snipplr</title>
    <description>Recent snippets posted on Snipplr.com</description>
    <link>https://snipplr.com/</link>
    <lastBuildDate>Tue, 09 Jun 2026 15:08:11 +0000</lastBuildDate>
    <item>
      <title>(jQuery) Call a function on an anchored object - dougunderscorenelson</title>
      <link>https://snipplr.com/view/17681/call-a-function-on-an-anchored-object</link>
      <description>&lt;p&gt;Sometimes you click a link like faq.html#item5 and, after the browser jumps you to the anchor, you have trouble spotting the item you're looking for. anchorAway is a little function that helps you call a function on anchored items, maybe something like a scrollTo or a background color, that helps users easily spot the content you directed them to.&#13;
&#13;
anchorAway parses the window.location for an anchor (#foo), finds it, and calls the function (act(bar)) on it. It also finds any on-page links to the objects you've specified and binds the same function to their click event.&lt;/p&gt;</description>
      <pubDate>Thu, 30 Jul 2009 10:44:09 UTC</pubDate>
      <guid>https://snipplr.com/view/17681/call-a-function-on-an-anchored-object</guid>
    </item>
    <item>
      <title>(jQuery) Has the image loaded? - dougunderscorenelson</title>
      <link>https://snipplr.com/view/16307/has-the-image-loaded</link>
      <description>&lt;p&gt;Used this on a project to determine whether images were loaded or not. In an image carousel, for example, you could test the next/clicked image before advancing the slide, and if 'loaded' wasn't 'true', you could add a "loading" class and attach a new .load handler to remove the class and advance when the image finished loading.&lt;/p&gt;</description>
      <pubDate>Thu, 25 Jun 2009 12:35:43 UTC</pubDate>
      <guid>https://snipplr.com/view/16307/has-the-image-loaded</guid>
    </item>
    <item>
      <title>(jQuery) Get index of the current element. - dougunderscorenelson</title>
      <link>https://snipplr.com/view/15788/get-index-of-the-current-element</link>
      <description>&lt;p&gt;Quickly get the index of the current element. I find myself re-using this several times in a document, so I made a lil' function for it.&lt;/p&gt;</description>
      <pubDate>Tue, 09 Jun 2009 20:56:34 UTC</pubDate>
      <guid>https://snipplr.com/view/15788/get-index-of-the-current-element</guid>
    </item>
    <item>
      <title>(jQuery) Wrap Your HRs for Easy Stylin' - dougunderscorenelson</title>
      <link>https://snipplr.com/view/14548/wrap-your-hrs-for-easy-stylin</link>
      <description>&lt;p&gt;HRs are a pain in the ass to style, so why bother? Wrap them in a DIV with a class of HR instead. (In your stylesheet, set .hr hr { display: none }).&#13;
&#13;
This also ports the class of the HR up to the new parent DIV, allowing you to make a few different HR types that clients can easily work with.&lt;/p&gt;</description>
      <pubDate>Tue, 28 Apr 2009 18:03:32 UTC</pubDate>
      <guid>https://snipplr.com/view/14548/wrap-your-hrs-for-easy-stylin</guid>
    </item>
    <item>
      <title>(jQuery) Adding a Focus class to Forms - dougunderscorenelson</title>
      <link>https://snipplr.com/view/14547/adding-a-focus-class-to-forms</link>
      <description>&lt;p&gt;This adds a class to focused form elements (helpful for IE6/7), as well as adds a class to the input's parent (in this case, named "form-field").&lt;/p&gt;</description>
      <pubDate>Tue, 28 Apr 2009 17:59:35 UTC</pubDate>
      <guid>https://snipplr.com/view/14547/adding-a-focus-class-to-forms</guid>
    </item>
    <item>
      <title>(jQuery) Wrap the insides of Buttons - dougunderscorenelson</title>
      <link>https://snipplr.com/view/14546/wrap-the-insides-of-buttons</link>
      <description>&lt;p&gt;Quick script to find button elements (and elements with the "button" class) and wrap their innards in spans. Good for making rounded-corner buttons.&lt;/p&gt;</description>
      <pubDate>Tue, 28 Apr 2009 17:57:12 UTC</pubDate>
      <guid>https://snipplr.com/view/14546/wrap-the-insides-of-buttons</guid>
    </item>
  </channel>
</rss>
