PDA

View Full Version : Show Thread Enhancements - [AJAX] Threads rating


mad@Max
07-11-2008, 10:00 PM
This mod merge of three old mods:
vB.org Rating System Replica (https://vborg.vbsupport.ru/showthread.php?t=155701)
[AJAX] Your One Click Thread Ratings (https://vborg.vbsupport.ru/showthread.php?t=136162)
Who Rated This Thread / Delete Who Rated (https://vborg.vbsupport.ru/showthread.php?t=133067)

Futures:
- Now it is not necessary to delete elements from a template
- You can choose id forums, where a rating threads to display it is necessary or not necessary
- On click rating icon in the threads you get info about voting
- You can delete vote from thread rating
- Realisation with AJAX

Install:

Extract all files from folder "Upload" in forum root directory

Find in file threadrate.php on youre server:

$xml->add_tag('voteavg', process_replacement_vars("$vbphrase[rating]: <img class=\"inlineimg\" src=\"$stylevar[imgdir_rating]/rating_$thread[rating].gif\" alt=\"" . construct_phrase($vbphrase['thread_rating_x_votes_y_average'], $thread['votenum'], $thread['voteavg']) . "\" border=\"0\" />"));Replace with:

$currate = ($thread['voteavg']*25 . px);
$xml->add_tag('voteavg', process_replacement_vars("<table cellpadding=\"$stylevar[cellpadding]\" cellspacing=\"0\" border=\"0\" width=\"100%\"><tr><td align=\"right\" width=\"45%\" nowrap=\"nowrap\"><div><strong>$vbphrase[trate_currate]</strong></div></td><td align=\"left\" width=\"55%\" nowrap=\"nowrap\"><ul class=\"star-rating\" title=\"" . construct_phrase($vbphrase['thread_rating_x_votes_y_average'], $thread['votenum'], $thread['voteavg']) . "\"><li class=\"current-rating\" style=\"width:$currate;\"></li></td></tr></table>"));Using the Product Manager, upload the Product that came with this modification.

Admincp > Plugins and Products > Manage Products > [Add/Import Product] >

product-trate.xml

Update:

Uninstall old mod and import product (v1.3)

Upload stars.png in folder your style, by default /images/rating/

Enjoy!

DEMO
www.mixplay.ru/forum.php (http://www.mixplay.ru/forum.php) // choose any thread
user: Test
pass: 123456

Thread Rating T?rk?e 1.4.1.zip (https://vborg.vbsupport.ru/attachment.php?attachmentid=86455&d=1220348854)

Click Install, if you like this mod:)

PoetJA-1975
07-12-2008, 07:21 PM
Nice!
Thanx for sharing.

Jacquii.

Internetcafe
07-12-2008, 09:31 PM
Great addition .. I changed the background colour to match my skin.

Clicked install

fukdawrld
07-12-2008, 10:03 PM
excellent post here

Mark.B
07-12-2008, 10:21 PM
Only thing I'm finding is that when you vote, if the thread has not been voted on already the data is missing from the box until you refresh the page.

It will say:
"Thread Rating: 0 votes, average."

When it should say something like:
Thread Rating: 1 votes, 5.00 average."

Hornstar
07-12-2008, 10:21 PM
Yeah I think my members will really love this. I can see a few people going around and abusing it tho, so it would be nice to know who is voting and to be able to ban people from voting any more if they are just going around and clicking on terrible on every thread.

Could you add this feature?

mad@Max
07-12-2008, 10:35 PM
hornstar1337
Yes, i'm integrate this mod (https://vborg.vbsupport.ru/showthread.php?t=165652) with my. Tomorrow i release him.

vietdjclub
07-13-2008, 04:18 AM
would be better if you could disable poster rate your own thread

luffy
07-13-2008, 05:44 AM
excellent Thank you

shadowevil
07-13-2008, 05:54 AM
no compatible with GARS, You can do with next version for well compatible with Gars ? thanks

TheProphet
07-13-2008, 08:46 AM
thx m8, will give this a try..

Q-v-n-s-Q
07-13-2008, 08:56 AM
nice mod, thanks

marc2005
07-13-2008, 02:33 PM
very useful, thanks!

mad@Max
07-13-2008, 07:46 PM
ADDED
Thread Rating + Rating Info Eng

Mark.B
07-13-2008, 10:43 PM
This seems to be giving me a Javascript error which is only fixed by removing the first instance of this line (and it's closing </if> tag):
<if condition="$vboptions['trateglobal']==0 OR (in_array($threadinfo['forumid'], array($vboptions['trateforum'])))">

But this then results in a security token error when trying to rate a thread.

The error is "object expected".

mad@Max
07-13-2008, 11:04 PM
I tested, all tags is fine, mb are you delete other part of code?

Mark.B
07-13-2008, 11:50 PM
I tested, all tags is fine, mb are you delete other part of code?
Well at first I didn't notice it, because I use Firefox which doesn't routinely point out JS errors in the way IE does.

Then I tried using the moderation tools, and when you click the check box in a post, nothing happens.

Suspecting a JS error, I tried it in IE, and sure enough, it's giving "object expected".

From my debugging attempts, it seems to be to do with the inline moderation form being surrounded by that conditional...presumably if the conditional returns false, the form doesn't execute which stops the inline moderation tools working.

You will only notice this issue if you're logged in as a moderator or admin with mod rights for the forum you are viewing.

Hope this is some use, as it's otherwise an excellent mod.

abrecher
07-14-2008, 04:54 AM
Used on GARS too and it does not work.

mad@Max
07-14-2008, 01:16 PM
I will try add: ajax, future delete given rating from anyone and compatible with GARS.
Mark.B
Replace "</if>" after
<if condition="$show['threadrating']">
<td class="vbmenu_control" id="threadrating" nowrap="nowrap">
<a href="$show[nojs_link]#goto_threadrating"><span id="threadrating_current"><if condition="$show['rating']">$vbphrase[rating]: <img class="inlineimg" src="$stylevar[imgdir_rating]/rating_$thread[rating].gif" alt="<phrase 1="$thread[votenum]" 2="$thread[voteavg]">$vbphrase[thread_rating_x_votes_y_average]</phrase>" border="0" /><else />$vbphrase[rate_thread]</if></span></a>
<if condition="$show['popups']"><script type="text/javascript"> vbmenu_register("threadrating"); </script></if>
</td>
</if>
Must be work.

mad@Max
07-14-2008, 05:41 PM
Mod is updated.

MissKalunji
07-16-2008, 06:00 PM
could you add WHICH thread to ENABLE it? i only want it one thread i have many subforums it would take me a while.

Thanks

snowlion
07-20-2008, 03:30 PM
when i add this line

<!-- thread rating info -->
<script type="text/javascript">
<!--
function openDreamTRI(threadid) {
dreamTRIWindow = window.open('threadratinginfo.php?threadid=' + threadid, 'dreamTRI', 'directories=no, height=150, width=300, location=no, menubar=no, resizable=yes, status=no, scrollbars=yes, toolbar=no');
}
//-->
</script>
<!-- / thread rating info -->

i can't find threadratinginfo.php. Sorry, did you miss this file?

Mark.B
07-25-2008, 03:58 PM
The new version till messes up the mod tools. it's fine as an ordinary user, but as an admin or mod the the tick boxes in posts no longer work, and for admins and mods in Firefox it won't submit the rating at all. I've had to uninstall for now until this can be fixed.

mad@Max
07-25-2008, 07:09 PM
MissKalunji, maybe.
snowlion, you are right, i have miss it, sorry:).
Mark.B, try now, i update mod.
In updated mod added forgotten file and fix one bug.

MissKalunji
07-25-2008, 08:25 PM
Thanks mad@max :)

MissKalunji
07-25-2008, 08:43 PM
uhm when i select a rating nothing happens?

mad@Max
07-25-2008, 09:48 PM
MissKalunji what do you mean?

MissKalunji
07-25-2008, 10:38 PM
when i click on example :excellent ajax should kick in and register the vote but it doesn't nothing happens it doesn't register the vote nothing.

mad@Max
07-25-2008, 11:56 PM
MissKalunji, after click on vote nothing happens? Hm, this mod work on many forums, and work fine. Check instructions to installation.

MissKalunji
07-26-2008, 12:03 AM
i did i double checked :-/ when i did the manual ones (from another author) worked fine but this one isn't

When i click in "excelent" and press on enter on my keyboard i get an error on wrong thread or something like that...

vietdjclub
07-26-2008, 12:43 AM
working fine on IE but not working in FF. how to fixed it please?????

MissKalunji
07-26-2008, 02:12 AM
oh that could be it...i was on FF let me check on IE

MissKalunji
07-26-2008, 02:22 AM
yeah i confirm it doesn't work IN firefox but does work in Internet explorer

ogameclub
07-26-2008, 10:28 AM
yeah i confirm it doesn't work IN firefox and uninstalled.

mad@Max
07-26-2008, 12:58 PM
MissKalunji, registering your vote happens by one step, just choose a rate. I dont understand for what you click "enter"?
I'm test this mod on FF, IE, Opera, Safari. On all browsers work very good!
PS you may test mod on our board, after register.

vietdjclub
07-26-2008, 01:31 PM
MissKalunji, registering your vote happens by one step, just choose a rate. I dont understand for what you click "enter"?
I'm test this mod on FF, IE, Opera, Safari. On all browsers work very good!
PS you may test mod on our board, after register.

i'm test with admin group and user group but ff doesnt work. i confirm it. you mayby check it via the account i sent. check your PM

EagleNick
07-26-2008, 02:33 PM
Nothing happens when a user clicks a rating... and there is no submit button.

So I don't know what to do. Please help ;)

EagleNick
07-26-2008, 02:36 PM
Nothing happens when a user clicks a rating... and there is no submit button.

So I don't know what to do. Please help ;)
Okay now that I've read other replies... I tested in IE and it works - not in Firefox.
Therefore, I am UNINSTALLING it.

If you fix it to support FF, I will be glad to use it ;)

mad@Max
07-26-2008, 05:46 PM
I found 1 bug with ajax and FF, after voting not showing alt text (phrase) statistic on image (stars). But mod work.
You may test on fresh forum:
www.mixplay.ru/forum.php // choose any thread
user: Test
pass: 123456

EagleNick
07-26-2008, 07:05 PM
I found 1 bug with ajax and FF, after voting not showing alt text (phrase) statistic on image (stars). But mod work.
You may test on fresh forum:
www.mixplay.ru/forum.php // choose any thread
user: Test
pass: 123456
I tried it out and it worked.

But It doesn't work on my site. How do I fix it?

mad@Max
07-26-2008, 08:30 PM
EagleNick
Send me link to your site in my PM, with login and pass. I will see.

MissKalunji
07-26-2008, 08:57 PM
ok here's what i do.

- I click in example : Excellent
- Nothing Happens
- Since there is no submit button (since it works with ajax) I try to press on enter on my keyboard
- and this is what it says : You did not select any posts to which the action you picked can be applied.

MissKalunji
07-26-2008, 09:13 PM
btw i get some javascripts error from Firefox 3

On your site and mine

Error: linkobj is null
Source File: http://www.mixplay.ru/clientscript/vbulletin_ajax_oneclick_threadrate.js?v=371
Line: 27

and mine

Error: formobj is null
Source File: http://www.dancehallareaz.com/forum/clientscript/vbulletin_ajax_oneclick_threadrate.js?v=372
Line: 33

and then when i try to vote here's the error i get

Error: Permission denied to call method Location.toString

and

Error: linkobj is null
Source File: http://www.mixplay.ru/clientscript/vbulletin_ajax_oneclick_threadrate.js?v=371
Line: 27

MissKalunji
07-26-2008, 09:17 PM
OK i found my problem i had to move this : $trate before the poll like he said in the previous thread : https://vborg.vbsupport.ru/showthread.php?t=136162

mad@Max
07-26-2008, 09:28 PM
It not essentially. Maybe you enable not all script in FF, like yahooapis. Because i too use FF3, and i happy :)

MissKalunji
07-26-2008, 09:36 PM
Well it's ok :) it was where it was placed now it's working fine:) Thanks!

