Rating stars script - ReferenceError: renot not defined
Place for comments, problems, questions, or any issue related to the JavaScript / PHP scripts from this site.
-
waleedbarakat
- Posts: 7
- Location: Cairo, Egypt
Rating stars script - ReferenceError: renot not defined
Hello, dear respective admin,
I am sorry for creating another thread about issues in the same script (
Ajax-PHP Rating Stars Script), but just to make it easier for people who face the same issue on their websites. The new issue is about:
Code: Select all
ReferenceError: renot is not definedratings.js:153:12
onreadystatechange girlsugames.com/strating/ratings.js:153
if(ratev !='' && (renot == undefined || renot == 2))
I don't wanna play around to avoid any other problems, so I preferred to ask you first how to resolve this issue? Here are some screenshots about the issue
(it only appears after I click the stars and vote)
i.ibb.co/7nLJ5mb/new-issue.png
i.ibb.co/KVgpWw3/new-issue-det.png
Note:
(it only appears after I click the stars and vote)
The website URL is:
https://girlsugames.com/
you can try any game you like, all games aren't rated yet, so, it'll be easy to detect the issue in the browser console.
Thank you.
Admin
Try make these changes in ratings.js file (in the area of code between the lines 134...153):
1. After this line of code:
Code: Select all
let jsonitems = JSON.parse(obajx.responseText);
Add the following line:
So, you must have:
Code: Select all
let jsonitems = JSON.parse(obajx.responseText);
let renot;
2. Delete the word "let" from this line of code:
Code: Select all
let renot = (data_rt && data_rt=='novote') ?1 :jsonitems[rtgitem][2];
So, it will be:
Code: Select all
renot = (data_rt && data_rt=='novote') ?1 :jsonitems[rtgitem][2];
- Or download again the script from this site (I made the changes).
waleedbarakat
Awesome! the issue resolved successfully, Thank you for skyrocket responses and help

Similar Topics
-
Rating Stars Script uses 4 stars only
Scripts from this website
First post
Hi,
Thanks for the good looking scripts.
I am using Ajax-PHP Rating Stars Script with SQLite (I am using MySQL) at urbanprime.in (Link: )...
Last post
Hi.. Thanks for quick reply. It is working now.
Thanks.
-
Using rating script with 7 stars
Scripts from this website
First post
I'm using the script in subject I wrote, from the page:
I'ts only possible to rate 4 stars? What I made wrong?...
Last post
Hello,
You use the version for 7 stars (it can be used with 5, 7 or 10 Stars).
I noticed in the page you posted that only the first 6 stars can be...
-
Stars Not showing on Rating Script
Scripts from this website
First post
Good Day,
I've been working on this for hours and I'm sure there is something simple I'm missing, regarded to this script:
I've downloaded...
Last post
Sorry,
I think that the problem is from php server.
I notied that your server emits warning error if the date_default_timezone_set isn't specified;...
-
Ajax-PHP Rating Stars Script with SQLite
Scripts from this website
First post
I use always the script: //coursesweb.net/php-mysql/rating-stars-script-ajax-php_s2 from this great site!
In the last week I migrated all my scripts...
Last post
Thanks for the short explanation. I now know the mechanism of sqlite query... and the Ajax call is already in asynchronous mode since the third...
-
Ajax-PHP Rating Stars-SyntaxError JSON.parse unexpected character
Scripts from this website
First post
The Ajax-PHP Rating Stars Script , I am trying to get it working but I keep getting this error:
SyntaxError: JSON.parse: unexpected character at...
Last post
Awesome, Finally I get it works, after adding this line alert(obajx.responseText); it guided me to what was missing, first of all, the files URL's...