MyBB Community Forums

Full Version: Rating Image Replacement...
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Long story short, I had MyBB 1.2, one of my admin's Steam account got hacked, they got our FTP password, they decided to delete our entire site. What motivates these people?

Anyway, we decided to upgrade to 1.4, so now I'm rebuilding the theme and I can't find where the thread rating image is referenced. I don't like gif images, and I have my own png images of the same name as the gif images (i.e. 0stars.gif = 0stars.png, etc...). I have looked through all of the php files (I think) to find out where it builds the image array and I'm having no luck. Is there anyone here that knows where I can change the .gif extension to a .png extension in the the system? I know I've done it before on the older version, but I forgot where, or it is different on this version.

Thanks in advance!
I believe it's in star_ratings.css in the theme settings.
The star ratings are CSS based, so they're in a stylesheet called "star_ratings.css".

You can get to it by editing your theme's options.

Damn, Matt beat me to it! Toungue
(2009-03-26, 08:40 AM)MattRogowski Wrote: [ -> ]I believe it's in star_ratings.css in the theme settings.

omg i'm really really dumb

i'd done this before but couldn't remember how and i looked through all the global.css and templates thinking "WHERE IS IT"

oh it's star_ratings.css on the main page of the theme welp
(2009-03-26, 08:40 AM)MattRogowski Wrote: [ -> ]I believe it's in star_ratings.css in the theme settings.
I looked there, that seems to be for some other rating thing, not the thread rating. Here is the data from the "forumdisplay_threadlist_rating" template...

 <td class="tcat" align="center" width="60"><span class="smalltext"><strong><a href="{$sorturl}&amp;sortby=rating&amp;order=desc">{$lang->rating}</a> {$orderarrow['rating']}</strong></span></td> 

I need to know where the "rating" variable is controlled, and where it builds the image array for the 0stars.gif, 1stars.gif, etc.. I searched for all terms I could think of in all of the files from the forums, with no luck. Sad I am quite a n00b at php, so I'm sorry if I may have over looked something. And if this is changable in the theme templates, please show me where. (side note, search option for the templates section might be handy Wink )[/align]

Is it possible that since I've designed the theme for 1.2 and ported it to 1.4 that the rating system doesn't work and I should just remove the column?
... no, it's that one Smile If you actually look at the image it mentions, you'll see there's sort of 3 stars in 1 image. Ages ago there was an issue where that stylesheet didn't exist for some people and all the ratings were broken, both in threads and on the forum display. There are no other star ratings... and there is a search feature for the templates.... Huh
Hmmm... Ok, so I'm confused then. I haven't changed the paths in the css file so it still points to "images/star_rating.gif" and that file exists, however the theme is looking in the root image folder for the theme (i.e. images/ThemeName/), how do I point the theme to a different folder? If this css file now controls the rating portion, why doesn't the theme pick up on this? It gets all of the rating info on the hover/image title thing, just not the image. I remember in the old one, there was a php file that set the variable something like, a number thing, 1 ~ 5 then appended the stars.gif on the end, is this still something that I can find and change? I would much rather not use a GIF file, since I use the alpha channels in the png format. Confused