How can i make it So WHen you're done voting it Removed the whole thing? I don't want it to show the average rating nothing.

BatMs.com
07-26-2008, 10:22 PM
Very Nice..

Thanks

MissKalunji
07-26-2008, 10:38 PM
Well it's ok :) it was where it was placed now it's working fine:) Thanks!

How can i make it So WHen you're done voting it Removed the whole thing? I don't want it to show the average rating nothing.

Never mind ;) got it Thanks

vietdjclub
07-27-2008, 03:18 AM
I found 1 bug with ajax and FF, after voting not showing alt text (phrase) statistic on image (stars). But mod work.
You may test on fresh forum:
www.mixplay.ru/forum.php // choose any thread
user: Test
pass: 123456

i tried it work but it doesn't work with my board. i use FF ver 3.0. any add on ???

MissKalunji
07-27-2008, 04:20 AM
The $strate move under $poll instead of the place he said and it will work. The script was conflicting with something else from vb.

vietdjclub
07-27-2008, 05:55 AM
The $strate move under $poll instead of the place he said and it will work. The script was conflicting with something else from vb.

yes i confirm that put $strate under $poll will work fine.
great information :D

MissKalunji
07-27-2008, 12:44 PM
great ;)

EagleNick
07-27-2008, 02:42 PM
yes i confirm that put $strate under $poll will work fine.
great information :D
Thanks, this works perfectly! :D

cSh
07-28-2008, 01:50 PM
The $strate move under $poll instead of the place he said and it will work. The script was conflicting with something else from vb.

$strate > $trate yes work but click rating thread not forwad wait wait waittt

MissKalunji
07-28-2008, 09:36 PM
click rating thread?

balance12
07-29-2008, 03:27 PM
I installed the once click raitng and now its workinf fine.. but ut shows me Two Options to vote.. the one of this mod, and the one from the other mod...

RvG2
07-29-2008, 04:17 PM
yes i confirm that put $strate under $poll will work fine.
great information :D

is this fixed in ver 1.1?

MissKalunji
07-29-2008, 04:22 PM
no he didn't do anything

Just do the fix yourself. It's just the Readme files that he would have to edit

mad@Max
07-29-2008, 05:58 PM
Ok, i'm update Readme file :) And first post.

GaiLoan
08-05-2008, 07:34 AM
everything just working fine

my opinion (if after you click but notin happen, i think you host is too slow or something)

