gosukiwi supports this item


16 comments found.

Congrats ! nice work :)

Thanks! Glad you like it ~

Where and how do you record the ratings and their average? Would i need to hook it to a DB with my own php code i guess?

When you add it to your HTML it’s just another form field, you can then get the value using $_POST.

So i need to store $_post into a custom db for retrieving all the votes and showing the average back on the page to following visitors? I mean, the votes are not stored in this script, there is no db feature, correct?

Yeah, it’s just a frontend script, as well as a jQuery UI’s datepicker for example, it just displays a nice interface so users can select a value, how the value is handled is up to the backend (server code), as usual.

please create that php jack for using in database

Using in database? Could you provide me with an example so I can understand? I’m always open to ideas :)

How you set a default value? Perhaps this is what the others are looking for?

After retrieving an average rating value from the database, it would be great to present that to the user to show them the average rating. Then after you click a star, it would change to your rating.

If you set a value to the input, the plugin will load it as default, for example:

<input type=”number” value=”3”>


Excellent, thank you!

Hello, i have a gellery image adroid app, can i use this for rating all single image?


This is a Javascript plugin, if your app is made using HTML + CSS + JS and compiled to Android with PhoneGap it’ll work, but I don’t know the details about your app.


Looks like the demo is broken, I don’t see any stars but text inputs instead.

Thanks for reporting! Already submitted changes, waiting for approval.

Hi, how can i reset the rating? $(’#input1’).val(‘0’) doesn’t work…

Hi! I updated the plugin to add some convenience to this, there are two ways to do it, the first is using jQuery and manually calling a ‘change’ event as ‘val’ doesn’t actually do that


The latter is using the built-in method

$(’#input’).rating(‘val’, 1);

Please note I just uploaded the changes, it might take a while for CodeCanyon to approve :)


hi, how can I change the number of stars from 5 to 10?

nevermind, got it by changing the 1-5 loops in the .js. thanks!

hi, one more question, how can i make it that once a user votes (i.e. clicks on a star), the POST triggers? i.e. i don’t want a submit button to update the votes, but rather add the vote once the user clicks on a star.


Yeah on the same element you use the rating method

$(’#el’).rating().on(‘change’, function () { /* ... */ });

When an user changes the rating it trigger the ‘change’ event for the associated input :) You can even validate the rating before submitting the form, just in case.


i’m kinda new on JS so forgive me.

i’m doing this: $(’#myElement’).rating({ /* code to create your rating plugin */ }); which works fine

...and then this: $(’#myElement’).rating().on(‘change’, function () { alert(“Test”); }); ...which doesn’t work

but when i go to the code of your js: $el.on(‘change’, function () { alert(“Test”); }); ...it works! is that the place where I should place my code?

oops, just realised it should be: $(’#myElement’).on(‘change’, function () { /* */ })

..which works fine! sorry about that :)

how can i send the rating value to an email?

Hi, usually when you incorporate your rating element in a form, if you set a validationMessage and try to submit the form without rating, your .tipi will pop up indicating that the user needs to rate which is awesome. If however, I use it alongside jQuery validation plugin to validate other elements of the form, your validation does not occur anymore. Can you please let me know how to fix this, or perhaps push a fix to the plugin? I’ve also sent you an email with some bits of the actual code.

I’m using jQuery v2.1.1 and jQuery Validation Plugin v1.13.0


no problem! needless to say that other than this minor issue the plugin is <beep word here> awesome :)

hey gosukiwi, any update with this?

Sorry still didn’t have time to look at it, I’ll try to do it this weekend!

Hello, great work. Is any way to put “disable” or “readonly”? It’s only for show report but no for assign the rate.

Thank you!

Hi… is it possible to store the result using localStorage storage? And, if so, what would be the best way to do that? Great looking work, by the way :)

Hi, great plugin! I added this code for set also the number of icons that you want see. The add is inside the “rating.jquery.js” file:

defaults = { // whether or not to display the label under the stars showLabel: true, // messages for the label under the stars messages: [ ‘What did you think?’, ‘It was awful’, ‘It leaves something to be desired’, ‘Didn\’t surprise me’, ‘I liked it’, ‘It\’s the best!’ ],........ //this line numberIcon: 4 };

and change all for with this: for(i = 1; i <= self.settings.numberIcon; i++).

Thank you however. 10+ for this plugin ;)


Hi, nice plugin… I have a form where they have multiple questions and different scales (different number of stars) I prefere customize outside of rating.jquery.min.js in the own page, number of stars, different value and comments by each value (stars).... what do you could recomment?... me thanks in advance…

The Plugin.prototype in rating.jquery.js are the main setting of rating, how can I send the value to “i” for change the number of stars that are showing?

Hi Mate, Need your suggestion, I am trying to use this script in a form where i need to accept more than one field for rating in the same form.

if i use this below code more then once the rating stops working i am not sure how to fix it.

<input name=”Feedback” type=”number” id=”rating-1” style=”display: none;”>