Problem with Rating script

Place for comments, problems, questions, or any issue related to the JavaScript / PHP scripts from this site.
User avatar
JanMolendijk
Posts:282
Location:Holland Rotterdam

Problem with Rating script

Dear admin how are you doing ?
I`m back again with something...

I wanna use this script:
https://coursesweb.net/php-mysql/rating- ... jax-php_s2
i changed it to mysql but it is not working also if i do the text option.

145.53.93.209/Rating/2/test.html

Admin Posts:805
Hello,
You should add the script directly in the root folder of you website.
If you added it into a sub-folder, try edit the path to "ratings.php" in the "ratings.js" file (line 105).

- Delete the beginning "/":

Code: Select all

cerere_http.open("POST", 'ratingfiles/ratings.php', true);
- Or, use absolute path (with "http:", or "https:"):

Code: Select all

cerere_http.open("POST", 'http://domein/subfolder/ratingfiles/ratings.php', true);
- Or, add the sub-folder name, with '/' from root:

Code: Select all

cerere_http.open("POST", '/subfolder/ratingfiles/ratings.php', true);

JanMolendijk Posts:282
Thanks for the support Admin it is working 1000%