nashio / star-rating-svg

A star rating jQuery plugin that uses SVG for easier customization
http://nashio.github.io/star-rating-svg/demo
MIT License
355 stars 156 forks source link

Bug in Firefox when stars were not filled if baseUrl contains local anchor on page #19

Closed serhiyzablotskiy closed 7 years ago

serhiyzablotskiy commented 7 years ago

Hi. I has detected a bug in firefox when stars were not filled if baseUrl contains local anchor on page.

I had resolved this issue by removing #local_anchor in my baseUrl before it will display.

var baseUrl = s.baseUrl ? location.href : '';

baseUrl = baseUrl.indexOf('#') != -1? baseUrl.replace(baseUrl.substring(baseUrl.indexOf('#'), baseUrl.length), ""): baseUrl;

...

nashio commented 7 years ago

Hello @serhiyzablotskiy , have you tried the option mentioned here? ---> https://github.com/nashio/star-rating-svg/issues/16

{  
   baseUrl: true  
}
serhiyzablotskiy commented 7 years ago

Hello. Yes I had try. But it didn't work.

2017-01-04 7:00 GMT+02:00 Ignacio Chavez notifications@github.com:

Hey @serhiyzablotskiy https://github.com/serhiyzablotskiy , have you tried the option mentioned here?

16 https://github.com/nashio/star-rating-svg/issues/16

{ baseUrl: true }

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/nashio/star-rating-svg/issues/19#issuecomment-270295162, or mute the thread https://github.com/notifications/unsubscribe-auth/AG1OJmIUyjF-KLTXxZ8n05Rs7_tbCmq7ks5rOydhgaJpZM4LWTZM .

nashio commented 7 years ago

Ah, I see what you mean, apologize, I misunderstood your comment. I added a fix, please re-download and let me know if that fixes it I basically only grab the part before the "#" from the url, similar to what you did.

@serhiyzablotskiy