jsell
09-06-2002, 03:33 PM
Hey everyone first of all i would like ot thank you in advance for the help but here it goes
i am trying to hack my own "admin Recommended" type of hack where I replace the post icon's with a yes or a no icon at my choosing. I want it to show up in the forumdisplay when i choose if i want to reccomend the thread or not. I have everything working except it doesn;t diplay the icon's correctly. obviously there is soemthing wrong with my code. I am pretty new to php and to Vbulletin so please go easy one me.
// reco hack
unset($recodata);
unset($reco);
$recodata=$DB_site->query("SELECT reco from recodata data WHERE threadid='$threadid'");
if (($recodata[recomend]==1)) {
eval("\$reco= \"".gettemplate("reco_yes")."\";");
} else {
eval("\$reco= \"".gettemplate("reco_no")."\";");
}
}
//end add reco hack
above is the code i am using in forumdisplay.php
what happens is that is displays only the "reco_no" template
it's like it's either not getting the info from the query or it's using the same info for every thread (i think)
can some one please help
again thanks
Jsell
i am trying to hack my own "admin Recommended" type of hack where I replace the post icon's with a yes or a no icon at my choosing. I want it to show up in the forumdisplay when i choose if i want to reccomend the thread or not. I have everything working except it doesn;t diplay the icon's correctly. obviously there is soemthing wrong with my code. I am pretty new to php and to Vbulletin so please go easy one me.
// reco hack
unset($recodata);
unset($reco);
$recodata=$DB_site->query("SELECT reco from recodata data WHERE threadid='$threadid'");
if (($recodata[recomend]==1)) {
eval("\$reco= \"".gettemplate("reco_yes")."\";");
} else {
eval("\$reco= \"".gettemplate("reco_no")."\";");
}
}
//end add reco hack
above is the code i am using in forumdisplay.php
what happens is that is displays only the "reco_no" template
it's like it's either not getting the info from the query or it's using the same info for every thread (i think)
can some one please help
again thanks
Jsell