Forum Index
RegisterSearchFAQMemberlistUsergroupsLog in
News rating (ajax)
Goto page Previous  1, 2, 3, 4, 5, 6, 7  Next
 
Reply to topic    Forum Index » Additional Downloads View previous topic
View next topic
News rating (ajax)
Author Message
astrostart



Joined: 11 Feb 2007
Posts: 124
Location: The Netherlands

Post Reply with quote
FI-DD, what do you think of the style of .gif I use for my ratings?



http://www.astrostart.nl/index.php/2007/03/14/subaru-fotografeert-de-krabnevel.html



I attached it, if others want to us it!



star_10.gif
 Description:
 Filesize:  280 Bytes
 Viewed:  667 Time(s)

star_10.gif



_________________
My site: http://www.astrostart.nl | Thanks to everyone here who has helped me!
Fri Mar 16, 2007 2:39 pm View user's profile Send private message Visit poster's website
Guest








Please login to hide the ads.

FI-DD
Admin


Joined: 22 Sep 2005
Posts: 2857
Location: Germany

Post Reply with quote
Fits nicely your layout. Smile



Btw, you know that on your page the average rating and total votes only update after reloading the page, don't you?
Fri Mar 16, 2007 2:56 pm View user's profile Send private message
astrostart



Joined: 11 Feb 2007
Posts: 124
Location: The Netherlands

Post Reply with quote
Yup I know. Thats just with Firefox, right?

_________________
My site: http://www.astrostart.nl | Thanks to everyone here who has helped me!
Fri Mar 16, 2007 3:24 pm View user's profile Send private message Visit poster's website
FI-DD
Admin


Joined: 22 Sep 2005
Posts: 2857
Location: Germany

Post Reply with quote
No, it's because you removed the divs around the tags.



The code is supposed to look like this:

Code:
<div id="rating_middle{id}">{rating-middle}</div>




Never tried it but this should work too:

Code:
<b id="rating_middle{id}">{rating-middle}</b>

Fri Mar 16, 2007 3:51 pm View user's profile Send private message
astrostart



Joined: 11 Feb 2007
Posts: 124
Location: The Netherlands

Post Reply with quote
I have this:



<div id="ratingform{id}">{rating:10:10}</div>



Is that not good?

_________________
My site: http://www.astrostart.nl | Thanks to everyone here who has helped me!
Fri Mar 16, 2007 4:48 pm View user's profile Send private message Visit poster's website
astrostart



Joined: 11 Feb 2007
Posts: 124
Location: The Netherlands

Post Reply with quote
Oh you mean rating_middle.



You're right! Smile



But if i do <div></div> I get an enter after rating-middle, but it should be on the same line. That's why I deleted the <div> tags from rating-middle.

_________________
My site: http://www.astrostart.nl | Thanks to everyone here who has helped me!
Fri Mar 16, 2007 4:51 pm View user's profile Send private message Visit poster's website
scottdallas



Joined: 04 May 2006
Posts: 2027
Location: US

Post Reply with quote
I can't get it to write the rating in the {short-story} it just sits at Please Wait... so how could I just put the {rating} like I used to and when they are in {full-story} they can do the AJAX rating?



Also, how can I make the <div id="rating_total{id}"> tags to stop line breaking their results?



For example:





My code is:

Code:
<b>Ratings:</b>&nbsp;<div id="rating_total{id}">{rating-total}</div>


_________________
www.scodal.com is an example of cnr as a social forum - www.scottdizzle.com is an example of cnr as a personal website to share whatever cool stuff i feel like. i have another, but it's nsfw. pm me Wink
Fri Mar 16, 2007 9:40 pm View user's profile Send private message Visit poster's website AIM Address
rats



Joined: 29 May 2006
Posts: 44

Post Reply with quote
mine is just getting stuck with "Please wait..." after rating Sad
Sat Mar 17, 2007 6:19 pm View user's profile Send private message
scottdallas



Joined: 04 May 2006
Posts: 2027
Location: US

Post Reply with quote
oh i guess i've just repeated the same issue a few others are having. sorry about that

_________________
www.scodal.com is an example of cnr as a social forum - www.scottdizzle.com is an example of cnr as a personal website to share whatever cool stuff i feel like. i have another, but it's nsfw. pm me Wink
Sun Mar 18, 2007 12:12 am View user's profile Send private message Visit poster's website AIM Address
FI-DD
Admin


