1. Francesco Banconi
  2. django-generic-ratings
Issue #22 new

Form submit error

Anonymous created an issue

When I click submit on a form without clicking a rating (submitting an empty form), it goes to /ratings/vote and prints out "Invalid data in vote form". How can I handle this error?

Comments (2)

  1. Unknown Name
    In order to use this form you must download the
    jQuery Star Rating Plugin available at
    http://www.fyneworks.com/jquery/star-rating/#tab-Download
    and then load the required javascripts and css, e.g.::
    
  2. Hannes Tismer

    This is a localization issue. The score gets sent with a comma instead of a dot.

    Add this to the ratings.js code: values[this.name] = $(this).val().replace(",", ".");

    instead of values[this.name] = $(this).val();

  3. Log in to comment