mad@Max
08-06-2008, 04:34 PM
Mod is updated.
Added option: Enable on forums - Forums IDs in which you would wish to see a rating in threads.
And now you need just import product, without templates editions:)

MissKalunji
08-06-2008, 05:14 PM
:) thank you

FIM
08-06-2008, 09:51 PM
No Markup Validation Service

mad@Max
08-07-2008, 09:36 AM
FIM
What do you mean?

virus9112002
08-08-2008, 05:10 PM
everything just working fine
But when you click on Thread Tool ther is some Problem
Look at the Attach

MobileBros
08-08-2008, 05:58 PM
everything just working fine
But when you click on Thread Tool ther is some Problem
Look at the Attach

i get the same thing

MissKalunji
08-08-2008, 06:15 PM
which version does you guys have?

twister17e
08-08-2008, 09:23 PM
i get the same thing

I have the same error. The showthread layout becomes messed up. There is text that says, "id" method="post" name="threadadminform">" and id /> just like in the screen shot. I am using version #1.2 and the layout becomes completely normal if I disable this mod.

MissKalunji
08-08-2008, 09:52 PM
which version does you guys have?

virus9112002
08-09-2008, 01:46 AM
which version does you guys have?

Thread Rating Version: 1.2
Last Update: 06 Aug 2008

My vBulletin 3.7.2

MissKalunji
08-09-2008, 03:17 AM
ok i didn't install the update yet...i'de have to check see the difference between both..

Did it do that before you upgraded to 1.2?

virus9112002
08-09-2008, 11:01 AM
In fact I did not Start the installation of the previous version

eXoOutsider
08-09-2008, 03:47 PM
How would someone go about changing the background color?

mad@Max
08-09-2008, 10:07 PM
Yes, in version 1.2 there was an error - fixed:)
So now I wish to present you a result of my long and hard works:)
Now the voting look a like on youtube and other, i.e. on hover mouse and click on star.
You may test:
www.mixplay.ru/forum.php // choose any thread
user: Test
pass: 123456

eXoOutsider, in template "trate" find:
.quickajaxrating{
padding: 5px;
background: #DFE6EF;
border: 1px dashed #B53A25;
color: #000000;
}
And change background color.

eXoOutsider
08-09-2008, 10:35 PM
Yes, in version 1.2 there was an error - fixed:)
So now I wish to present you a result of my long and hard works:)
Now the voting look a like on youtube and other, i.e. on hover mouse and click on star.
You may test:
www.mixplay.ru/forum.php // choose any thread
user: Test
pass: 123456

eXoOutsider, in template "trate" find:
.quickajaxrating{
padding: 5px;
background: #DFE6EF;
border: 1px dashed #B53A25;
color: #000000;
}
And change background color.
Thank you very much :)

Forum Lover
08-09-2008, 10:42 PM
Max, things are showing up like din. How can I fix thiks?

mad@Max
08-09-2008, 10:50 PM
Upload stars.png in folder your style, by default /images/rating/

virus9112002
08-09-2008, 11:19 PM
Work 100%

Best Y Man

glorify
08-10-2008, 01:15 AM
Looks great but those stars don't fit into my board. Have some similar to default?

Forum Lover
08-10-2008, 05:00 AM
Wow, thanks chief.

mad@Max
08-10-2008, 10:18 PM
I'm update hack and add gif animation of work product:)

MissKalunji
08-11-2008, 02:28 AM
THANK YOU!!!!!!!! that's what i've been wanting forever!

MissKalunji
08-11-2008, 02:35 AM
You Forgot to translate this : ??????? ??????? to Rate Thread

in

<table cellpadding="$stylevar[cellpadding]" cellspacing="0" border="0" width="100%"><tr><td align="right" width="45%" nowrap="nowrap"><div><strong><a href="javascript:openDreamTRI($thread[threadid])">??????? ???????</a>:</strong></div></td><td align="left" width="55%" nowrap="nowrap"><ul class="star-rating" title="<phrase 1="$thread[votenum]" 2="$thread[voteavg]">$vbphrase[thread_rating_x_votes_y_average]</phrase>"><li class="current-rating" style="width:$current_rating;"></li></td></tr></table>


and i get an error when viewing who rated

Warning: Division by zero in [path]/threadratinginfo.php on line 75

Warning: Division by zero in [path]/threadratinginfo.php on line 78

Warning: Division by zero in [path]/threadratinginfo.php on line 78

Warning: Division by zero in [path]/threadratinginfo.php on line 78

Warning: Division by zero in [path]/threadratinginfo.php on line 78

Warning: Division by zero in [path]/threadratinginfo.php on line 78

mad@Max
08-11-2008, 07:00 AM
Thanks - reload product.
How you got this error?

MissKalunji
08-11-2008, 05:56 PM
Thanks - reload product.
How you got this error?

I took a screenshot

mystic10
08-11-2008, 07:13 PM
instead of rate this thread i see this i am confused why Îöåíèòå ýòó òåìó: i dont know what language is it but kindly help on how to fix my issue

MissKalunji
08-11-2008, 10:33 PM
in template : THREADRATINGINFO_WHOVOTED_ENTRY

search for : Îöåíèòå ýòó òåìó

and change it for : Rate This Thread

I'de attached the fix product but don't know if im allowed

mad@Max
08-12-2008, 10:05 AM
MissKalunji you get this error when number of votes > 0?
mystic10 reinstall product or do what say MissKalunji.

mad@Max
08-12-2008, 01:32 PM
Yes, error happens when number of votes = 0. Wait new version with fix.

MissKalunji
08-12-2008, 02:37 PM
:) thanks it was fine with the previous one only happened after the upgrade

BANDiT600
08-12-2008, 07:52 PM
How to insert space "&nbsp;".

mad@Max
08-12-2008, 10:19 PM
Hack is updated.
In new version fixed all bugs and for fulled deep changed image after click on star, like on attached image from previous post. Added manual how did this.
BANDiT600 i think i was answer on your question:)

MissKalunji
08-12-2008, 10:32 PM
Thanks ;)

Forum Lover
08-13-2008, 06:19 AM
Is it only me, or anyone get this same problem?:confused:

mad@Max
08-13-2008, 07:57 AM
Forum Lover only you:)

BANDiT600
08-13-2008, 11:42 AM
Is it only me, or anyone get this same problem?:confused:

Same for me...

mad@Max
08-13-2008, 06:39 PM
Hm, on same forum this bug exist. Soon i rebuild hack...

mad@Max
08-13-2008, 09:37 PM
Hack is updated. Hope all bug in past:)
I'm tested on 3 board and 4 style - work fine:)

yingzhou
08-19-2008, 11:05 AM
thank, the updated work perfect!

Cobro
08-21-2008, 08:15 PM
WOW thank you very much like it alllot

mad@Max
08-21-2008, 11:52 PM
I am glad:)

Mongez
08-22-2008, 03:37 AM
Many thanks, this is very useful mod

but i have small problem

when i click in Edit/View Rating option i get nothing ,so what can i do to fix it ?