Joined: 22 Sep 2005
Posts: 2857
Location: Germany

Post Reply with quote
astrostart wrote:
But if i do <div></div> I get an enter after rating-middle, but it should be on the same line. That's why I deleted the <div> tags from rating-middle.


Use float:left in your css. Check the template on the example page.
Mon Mar 19, 2007 4:27 pm View user's profile Send private message
FI-DD
Admin


Joined: 22 Sep 2005
Posts: 2857
Location: Germany

Post Reply with quote
scottdallas wrote:
Also, how can I make the <div id="rating_total{id}"> tags to stop line breaking their results?



Use float:left in your css. Check the template on the example page.
Mon Mar 19, 2007 4:35 pm View user's profile Send private message
astrostart



Joined: 11 Feb 2007
Posts: 124
Location: The Netherlands

Post Reply with quote
Is this possible?



I have a lot of visitors who just vote '1'.



Is it possible that if visitors vote '1', the IP gets stored, but the score isn't saved in the database.



So they cannot vote on the same newsmessage again, just because they rated it too low.



Hopefully this is the way to get rid of the spammers. Rolling Eyes

_________________
My site: http://www.astrostart.nl | Thanks to everyone here who has helped me!
Thu Mar 22, 2007 8:07 am View user's profile Send private message Visit poster's website
twist



Joined: 05 Jan 2007
Posts: 28

Post Issues Reply with quote
I'm having more problems than usual with this script. Let's see.



I'm having line break issues, but I think that was covered above, so I'll try floating the ratings details.



I'm also getting stuck seeing "Please Wait..." after rating. If I then refresh, I can't rate at all and my rating isn't reflected in the totals or on the stars.



If I then go to the options settings, and attempt to remove the ratings for the article, it says (1) item deleted, but it is still showing up in the Configuration settings. If I hit refresh they are still there as well. If I go to the database, the ratings table is empty.



Also, where is the settings to allow/disallow IP/Cookie blocking?



**Update** I did a full re-install and everything seems to be working.



I've attempted to resize the 25px stars. Made a new graphic which is 20px and then edited the stars.css file with the new widths. I did all of this inside of rating25. Inside my template I call the new new graphics as {rating:5:25} the problem is 6 stars are displayed instead of 5. When I hover over the 5, everything functions as needed. There's just an extra gray 6th star which can not be hovered over etc. If I increase this to 6:25, I still get an extra. I made some CSS adjustments but none of the changes seemed to remove the extra star.



**Update** Have to love figuring our your own problems. The width is hard coded in the ratings.php file. So if you want to create new size stars other than 10/25/30 - duplicate all of the values in the stars.css file and rename them to the new size. ie: .ratingblock20.
Sat Mar 24, 2007 10:42 pm View user's profile Send private message
FI-DD
Admin


Joined: 22 Sep 2005
Posts: 2857
Location: Germany

Post Reply with quote
astrostart wrote:
Is it possible that if visitors vote '1', the IP gets stored, but the score isn't saved in the database


In plugins/rating/rating.php change this:

Code:
         $sql->update(array(

                 'table'  => 'news',

                 'where'  => array("id = ".$news_id),

                 'values' => array(

                            'rating'   => $new_rating,

                            'votes'   => $new_votes

                            )

                 ));




to this:

Code:
      if($rating > 1){

         $sql->update(array(

                 'table'  => 'news',

                 'where'  => array("id = ".$news_id),

                 'values' => array(

                            'rating'   => $new_rating,

                            'votes'   => $new_votes

                            )

                 ));

      }




(Not tested.)
Mon Mar 26, 2007 3:31 pm View user's profile Send private message
rats



Joined: 29 May 2006
Posts: 44

Post Reply with quote
looks like the stuck thing has to do something with the cookie... I got stuck also, but when disableing the cookie part in the conf, it works.



edit: after enable/disable the cookie part, it works perfect Confused
Tue Apr 03, 2007 5:17 pm View user's profile Send private message
Display posts from previous:    
Reply to topic    Forum Index » Additional Downloads All times are GMT + 1 Hour
Goto page Previous  1, 2, 3, 4, 5, 6, 7  Next
Page 3 of 7

 
Jump to: 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum



Powered by phpBB © 2001, 2005 phpBB Group
Design by Freestyle XL / Music Lyrics.