Error: Could not fetch http://thedevnet.com/wp-content/plugins/gd-star-rating/css/gdsr.css.php?t=0&s=a10i10m20k20c05r05%23121620243046%23121620243240%23s1pchristmas%23s1pcrystal%23s1pdarkness%23s1poxygen%23s1goxygen_gif%23s1pplain%23s1ppumpkin%23s1psoft%23s1pstarrating%23s1pstarscape%23t1pclassical%23t1pstarrating%23t1gstarrating_gif&ver=1.7.2 for caching. You might need to exclude this file in WP Minify options. The Developer Network – AJAX Star Rating

AJAX Star Rating

Use this class to update user votes and display rated content with star images.  If you want to, storethe ratings in a MySQL database given by each user that votes on content keeping track of the IP addresses of the computers from which each user votes. The class shows a row of stars to let the user vote on the content. Votes are submitted to the server via AJAX.

Directions:

  1. update database schema
  2. add database creadentions in the RatingManager.inc.php
  3. Since this is user id based create $_SESSION['USERID'] = ’sudhir’; session variable and remove the hardcoded variable form ratingmanager.inc.php

Usage: (at top of source code)

  1. <?php include('RatingManager.inc.php'); ?>

Usage: (in head)

  1. <script type="text/javascript" src="js.js"></script>
  2. <link rel="stylesheet" type="text/css" href="stars.css" />

Usage: (in body tags)

  1. <?php
  2. $ratingManager = RatingManager::getInstance();
  3. $ratingManager->drawStars(1); // where 1 would be a unique id for that stars rating
  4. ?>

Download:

Star Rating Class
ajax_star_rating-2009-07-11.zip
Version: 1.1

7.4 KiB
21 Downloads
Details…

GD Star Rating
loading...

Originally posted 2009-10-16 22:17:16.

Popularity: 15%

Posted by irbobo   @   29 July 2010

Related Posts

Like this post? Share it!

RSS Digg Twitter StumbleUpon Delicious Technorati Facebook

0 Comments

No comments yet. Be the first to leave a comment !
Leave a Comment

You must be logged in to post a comment.

Previous Post
« Simple PHP Caching Snippet
Next Post
Easily Zip Your Files Using PHP »
Powered by Wordpress   |   Lunated designed by ZenVerse