mad@Max
08-22-2008, 08:03 AM
In the top of template navbar add this:
<!-- thread rating info -->
<script type="text/javascript">
<!--
function openDreamTRI(threadid) {
dreamTRIWindow = window.open('threadratinginfo.php?threadid=' + threadid, 'dreamTRI', 'directories=no, height=150, width=300, location=no, menubar=no, resizable=yes, status=no, scrollbars=yes, toolbar=no/\');
}
//-->
</script>
<!-- / thread rating info -->

Mongez
08-22-2008, 11:25 AM
In the top of template navbar add this:
<!-- thread rating info -->
<script type="text/javascript">
<!--
function openDreamTRI(threadid) {
dreamTRIWindow = window.open('threadratinginfo.php?threadid=' + threadid, 'dreamTRI', 'directories=no, height=150, width=300, location=no, menubar=no, resizable=yes, status=no, scrollbars=yes, toolbar=no/\');
}
//-->
</script>
<!-- / thread rating info -->

Sorry still have same problem

* I test this mod on my localhost, so this is have relation in my problem ?

many thanks agin

mad@Max
08-22-2008, 04:33 PM
You are use default style?

Mongez
08-22-2008, 09:58 PM
You are use default style?

This is strange ,it is working great with some styles i have, and some styles not working only Edit/View Rating option, so when i test now i get the problem in Navbar template, i have edit this template before, so what can i do ?

Thank you for your help.

mad@Max
08-22-2008, 10:09 PM
For some styles need special editing. If you have online example, i can look on it.

Mongez
08-22-2008, 10:12 PM
For some styles need special editing. If you have online example, i can look on it.

yes this is my forum http://www.klamaraby.com/vb/index.php

sorry it is Arabic forum :)

and i have Attach my navbar template if you want take a look

many thanks.

mad@Max
08-22-2008, 10:46 PM
You are sure what add correctly code in "navbar" template, at the top?

<!-- thread rating info -->
<script type="text/javascript">
<!--
function openDreamTRI(threadid) {
dreamTRIWindow = window.open('threadratinginfo.php?threadid=' + threadid, 'dreamTRI', 'directories=no, height=150, width=300, location=no, menubar=no, resizable=yes, status=no, scrollbars=yes, toolbar=no');
}
//-->
</script>
<!-- / thread rating info -->
Because with this, it is must work.

Mongez
08-22-2008, 10:50 PM
Strange working now !, i can not talk something for your help :up:

thanks again for your time and have a nice day :)

mad@Max
08-22-2008, 11:22 PM
Welcome;)

PaylaX
08-23-2008, 09:20 AM
a great job!

nominated & installed

Mongez
08-23-2008, 11:41 PM
Hi mad

sorry one bug i found

the visitor can see who vote Tab (not really can see who vote but he can see the tab)

look in my print screen to understand me

many thanks

mad@Max
08-23-2008, 11:46 PM
Thanks, soon i fix it.

Peterpan002
08-25-2008, 04:15 PM
I have changed the attached png but it is smaller how do I change the image size so it correctly displays I looked in threadrate.php but cannot see.

edit: trate

ok but for 15px image could you tell me what to change.

mad@Max
08-25-2008, 04:27 PM
Peterpan002, for this need a many changes.

Peterpan002
08-25-2008, 04:38 PM
ok I got most anything outside of trate template need changing works ok except number of icons on vote too long - SORTED Thank you :)

PHILLYFAN
08-27-2008, 10:56 PM
ok i done everything by the book and it has it up on my forum however it doesnt show the stars to click whitch one u wanna vote on. but if i hoover over where the stars are its tehre just not showing any reason why?

mad@Max
08-27-2008, 11:48 PM
Hm... Say your forum.

PHILLYFAN
08-28-2008, 05:31 AM
<a href="http://www.nationalsocomleague.com/forum" target="_blank">www.nationalsocomleague.com/forum</a>

PHILLYFAN
08-28-2008, 05:32 AM
here is a perfect example. if you click the link you can i voted on a thread cause u see the percentage of the vote

http://www.nationalsocomleague.com/forum/showthread.php?p=195#post195

PHILLYFAN
08-30-2008, 12:27 AM
anyone?

ParaWa
08-30-2008, 01:02 AM
Really appreciate this mod! Thanks

yingzhou
08-30-2008, 01:53 PM
My forum have this conflict, viewed by IE.

https://vborg.vbsupport.ru/external/2008/08/5.jpg

It conflict with my forum keyboard, based on javascript.

mad@Max
08-30-2008, 02:11 PM
PHILLYFAN
This is easy:) Upload stars.png in folder "/forum/fusion/rating/", because i dont find it in path http://www.nationalsocomleague.com/forum/fusion/rating/stars.png. Then in template trate find "fusion/rating/stars.png" and replace with "forum/fusion/rating/stars.png"

PHILLYFAN
08-30-2008, 04:36 PM
what does this last part do
Then in template trate find "fusion/rating/stars.png" and replace with "forum/fusion/rating/stars.png"


the reason im asking when i added the stars.png it works now so do i need to do the trate step also if so where that be located can seem to find it..

thank you for your help so far

again nice mod

mad@Max
08-30-2008, 06:45 PM
I tested on your board - all works:)

PHILLYFAN
08-30-2008, 06:49 PM
thanks for your help... great mod!

NAZIA
08-30-2008, 09:03 PM
Thanks Buddy..
It is very Nice..Now users easily can rate the thread.. Thanks Max

NAZIA
08-30-2008, 11:18 PM
http://wumuw.com/i/20080830081747PMhlp.JPG

mad@Max
08-31-2008, 12:04 AM
Add this anywhere:
Rating: <img class="inlineimg" src="$stylevar[imgdir_rating]/rating_$thread[rating].gif" border="0" alt="" /> ($thread[votenum] votes - $thread[voteavg] average)
Must be work.

Mongez
08-31-2008, 11:30 AM
mad you fix my problem yet ?

thanks

NAZIA
08-31-2008, 01:28 PM
Add this anywhere:
Rating: <img class="inlineimg" src="$stylevar[imgdir_rating]/rating_$thread[rating].gif" border="0" alt="" /> ($thread[votenum] votes - $thread[voteavg] average)Must be work.




http://wumuw.com/i/20080831102649AMhelp2.JPG


As on my Board this Column is Visible but its Rating is not appearing there, Even User Rated the same thread

http://wumuw.com/i/20080831103322AMuntitled.JPG

PaylaX
09-02-2008, 08:45 AM
Perfect job!

Turkish language pack(Please update first post):

rskg4
09-05-2008, 09:27 PM
is it possible to allow a user to change their rating? All i get is a message that they are not allowed..perhaps it is a setting in the vb options?

Edit-

I'm blind, i found it.

Thanks for this mod.

mad@Max
09-05-2008, 11:55 PM
PaylaX
Thanks, in first post.

Dennis Kaczor
09-06-2008, 01:43 AM
Yes, in version 1.2 there was an error - fixed:)
So now I wish to present you a result of my long and hard works:)
Now the voting look a like on youtube and other, i.e. on hover mouse and click on star.
You may test:
www.mixplay.ru/forum.php // choose any thread
user: Test
pass: 123456

eXoOutsider, in template "trate" find:
.quickajaxrating{
padding: 5px;
background: #DFE6EF;
border: 1px dashed #B53A25;
color: #000000;
}
And change background color.

First of all great mod and one that I have installed and makes it easier for the users.

I too wanted to change the background colour from that white to the colour of my template.

I got the values for it, but it does not seem to change the colour for me it's still white. The background colour is what I wanted to have and the other is white, but I can change that later, but some how this is not working out? See below.

