1 (edited by raptrex 2007-06-24 01:24)

Topic: ajax rating

ok im during this on my local computer, not on a host

im trying to get this ajax rating script to work with punbb
http://www.masugadesign.com/the-lab/scr … ating-bar/

ok first you have to put this on top of your script

<?php require('_drawrating.php'); ?>

if i put that in header.php i get this error

Fatal error: Cannot redeclare rating_bar() (previously declared in C:\xampplite\htdocs\punbb\_drawrating.php:14) in C:\xampplite\htdocs\punbb\_drawrating.php on line 94

im calling rating_bar like this in viewtopic.php

<?php echo rating_bar($id); ?>

can someone help me get this to work

and all the files that are needed are with viewtopic, index ....ect
and in /img and in /js

Re: ajax rating

lol nvm
ok i fixed this by adding
<?php require('_drawrating.php'); ?>
to the top of viewtopic.php

and to have a rating for each topic i did this
<?php echo rating_bar($id,''); ?>

and then call the css files and js files in header.php
and it works perfectly!!!!!

so topic resolved...

3 (edited by bingiman 2008-09-06 02:46)

Re: ajax rating

This rating system is great but if I log in as a different user the rating system is locked and no one else can vote. do you have the same problem?

Bingiman