mucka_tbfm
Mucka Jay
We have 17 categories and we only want the vote button visible in one category at a time. Is this an easy thing to do before we start trying to take the code apart?
$TMPL['custom_vote_button'] = '';
if ($TMPL['category'] == 'heat 01')
{
$TMPL['custom_vote_button'] = "<a href=\"{$TMPL['list_url']}/index.php?a=in&u={$TMPL['username']}\" class=\"stats_vote\" rel=\"nofollow\">VOTE</a>";
}
<?php
if (!defined('VISIOLIST')) {
die("This file cannot be accessed directly.");
}
?>
$TMPL['custom_vote_button'] = '';
if ($TMPL['cat_exist'] && $TMPL['cat_exist'] == 'heat 01')
{
$TMPL['custom_vote_button'] = "<a href=\"{$TMPL['list_url']}/index.php?a=in&u={$TMPL['username']}\" class=\"stats_vote\" rel=\"nofollow\">VOTE</a>";
}
$TMPL['custom_gateway'] = '';
if ($TMPL['category'] == 'Heat 01')
{
$TMPL['custom_gateway'] = "<a href=\"{$TMPL['list_url']}\" class=\"visio_button large_button_red\" <span>Enter without voting</span></a><a href=\"{$TMPL['list_url']}/index.php?a=in&u={$TMPL['username']}&sid={$TMPL['sid']}\" class=\"visio_button large_button_green\" <span>Enter and vote</span></a>";
}
if($TMPL['category'] != 'Heat 01') {
header("Location: {$CONF['list_url']}/");
exit;
}