.quickajaxrating2{
padding: 5px;
background: #3B4E5B;
color: #FFFFFF;

Dennis Kaczor
09-06-2008, 03:54 PM
PaylaX
Thanks, in first post.

Max,

I found why I could not change the background, only if I had payed more attention to the message thread, I now have it working fine now. Again great mod.

Sharp Intellect
09-20-2008, 10:03 PM
does this hack work for vB 3.6?

mad@Max
09-20-2008, 10:57 PM
Sharp Intellect, yes.

Dennis Kaczor
09-28-2008, 10:41 PM
OK here is a problem and I don't have any ideas to why my ratings with the stars and statistics don't show up on a message thread. This was working fine the other day and now it went south some how.

If there is a new message, than I can see the stars for rating the image, and once you rate that thread the stars and statistics does not show up to show who voted on the thread.

If you are in the forums and pick one and go to the star ratings on the right side and click on the rating it shows who has rated the thread.

In all, any messages that have been rated there is no display of the stars and statistics that show up. Any ideas what I could look for?

I removed the plug-in and then installed it again, but still the same thing where it is not displaying

mad@Max
09-28-2008, 11:08 PM
Hm, very strange. Write your site, i'll look up.

Dennis Kaczor
09-28-2008, 11:52 PM
Hm, very strange. Write your site, i'll look up.

http://www.icurdigital.com

Name: Guest
P/W : 1234

mad@Max
09-29-2008, 12:20 AM
I encountered this problem. I would find a solution.

mad@Max
09-29-2008, 12:57 AM
Dennis Kaczor, Which version work for you?

crazy-girl
09-29-2008, 02:01 AM
Thank you very much for this nice Addon :)

dtv100
10-06-2008, 09:48 PM
any way to use dark colors on stars? my forum backgroung is white and you cant see the start almost.

acast
10-15-2008, 06:14 PM
Is any way to have different ratings in the different subforums? For example in one subforum you rate with some images, and in other with other images and a different message? Perhaps with an if?

mad@Max
10-15-2008, 07:38 PM
dtv100, Need repaint a picture:)
acast, need write another css class.

acast
10-15-2008, 09:18 PM
dtv100, Need repaint a picture:)
acast, need write another css class.How friend? Can you explain me?

mad@Max
10-15-2008, 11:00 PM
Hm, no, go in the trate template, find all $stylevar[imgdir_rating]/stars.png, and then replace founded items on <if condition="in_array($thread[forumid], array(1,2,3,4,...,N)">$stylevar[imgdir_rating]/black_stars.png<else />$stylevar[imgdir_rating]/stars.png</if>Where 1,2,3,4,...,N forums with different stars. But resolution of different image must be like stars.png.
Must be work:)

mad@Max
10-16-2008, 01:49 AM
Mod is updated.
Fixed problem when rating not displaying after voting (on some forums).
Quick fix for those who have this problem. In template trate find <if condition="$show['ratethread'] && $threadinfo['vote']==NULL"> replace with <if condition="$show['ratethread']">
Added hand setting, info in first post.

acast
10-16-2008, 11:50 AM
Hm, no, go in the trate template, find all $stylevar[imgdir_rating]/stars.png, and then replace founded items on <if condition="in_array($thread[forumid], array(1,2,3,4,...,N)">$stylevar[imgdir_rating]/black_stars.png<else />$stylevar[imgdir_rating]/stars.png</if>Where 1,2,3,4,...,N forums with different stars. But resolution of different image must be like stars.png.
Must be work:)Hi friend, thank you for helping me. I have this code in showthread:

<if condition="$rated">
<span id="threadrating_current"><if condition="$show['rating']">$vbphrase[rating]: <img class="inlineimg" src="$stylevar[imgdir_rating]/rating_$thread[rating].gif" alt="<phrase 1="$thread[votenum]" 2="$thread[voteavg]">$vbphrase[thread_rating_x_votes_y_average]</phrase>" border="0" /></if></span>
<else />
<div align="left"><span class="ratetext">$vbphrase[rate_this_thread] - <em>$thread[title]</em>.</span></div>
<a name="goto_threadrating"></a>

And this one in threadbit:

<if condition="$show['threadratings'] AND $show['threadrating']"><span style="float:$stylevar[right]"><img class="inlineimg" src="$stylevar[imgdir_rating]/rating_$thread[rating].gif" border="0" alt="<phrase 1="$thread[votenum]" 2="$thread[voteavg]">$vbphrase[thread_rating_x_votes_y_average]</phrase>" /></span></if>

My images for ratings are called:

http://www.XXX/enlighten/rating/rating_1.gif
http://www.XXX.com/enlighten/rating/rating_2.gif


... Up to five rating_5.gif


How can i change it so in the template?

mad@Max
10-16-2008, 12:28 PM
Use the last version of mod.

acast
10-16-2008, 12:40 PM
Use the last version of mod.Sure friend, but you make it the stars with the same PNG image. Could be with different images? I explain you, i have a cinema subforum where i want to have different images for the different ratings instead the film is great, average, poor... and when the post have a rating appears a different image. The change you did makes that use only one image: Stars.png. Isnt it?

Thanks for your answer, i really apreciate your work.

Charles_1
10-29-2008, 12:49 AM
Hi mad@max,

your mod is working perfectly (vB 3.6.7), thanks for sharing. But I have one request.

I am also using mod vBi-Gallery for vB 3.6.X (https://vborg.vbsupport.ru/showthread.php?t=128598), which can transform specific sections of forum to simple galleries using own versions of some templates with modifications of layout (for this mod are relevant own versions of templates showthread and threadbit, there are also own verions of postbit and forumdisplay, others are only for gallery purposes like to show newest threads/pictures in forumhome etc.) - in the way of functionality of sections, threads and posts is everything standard, image for gallery is based on ordinary vB attachment in first post - modifications are only in the way of presentation of threads in forumhome and first post in threads). From this reason of own templates your mod "[AJAX] Threads rating" doesn't work or to be more specific the box of rating system doesn't appear in these sections, which are set to be "galleries".

I suppose, that it needs only minor modifications of conditions in some places to appear also in these sections using another versions of templates, but my attempts were useless so far :-(.

Could you please direct me to what is needed to get this work also in mentioned situation with another versions of mentioned templates? I would like to use your rating modification in "gallery showthread" and "standard vB showthread" as well, but if it is too complicated, then I rather choose only "gallery showthread", becouse I really need better presentation of thread rating in these sections.

I really like your solution and I would like to use it also for our "galleries" (I looked for some hack just becouse of using it in our "galleries"). Please, help :-).

mad@Max
10-29-2008, 05:10 AM
Wow, how many words:) Please, type your site.

Charles_1
10-29-2008, 08:48 AM
Wow, how many words:) Please, type your site.
Thanks for fast reply. Our forum is www.svethardware.cz/forum and section with mentioned functionality of simple gallery is for example this: http://www.svethardware.cz/forum/forumdisplay.php?f=212 (we have competition for our users in creating wallpapers on specific topic, every month new round with new topic and this way via only modified templates it is the best for this purpose - I don't want to use for this some special gallery with own database, comments and rating system). For viewing wallpaper (picture) in full size is needed to be logged in, but if you click on name of thread (first row in small boxes in forumdisplay), then you will se own template showthread of this gallery plugin.

