Ejemplo n.º 1
0
function theme_dir()
{
    $current_theme = get_current_theme_name();
    if (empty($current_theme) || !file_exists(template_path($current_theme) . DIRECTORY_SEPARATOR)) {
        $current_theme = 'default';
    }
    return template_path($current_theme) . DIRECTORY_SEPARATOR;
}
Ejemplo n.º 2
0
        //Get status
        $status = $FAUCET->status();
    } else {
        //SpammerSlapper Failed
        $status = SF_STATUS_PAYOUT_ERROR;
    }
} elseif (isset($_POST["cryptocoin_address"])) {
    //BAD CAPTCHA
    $status = SF_STATUS_CAPTCHA_INCORRECT;
} else {
    //No Submition
    $status = $FAUCET->status();
}
// statistics:
$vars['stats'] = $FAUCET->get_stats();
//Save Status
$vars['status'] = $status;
//TODO: I need to think of a better way to do this
$show_form = faucet_eval_status($status, $vars, $LANGUAGE, $SETTINGS);
if ($show_form) {
    // Render Captcha
    $vars['captcha'] = faucet_get_captcha($SETTINGS);
    // Render Form
    $vars['content'] = render_template(faucet_get_content('form'), $vars);
} else {
    // Render Error/Status
    $vars['content'] = render_template(faucet_get_content('status'), $vars);
}
// Render full page
print render_template(template_file("page.tpl.php", get_current_theme_name()), $vars);