Fork me on GitHub

jQuery Upvote - a voting plugin

jQuery Upvote is a plugin that generates a voting widget like the one used on Stack Exchange sites.

Examples

stackoverflow.com

unix.stackexchange.com

programmers.stackexchange.com

serverfault.com

Markup ("read-only" examples)

Basic

5
<div class="upvote">
    <a class="upvote"></a>
    <span class="count">5</span>
    <a class="downvote"></a>
    <a class="star"></a>
</div>

Upvoted

6
<div class="upvote">
    <a class="upvote"></a>
    <span class="count">6</span>
    <a class="downvote"></a>
    <a class="star"></a>
</div>

Downvoted

4
<div class="upvote">
    <a class="upvote"></a>
    <span class="count">4</span>
    <a class="downvote downvote-on"></a>
    <a class="star"></a>
</div>

Upvoted and starred

6
<div class="upvote">
    <a class="upvote"></a>
    <span class="count">6</span>
    <a class="downvote"></a>
    <a class="star star-on"></a>
</div>

unix.stackexchange.com style

4
<div class="upvote upvote-unix">
    <a class="upvote"></a>
    <span class="count">4</span>
    <a class="downvote downvote-on"></a>
    <a class="star"></a>
</div>

serverfault.com style

6
<div class="upvote upvote-serverfault">
    <a class="upvote"></a>
    <span class="count">6</span>
    <a class="downvote"></a>
    <a class="star star-on"></a>
</div>

Links