Your plugin is disabled for whole forum right now. If you need it to be enabled somewhere for info, just let me know.

Sarthek
10-29-2008, 10:17 PM
Installed, tnx

Two questions, if later for some reason (no support or whatever) we unistalled it, ratings still stay?

Can we somehowe enable guests to viewing rating?

Taragon
12-01-2008, 05:23 PM
Would it be possible to have the ajax rating bit (stars) only for vb blog as well perhaps?
If preferred after some kind of donation of course.

mad@Max
12-01-2008, 06:09 PM
Sarthek, no, this future only for members.
Taragon, hm, if rating working in blogs, you can add condition like if(THIS_SCRIPT == 'blog')
{
code
}

Tarfandestan
12-04-2008, 01:26 PM
tanx for your hack.
how can change the place of this bar in threads?
I want set it between quick reply and posts.

mad@Max
12-04-2008, 04:15 PM
Tarfandestan, hm, you need little rewrite code...
Find in plugin Threads rating (showthread_complete)$vbulletin->templatecache['SHOWTHREAD'] = str_replace('$navbar', '$navbar'.$vbulletin->templatecache['trate'], $vbulletin->templatecache['SHOWTHREAD']);
Replace with$vbulletin->templatecache['SHOWTHREAD'] = str_replace('$trcode', $vbulletin->templatecache['trate'], $vbulletin->templatecache['SHOWTHREAD']);
Now put $trcode in template SHOWTHREADbetween quick reply and posts
:)

Tarfandestan
12-04-2008, 09:16 PM
tanx a lot man. its ok right now.

mad@Max
12-04-2008, 11:56 PM
Welcome ;)

kmohamed
12-11-2008, 02:04 AM
this is one of the greatest hacks (my opinion) lol its small but it makes ur site looks great
thank u
should i be afraid of any bugs

kruchczan
12-14-2008, 12:31 PM
After the vote, zie shows me the result :(, the option does not work who voted :(, what I was doing wrong? please help

kmohamed
12-14-2008, 05:01 PM
After the vote, zie shows me the result :(, the option does not work who voted :(, what I was doing wrong? please help

you have to upload all of the files inside the zip file to your forum

clientscript---------------------------------->forum
images-------------------------------------->forum
threadratinginfo.php--------------------->forum
:)

kruchczan
12-14-2008, 05:37 PM
I have sent files and partly working, but I have an error javascript :(.


openDreamTRI is not defined
javascript:openDreamTRI(2204)

mad@Max
12-14-2008, 06:24 PM
kruchczan, you need handly add js code...
Tuning:

If you use non default style or just autoreplace in templates not worked, did this:

1) In mod settings enable hand setting

2) In the top of "navbar" template add:

$mdm_tr

kruchczan
12-14-2008, 07:38 PM
I have done and still not working :(.

chikkoo
12-25-2008, 08:21 PM
I can only see the rating in default style. Others it is not working.
Even in default style, I can't see the details of the voting.

DraculaVN
12-27-2008, 04:20 PM
Mod not working in Vbulletin 3.7.4 PL1 :(

mad@Max
12-27-2008, 06:26 PM
Mod will be working on all version vb, while jelsoft will not change voting code:)

kruchczan
12-27-2008, 06:36 PM
apparently forgot about something? does not work correctly!

TaMpE
01-02-2009, 10:50 PM
Hm, no, go in the trate template, find all $stylevar[imgdir_rating]/stars.png, and then replace founded items on <if condition="in_array($thread[forumid], array(1,2,3,4,...,N)">$stylevar[imgdir_rating]/black_stars.png<else />$stylevar[imgdir_rating]/stars.png</if>Where 1,2,3,4,...,N forums with different stars. But resolution of different image must be like stars.png.
Must be work:)

What do you mean? Do I have to cut out each star? It's work showing up like others people's.

rizelim
01-07-2009, 06:33 PM
Thank you very much friends !

mad@Max
01-12-2009, 11:36 PM
Version 1.5
Fixed some bugs, deleted hand opt., some cleanup.

mad@Max
01-13-2009, 04:50 PM
Version 1.5.1
Unified one module.

ZomgStuff
01-13-2009, 04:54 PM
Anyone know if this is working with 3.8?

mad@Max
01-13-2009, 06:15 PM
Yes, working - tested.

Taragon
01-13-2009, 06:26 PM
Thank you!
Do you also happen to have a version with the AJAX rating only perhaps?
I’ve tried to remove the things not needed, however I’m not really sure if I did things right.

mad@Max
01-13-2009, 07:14 PM
Sorry, but i not understand you. What do you mean?

Taragon
01-13-2009, 07:47 PM
Do you have a version available without the ?Who rat this thread? bit available?
I?ve tried to remove this at my forums, but I?m not sure I did things right.

Only leaving this available I mean:
https://vborg.vbsupport.ru/attachment.php?attachmentid=85424&d=1218672720

mad@Max
01-13-2009, 09:40 PM
‘Who rat this thread’lol))))))))))))
No, i not have that version. But why are you don't like this future?

Taragon
01-14-2009, 08:14 AM
Sorry, I wrote that wrong :p
The main reason I guess is my members are getting sometimes a bit confused when seeing lots of features.

mad@Max
01-15-2009, 02:17 PM
Version 1.5.2
Rewrited of one module, for better compatibility.
Taragon, View/Edit rating can only admin groups.

jGas
01-16-2009, 01:41 PM
hi, i use a different showthread template for some forums (and i've called it gars_showthred).

how should i modify the plugin (i suppose Threads rating Cache templates) to include also gars_showthread?
thanks!

mad@Max
01-16-2009, 03:51 PM
Template gars_showthread replaced showthread template?

jGas
01-16-2009, 09:55 PM
It may sound stupid but it doesn't work...even if i change the mod is still visible in showthread but not in gars_showthread!

edit: solved.. i don't know how but now i can see in every template and that's ok!

what about if i'd like to move the box to another position?

thanks for this mod, it's wonderful :D

mad@Max
01-17-2009, 10:51 AM
If you want move box with rating, open Threads rating Maintains and look on stringeval('$navbar .= "' . fetch_template('trate_main') . '";');
Replace $navbar with what you need variable (like $footer), or create your own.

phoxitin
01-27-2009, 07:28 AM
Does this work 3.8.x ??

Taragon
01-27-2009, 08:50 PM
Does this work 3.8.x ??

Yes, it does :)

Battle_Ring
02-07-2009, 12:03 AM
Not working for me. It shows whilie i vote then it disappears

kersti
03-09-2009, 09:43 PM
I'm getting 404 errors - /threadratinginfo.php?threadid=36

How do I fix that?

mad@Max
03-10-2009, 08:09 PM
All files is uploaded?

f4vn
03-13-2009, 06:13 PM
Hi,

Can you help me chang code to vote from this https://vborg.vbsupport.ru/attachment.php?attachmentid=96377&stc=1&d=1236971513
to this https://vborg.vbsupport.ru/attachment.php?attachmentid=96378&stc=1&d=1236971513.

Thanks :),

pawelx1988
03-17-2009, 09:08 AM
The mod is great - thanks! But I have a problem and my friends too.
My forum is on dedicated server, but the ratings is very slow.

