예제 #1
0
파일: clean.php 프로젝트: ITw3/redaxscript
/**
 * clean
 *
 * @since 1.2.1
 * @deprecated 2.0.0
 *
 * @package Redaxscript
 * @category Clean
 * @author Henry Ruhs
 *
 * @param string $input
 * @param integer $mode
 * @return string
 */
function clean($input = '', $mode = '')
{
    $output = $input;
    /* if untrusted user */
    if (FILTER == 1) {
        if ($mode == 0) {
            $output = clean_special($output);
        }
        if ($mode == 1) {
            $output = clean_script($output);
            $output = clean_html($output);
        }
    }
    /* type related clean */
    if ($mode == 2) {
        $output = clean_alias($output);
    }
    if ($mode == 3) {
        $output = clean_email($output);
    }
    if ($mode == 4) {
        $output = clean_url($output);
    }
    /* mysql clean */
    $output = clean_mysql($output);
    return $output;
}
예제 #2
0
파일: index.php 프로젝트: ITw3/redaxscript
/**
 * call home admin notification start
 *
 * @since 1.2.1
 * @deprecated 2.0.0
 *
 * @package Redaxscript
 * @category Modules
 * @author Henry Ruhs
 */
function call_home_admin_notification_start()
{
    /* get contents */
    $url = 'http://service.redaxscript.com/version/' . clean_alias(l('redaxscript_version'));
    $contents = file_get_contents($url);
    /* collect output */
    if ($contents) {
        $output = $contents;
    }
    echo $output;
}