GithubHelp home page GithubHelp logo

getgrav / grav-plugin-star-ratings Goto Github PK

View Code? Open in Web Editor NEW
5.0 6.0 3.0 86 KB

Grav Star Ratings Plugin

Home Page: https://getgrav.org

License: MIT License

PHP 75.58% CSS 13.02% JavaScript 11.40%
grav grav-plugin star-rating

grav-plugin-star-ratings's People

Contributors

flaviocopes avatar mahagr avatar rhukster avatar utagawal avatar w00fz avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

grav-plugin-star-ratings's Issues

Unable to submit data with ajax

When plugin makes an attempt to submit the data - fails. From the dev console I can see that it tries to open the following link:

POST http://localhost/blog/star-ratings.json/nonce:6061864bbd08e22dea2371636413e5c4

It comes back with a

500 error:

{"error":{"type":"RuntimeException","message":"Page Not Found","file":"/var/www/html/blog/system/src/Grav/Common/Grav.php","line":177}}

screenshot-3

weird text unterneath rating

Hey guys, I updated your plugin recently and since then I see a weird text underneath the rating stars: PLUGIN_STAR_RATINGS.SCORE_TEXT

How can I remove that? Thank you very much

bildschirmfoto 2017-12-31 um 14 00 58

Show Aggregate Rating Number

Hi,

I just tested this plugin. It is nice and I like how easy you can customize it. But right now I am missing a feature. There is no option to show the aggregating rating count, like 4,87 or so. The option to show the number of rating is there, so would it not make sense to show the average rating too?

Display on blog (article list) page ?

I have not test it for that (front actually in dev') so : is the plugin can display on the blog page (article list) for each article the rating ?
If yes, is ti possible to say to the plugin "Show only rating number (ex : 5/10) and no star at all" ?

Thanks in advance !

Twig_Error_Runtime

I've a problem with the plugin. On all sub-pages it's working correctly, but on the homepage I get an error:

41
Twig_Error_Runtime
โ€ฆ/user/themes/striped/templates/partials/blog_item.html.twig 112

It's the theme Striped and this block:
{% if page.header.continue_link is sameas(false) %}

{{ page.content }}


{% if not truncate %}
{% set show_prev_next = true %}
{% endif %}
{% elseif truncate and page.summary != page.content %}

Twig_Error_Runtime
An exception has been thrown during the rendering of a template ("array_merge(): Argument #1 is not an array").

I didn't make changes to the settings in the star-ratings.yaml. Any idea?

Activating show count hover bug

I just installed the star ratings plug-in and noticed that it works fine unless I activate the option show count. When I do, the hover doesn't work correctly. You have to be one 1.5 stars to the left with your mouse, meaning that you can't give a rating lower than 1.5.

I made a screen recording to show what I mean.

https://vid.me/8LGZ

How to set rating?

Hi,
I am new to grav and I want to add a review option to my site. I found this plugin, but I am wondering, where to set the actual star rating? I guess the twig template with the id is used to display it, but where to I set or store the ratings?

Option to "Enable/Disable jQuery" and option to load 2 required scripts at bottom

Hi,

thank you very much for this plugin, works great.
i had to remove manually scripts from star-ratings.php , because I didn't wanted to load jQuery v2 (i use v3), and also wanted to load jquery.star-rating-svg.min.js and star-ratings.js at bottom of site, so now i load them via my grav theme.

Is it possible to add 2 options? :

  • First one to "Enable/Disable jQuery" in plugin options,
  • and second one to load those 2 scripts at bottom.

First one i managed, but second one didn't understand how to do add scripts at bottom via PHP (i have checked this doc - https://learn.getgrav.org/cookbook/general-recipes#add-javascript-to-the-footer - but it do not work)

Best Regards,
Maksim

TODOs

Here's a list of things I want to add:

  • Admin UI to view/edit the data
  • Option to restrict voting for non-guests (only logged in users)
  • Summary information

Stars in Google

Hello,

has anyone managed to bring the stars to google. It seems as google does not see the stars on my side. Only the amount of ratings can be added.

Thanks
Susanne

array_key_exists() expects parameter 2 to be array, null given

I am trying to use the plugin, but I am getting this error:
Twig_Error_Runtime
COPY
An exception has been thrown during the rendering of a template ("array_key_exists() expects parameter 2 to be array, null given") in "default.html.twig" at line 9.

please see the attachment.

error

Rich Snippet AggregateRating Question

The star rating is working well thanks, when I add the rich snippets to my site there are two separately generated snippets, is there a way to pull AggregateRating from star rating (which generated by star rating php) over into a twig file?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.