When I'm clicking on one of stars to rate - I must wait 3-4 seconds to see the rate, but I see that in your forum I have waited 1 second! :) Can you help me with it?

paul41598
04-02-2009, 03:08 PM
F4VN,

I've changed the template to meet your needs. I wanted it as well.

Replace the trate_main template with this:

<if condition="$show['threadrating']">
<if condition="$show['ratethread']">
<div class="quickajaxrating" style="text-align:center; padding-bottom: 5px; background: #FFDC84; color:#000;"">
<span id="oneclick_container">
<if condition="!$rated">
<noscript>
$vbphrase[rating]:
</noscript>
<form action="threadrate.php?t=$threadid" method="post" id="oneclick_vote_one">
<input type="hidden" name="s" value="$session[dbsessionhash]" /><input type="hidden" name="t" value="$threadid" /><input type="hidden" name="pp" value="$perpage" /><input type="hidden" name="page" value="$pagenumber" /><input type="hidden" name="vote" value="1" /><input type="submit" value="1" style="display:none;"/>
<noscript>
<input type="submit" value="1" />
</noscript>
</form>
<form action="threadrate.php?t=$threadid" method="post" id="oneclick_vote_two">
<input type="hidden" name="s" value="$session[dbsessionhash]" /><input type="hidden" name="t" value="$threadid" /><input type="hidden" name="pp" value="$perpage" /><input type="hidden" name="page" value="$pagenumber" /><input type="hidden" name="vote" value="2" /><input type="submit" value="1" style="display:none;"/>
<noscript>
<input type="submit" value="2" />
</noscript>
</form>
<form action="threadrate.php?t=$threadid" method="post" id="oneclick_vote_three">
<input type="hidden" name="s" value="$session[dbsessionhash]" /><input type="hidden" name="t" value="$threadid" /><input type="hidden" name="pp" value="$perpage" /><input type="hidden" name="page" value="$pagenumber" /><input type="hidden" name="vote" value="3" /><input type="submit" value="1" style="display:none;"/>
<noscript>
<input type="submit" value="3" />
</noscript>
</form>
<form action="threadrate.php?t=$threadid" method="post" id="oneclick_vote_four">
<input type="hidden" name="s" value="$session[dbsessionhash]" /><input type="hidden" name="t" value="$threadid" /><input type="hidden" name="pp" value="$perpage" /><input type="hidden" name="page" value="$pagenumber" /><input type="hidden" name="vote" value="4" /><input type="submit" value="1" style="display:none;"/>
<noscript>
<input type="submit" value="4" />
</noscript>
</form>
<form action="threadrate.php?t=$threadid" method="post" id="oneclick_vote_five">
<input type="hidden" name="s" value="$session[dbsessionhash]" /><input type="hidden" name="t" value="$threadid" /><input type="hidden" name="pp" value="$perpage" /><input type="hidden" name="page" value="$pagenumber" /><input type="hidden" name="vote" value="5" /><input type="submit" value="1" style="display:none;"/>
<noscript>
<input type="submit" value="5" />
</noscript>
</form>
<script type="text/javascript">
<!--
var threadid = $threadinfo[threadid];
document.write('<table cellpadding="$stylevar[cellpadding]" cellspacing="0" border="5" width="100%"><tr><td align="right" width="45%" nowrap="nowrap"><div><strong>$vbphrase[trate_rateit]</strong></div></td><td align="left" width="$widthcolumn%" nowrap="nowrap"><div class="current-rating" style="width:$current_rating;"><label for="vote5"><input type="radio" name="vote" id="oneclick_vote_five_submit" value="5" $votechecked[5] />$vbphrase[excellent]</label><label for="vote4"><input type="radio" name="vote" id="oneclick_vote_four_submit" value="4" $votechecked[4] />$vbphrase[good]</label><label for="vote3"><input type="radio" name="vote" id="oneclick_vote_three_submit" value="3" $votechecked[3] />$vbphrase[average]</label><label for="vote2"><input type="radio" name="vote" id="oneclick_vote_two_submit" value="2" $votechecked[2] />$vbphrase[bad]</label><label for="vote1"><input type="radio" name="vote" id="oneclick_vote_one_submit" value="1" $votechecked[1] />$vbphrase[terrible]</label></div></div></td>$evr</tr></table>');
-->
</script>
<script type="text/javascript" src="clientscript/vbulletin_ajax_oneclick_threadrate.js?v=$vboptions[simpleversion]">
</script>
<script type="text/javascript">
<!--
var threadid = $threadinfo[threadid];
vB_AJAX_OneClick_ThreadRate_Init('oneclick_vote_on e');
vB_AJAX_OneClick_ThreadRate_Init('oneclick_vote_tw o');
vB_AJAX_OneClick_ThreadRate_Init('oneclick_vote_th ree');
vB_AJAX_OneClick_ThreadRate_Init('oneclick_vote_fo ur');
vB_AJAX_OneClick_ThreadRate_Init('oneclick_vote_fi ve');
-->
</script>
<else />
<div align="center" style="font-size: 15px; font-family: verdana; font-weight: bold;">You have already rated this thread!</div> </if>
<table cellpadding="$stylevar[cellpadding]" cellspacing="0" border="0" width="100%">
<tr>
<td align="right" width="45%" nowrap="nowrap">
<div>
<strong>$vbphrase[trate_currate]</strong>
</div>
</td>
<td align="left" width="$widthcolumn%" nowrap="nowrap">

<ul class="star-rating" title="<phrase 1="$thread[votenum]" 2="$thread[voteavg]">$vbphrase[thread_rating_x_votes_y_average]</phrase>">
<li class="current-rating" style="width:$current_rating;">
</li>
</ul>
</td>$evr
</tr>
</table>
</if>
</span>
<span id="oneclick_threadrating_current"></span>
<span id="oneclick_threadrating_response"></span>
</div>
</if>
<br/>

jGas
04-08-2009, 04:24 PM
hi, i'm using this mod and i really love it!
is there a way to have the thread rating with 10 stars instead of 5?

thanks :D

mad@Max
04-09-2009, 08:29 AM
Now i'm working on a new version, and in it i will add a feature with 10 points. So, wait for version 2.0....

Arkham
04-13-2009, 04:32 PM
Is it possible to use the info from the "show user's rating" in the post itself?

E.g. in the header of each post, show what that particular user rated that thread? This feature is something I desperately need.

Looking forward to the new version!

Acido
04-21-2009, 02:38 PM
This is not working in 3.8.2

Arkham
04-21-2009, 02:49 PM
This is not working in 3.8.2

Crap. I was just going to install it, too.

Anyone know if it at least works w/3.8.1?

Taragon
04-21-2009, 09:46 PM
Crap. I was just going to install it, too.

Anyone know if it at least works w/3.8.1?

I guess it will work from 3.6.4 until at least 3.8.2

mindhunter77
04-30-2009, 08:57 PM
Where would I go to edit the white space between this MOD, and my banner? Any ideas, I have looked for an hour lol..

chjp
05-03-2009, 05:19 AM
I like it. Thank you.

EagleNick
06-14-2009, 06:22 PM
Hello,

Can you add an option to manually include the variable to show the ratings? I'd like to move the rating area to a customized area within the thread, and not right after $navbar.

How can I do this?

Thanks.

Dennis Kaczor
06-19-2009, 06:41 PM
F4VN,

