gRating example page
This page shows how to implement and use the gRating jQuery plugin for good ratings
Each example below shows a different feature or ability of the plugin
This page uses the following APIs that arent requirements of the gRating plugin for layout, display and enhancement purposes, you can safely ignore them when replicating the rating settings
Note: All ratings are embeded in Bootstrap "well well-sm" and text-center"s to better show the detail but this is omitted from the code displayed since it isn't related or neccasary for the plugin
Releases: The latest releases are available from the projects Github page https://github.com/duindain/gRating/releases
Issues: If you encounter an issue please submit it on GitHub https://github.com/duindain/gRating/issues
Help: To discuss or get help please visit the blog post about gRating http://lazinator.com/Articles/Duindain-gRating.php
<div class="rateThisPage" data-character="fa-diamond" data-max="10"></div> <script> $(".rateThisPage").grating({ callback: function(owner, value) { $.getJSON("index.php", {pageRating: value}, function(data) { $(".ratingAlertResult").html(''+ '<div class="alert alert-success alert-dismissible" role="alert">'+ ' <button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">×</span></button>'+ ' <strong>Success</strong> Thanks for submitting your rating!'+ '</div>').fadeTo(2000, 500).slideUp(500, function() { $('.ratingAlertResult').slideUp(500); });; }); }, ratingCss: {color: "#48C14A"}, ratingHoverCss: {color: "#7187DA"} }); </script>