sabret00the
06-10-2004, 07:21 PM
can you spot anything wrong with this code?
if ($action==report)
{
if ($bbuserinfo[usergroupid] > 0)
{
eval("\$report_form = \"".fetch_template("confessions_reportform")."\";");
if ($confirm==report)
{
if ($bbuserinfo[usergroupid] > 0 && $action == 'report' && $confessionid && $reason)
{
$body = "Please review confession $confessionid and take
appropriate action as you see fit\n\nReason given:\n
$reason\n\n$confessionurl\n\nThank You\n$bbuserinfo[username]";
vbmail($vboptions[$webmasteremail], 'Reporting A Confession', $body,
"From: \"$bbtitle Mailer\" <$vboptions[webmasteremail]>");
}
}
}
else
{
$url = "../confessions/";
eval(print_standard_redirect("confess_error_shouldnotbehere"));
}
}
it's within this if ($confessionid!='')
{
...
}
the second php tag opens the page "?confessionid=$confessionid"
where as the top php tag will go to ?confessionid=$confessionid&action=report" well should do anyway however it doesn't seem to want too and lastly since the '&action=report' is a form, the submitted data will go to "?confessionid=$confessionid&action=report&confirm=report"
if ($action==report)
{
if ($bbuserinfo[usergroupid] > 0)
{
eval("\$report_form = \"".fetch_template("confessions_reportform")."\";");
if ($confirm==report)
{
if ($bbuserinfo[usergroupid] > 0 && $action == 'report' && $confessionid && $reason)
{
$body = "Please review confession $confessionid and take
appropriate action as you see fit\n\nReason given:\n
$reason\n\n$confessionurl\n\nThank You\n$bbuserinfo[username]";
vbmail($vboptions[$webmasteremail], 'Reporting A Confession', $body,
"From: \"$bbtitle Mailer\" <$vboptions[webmasteremail]>");
}
}
}
else
{
$url = "../confessions/";
eval(print_standard_redirect("confess_error_shouldnotbehere"));
}
}
it's within this if ($confessionid!='')
{
...
}
the second php tag opens the page "?confessionid=$confessionid"
where as the top php tag will go to ?confessionid=$confessionid&action=report" well should do anyway however it doesn't seem to want too and lastly since the '&action=report' is a form, the submitted data will go to "?confessionid=$confessionid&action=report&confirm=report"