I've changed the template to meet your needs. I wanted it as well.

Replace the trate_main template with this:

<if condition="$show['threadrating']">
<if condition="$show['ratethread']">
<div class="quickajaxrating" style="text-align:center; padding-bottom: 5px; background: #FFDC84; color:#000;"">
<span id="oneclick_container">
<if condition="!$rated">
<noscript>
$vbphrase[rating]:
</noscript>
<form action="threadrate.php?t=$threadid" method="post" id="oneclick_vote_one">
<input type="hidden" name="s" value="$session[dbsessionhash]" /><input type="hidden" name="t" value="$threadid" /><input type="hidden" name="pp" value="$perpage" /><input type="hidden" name="page" value="$pagenumber" /><input type="hidden" name="vote" value="1" /><input type="submit" value="1" style="display:none;"/>
<noscript>
<input type="submit" value="1" />
</noscript>
</form>
<form action="threadrate.php?t=$threadid" method="post" id="oneclick_vote_two">
<input type="hidden" name="s" value="$session[dbsessionhash]" /><input type="hidden" name="t" value="$threadid" /><input type="hidden" name="pp" value="$perpage" /><input type="hidden" name="page" value="$pagenumber" /><input type="hidden" name="vote" value="2" /><input type="submit" value="1" style="display:none;"/>
<noscript>
<input type="submit" value="2" />
</noscript>
</form>
<form action="threadrate.php?t=$threadid" method="post" id="oneclick_vote_three">
<input type="hidden" name="s" value="$session[dbsessionhash]" /><input type="hidden" name="t" value="$threadid" /><input type="hidden" name="pp" value="$perpage" /><input type="hidden" name="page" value="$pagenumber" /><input type="hidden" name="vote" value="3" /><input type="submit" value="1" style="display:none;"/>
<noscript>
<input type="submit" value="3" />
</noscript>
</form>
<form action="threadrate.php?t=$threadid" method="post" id="oneclick_vote_four">
<input type="hidden" name="s" value="$session[dbsessionhash]" /><input type="hidden" name="t" value="$threadid" /><input type="hidden" name="pp" value="$perpage" /><input type="hidden" name="page" value="$pagenumber" /><input type="hidden" name="vote" value="4" /><input type="submit" value="1" style="display:none;"/>
<noscript>
<input type="submit" value="4" />
</noscript>
</form>
<form action="threadrate.php?t=$threadid" method="post" id="oneclick_vote_five">
<input type="hidden" name="s" value="$session[dbsessionhash]" /><input type="hidden" name="t" value="$threadid" /><input type="hidden" name="pp" value="$perpage" /><input type="hidden" name="page" value="$pagenumber" /><input type="hidden" name="vote" value="5" /><input type="submit" value="1" style="display:none;"/>
<noscript>
<input type="submit" value="5" />
</noscript>
</form>
<script type="text/javascript">
<!--
var threadid = $threadinfo[threadid];
document.write('<table cellpadding="$stylevar[cellpadding]" cellspacing="0" border="5" width="100%"><tr><td align="right" width="45%" nowrap="nowrap"><div><strong>$vbphrase[trate_rateit]</strong></div></td><td align="left" width="$widthcolumn%" nowrap="nowrap"><div class="current-rating" style="width:$current_rating;"><label for="vote5"><input type="radio" name="vote" id="oneclick_vote_five_submit" value="5" $votechecked[5] />$vbphrase[excellent]</label><label for="vote4"><input type="radio" name="vote" id="oneclick_vote_four_submit" value="4" $votechecked[4] />$vbphrase[good]</label><label for="vote3"><input type="radio" name="vote" id="oneclick_vote_three_submit" value="3" $votechecked[3] />$vbphrase[average]</label><label for="vote2"><input type="radio" name="vote" id="oneclick_vote_two_submit" value="2" $votechecked[2] />$vbphrase[bad]</label><label for="vote1"><input type="radio" name="vote" id="oneclick_vote_one_submit" value="1" $votechecked[1] />$vbphrase[terrible]</label></div></div></td>$evr</tr></table>');
-->
</script>
<script type="text/javascript" src="clientscript/vbulletin_ajax_oneclick_threadrate.js?v=$vboptions[simpleversion]">
</script>
<script type="text/javascript">
<!--
var threadid = $threadinfo[threadid];
vB_AJAX_OneClick_ThreadRate_Init('oneclick_vote_on e');
vB_AJAX_OneClick_ThreadRate_Init('oneclick_vote_tw o');
vB_AJAX_OneClick_ThreadRate_Init('oneclick_vote_th ree');
vB_AJAX_OneClick_ThreadRate_Init('oneclick_vote_fo ur');
vB_AJAX_OneClick_ThreadRate_Init('oneclick_vote_fi ve');
-->
</script>
<else />
<div align="center" style="font-size: 15px; font-family: verdana; font-weight: bold;">You have already rated this thread!</div> </if>
<table cellpadding="$stylevar[cellpadding]" cellspacing="0" border="0" width="100%">
<tr>
<td align="right" width="45%" nowrap="nowrap">
<div>
<strong>$vbphrase[trate_currate]</strong>
</div>
</td>
<td align="left" width="$widthcolumn%" nowrap="nowrap">

<ul class="star-rating" title="<phrase 1="$thread[votenum]" 2="$thread[voteavg]">$vbphrase[thread_rating_x_votes_y_average]</phrase>">
<li class="current-rating" style="width:$current_rating;">
</li>
</ul>
</td>$evr
</tr>
</table>
</if>
</span>
<span id="oneclick_threadrating_current"></span>
<span id="oneclick_threadrating_response"></span>
</div>
</if>
<br/>

Very nice work here Paul, and I have added this to my system. I have one question if this is possible as I'm not a coder. Rather than the user trying to move the mouse over the little radio button, have it so that it highlights the button when you move over the text area for that selection? Just a thought...

Dennis

xyzmary2001
07-17-2009, 11:11 AM
Will it be an update for vB 3.8.2? My users love it, it will be a shame to give up on it after I will make the update to vb 3.8.

@edit: Just checked and works perfectly with 3.8.2.

AndrusW
08-02-2009, 09:52 AM
Works perfectly for me in 3.83 also.

Verionia
08-04-2009, 03:35 PM
Works perfectly for me in 3.83 also.

Yes works perfect for 3.83 but how can I change images to the ones here on VB or different stars?

Verionia
08-04-2009, 08:35 PM
Wait... i had to uninstall as this is already implemented in 3.83... :o

Taragon
08-04-2009, 09:45 PM
Wait... i had to uninstall as this is already implemented in 3.83... :o
Rating, yes. Ajax rating, no.

Verionia
08-05-2009, 03:11 AM
Rating, yes. Ajax rating, no.

But Im having a problem... I cant rate threads on my forums anymore...everytime I click the rate button, nothing happens! :(

Tiberonmagnus
08-15-2009, 03:06 AM
Is there a method to make it so I can include the "View Rating" graph below the 5 star selection area? I'm talking about the information you get about who voted on the 5 stars after you press the "Edit/View Rating" button to the right of the stars. I can get it to appear below the 5 star selection area, but it doesn't show any numbers at all. Am I missing something?

mad@Max
08-20-2009, 05:10 PM
Finally, i rewrote the hack https://vborg.vbsupport.ru/showthread.php?t=221364.