• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP print_stop_message函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中print_stop_message函数的典型用法代码示例。如果您正苦于以下问题:PHP print_stop_message函数的具体用法?PHP print_stop_message怎么用?PHP print_stop_message使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了print_stop_message函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: verify_upload_folder

function verify_upload_folder($attachpath)
{
	global $vbphrase;
	if ($attachpath == '')
	{
		print_stop_message('please_complete_required_fields');
	}

	if (!is_dir($attachpath . '/test'))
	{
		@umask(0);
		if (!@mkdir($attachpath . '/test', 0777))
		{
			print_stop_message('test_file_write_failed', $attachpath);
		}
	}
	@chmod($attachpath . '/test', 0777);
	if ($fp = @fopen($attachpath . '/test/test.attach', 'wb'))
	{
		fclose($fp);
		if (!@unlink($attachpath . '/test/test.attach'))
		{
			print_stop_message('test_file_write_failed', $attachpath);
		}
		@rmdir($attachpath . '/test');
	}
	else
	{
		print_stop_message('test_file_write_failed', $attachpath);
	}
}
开发者ID:hungnv0789,项目名称:vhtm,代码行数:31,代码来源:adminfunctions_attachment.php


示例2: verify_upload_folder

function verify_upload_folder($imagepath)
{
    global $vbphrase;
    if ($imagepath == '') {
        print_stop_message('please_complete_required_fields');
    }
    if ($fp = @fopen($imagepath . '/test.image', 'wb')) {
        fclose($fp);
        if (!@unlink($imagepath . '/test.image')) {
            print_stop_message('test_file_write_failed', $imagepath);
        }
        return true;
    } else {
        print_stop_message('test_file_write_failed', $imagepath);
    }
}
开发者ID:holandacz,项目名称:nb4,代码行数:16,代码来源:avatar.php


示例3: construct_hidden_code

         construct_hidden_code('group', $vbulletin->GPC['group']);
         construct_hidden_code('searchstring', $vbulletin->GPC['searchstring']);
         construct_hidden_code('dostyleid', $vbulletin->GPC['dostyleid']);
         construct_hidden_code('product', $vbulletin->GPC['product']);
         construct_hidden_code('savehistory', intval($vbulletin->GPC['savehistory']));
         construct_hidden_code('histcomment', $vbulletin->GPC['histcomment']);
         print_table_header($vbphrase['vbulletin_message']);
         print_description_row(construct_phrase($vbphrase['template_eval_error'], $errors));
         print_submit_row($vbphrase['continue'], 0, 2, $vbphrase['go_back']);
         print_cp_footer();
         exit;
     }
 }
 $old_template = $db->query_first("\n\t\tSELECT title, styleid, dateline, username, template_un\n\t\tFROM " . TABLE_PREFIX . "template\n\t\tWHERE templateid = " . $vbulletin->GPC['templateid'] . "\n\t");
 if (strtolower($vbulletin->GPC['title']) != strtolower($old_template['title']) and $db->query_first("\n\t\tSELECT templateid\n\t\tFROM " . TABLE_PREFIX . "template\n\t\tWHERE styleid = {$old_template['styleid']} AND title = '" . $db->escape_string($vbulletin->GPC['title']) . "'\n\t")) {
     print_stop_message('template_x_exists', $vbulletin->GPC['title']);
 }
 if ($vbulletin->GPC['lastedit'] and $vbulletin->GPC['lastedit'] != $old_template['dateline']) {
     $comment = construct_phrase($vbphrase['template_edited_after_load'], $old_template['username']);
     echo "<p align=\"center\"><strong>{$comment}</strong></p>";
     /* Save what was in the template into the history */
     $db->query_write("\n\t\t\tINSERT INTO " . TABLE_PREFIX . "templatehistory\n\t\t\t\t(styleid, title, template, dateline, username, version, comment)\n\t\t\tVALUES\n\t\t\t\t({$old_template['styleid']},\n\t\t\t\t'" . $db->escape_string($vbulletin->GPC['title']) . "',\n\t\t\t\t'" . $db->escape_string($old_template['template_un']) . "',\n\t\t\t\t" . TIMENOW . ",\n\t\t\t\t'" . $db->escape_string($vbulletin->userinfo['username']) . "',\n\t\t\t\t'" . $db->escape_string($full_product_info[$vbulletin->GPC['product']]['version']) . "',\n\t\t\t\t'" . $db->escape_string($comment) . "'\n\t\t)");
 }
 $db->query_write("\n\t\tUPDATE " . TABLE_PREFIX . "template SET\n\t\t\ttitle = '" . $db->escape_string($vbulletin->GPC['title']) . "',\n\t\t\ttemplate = '" . $db->escape_string($vbulletin->GPC['template']) . "',\n\t\t\ttemplate_un = '" . $db->escape_string($template_un) . "',\n\t\t\tdateline = " . TIMENOW . ",\n\t\t\tusername = '" . $db->escape_string($vbulletin->userinfo['username']) . "',\n\t\t\tversion = '" . $db->escape_string($full_product_info[$vbulletin->GPC['product']]['version']) . "',\n\t\t\tproduct = '" . $db->escape_string($vbulletin->GPC['product']) . "'\n\t\tWHERE templateid = " . $vbulletin->GPC['templateid'] . "\n\t");
 if (strpos($vbulletin->GPC['title'], 'bbcode_') === 0) {
     // begins with bbcode_ - empty the post parsed cache
     $vbulletin->db->query_write("TRUNCATE TABLE " . TABLE_PREFIX . "postparsed");
 }
 // update any customized templates to reflect a change of product id
 if ($old_template['styleid'] == -1 and $vbulletin->GPC['product'] != $old_template['product']) {
     $db->query_write("\n\t\t\tUPDATE " . TABLE_PREFIX . "template\n\t\t\tSET product = '" . $db->escape_string($vbulletin->GPC['product']) . "'\n\t\t\tWHERE title = '" . $db->escape_string($vbulletin->GPC['title']) . "'\n\t\t\t\tAND styleid <> -1\n\t\t");
开发者ID:holandacz,项目名称:nb4,代码行数:31,代码来源:template.php


示例4: verify_reminder_title_length

function verify_reminder_title_length($title)
{
    global $vbphrase;
    $length = strlen($title);
    if ($length > MAXTITLELENGTH) {
        $diff = $length - MAXTITLELENGTH;
        print_stop_message('reminder_title_too_long', MAXTITLELENGTH, $diff);
    } else {
        return $title;
    }
}
开发者ID:0hyeah,项目名称:yurivn,代码行数:11,代码来源:adminfunctions_reminder.php


示例5: error_reporting

// ######################## SET PHP ENVIRONMENT ###########################
error_reporting(E_ALL & ~E_NOTICE);
if (!is_object($vbulletin->db)) {
    exit;
}
// ########################################################################
// ######################### START MAIN SCRIPT ############################
// ########################################################################
require_once DIR . '/includes/class_sitemap.php';
$runner = new vB_SiteMapRunner_Cron($vbulletin);
$runner->set_cron_item($nextitem);
$status = $runner->check_environment();
if ($status['error']) {
    // if an error has happened, display/log it if necessary and die
    if (VB_AREA == 'AdminCP') {
        print_stop_message($status['error']);
    } else {
        if ($status['loggable']) {
            $rows = $vbulletin->db->query_first("\n\t\t\tSELECT COUNT(*) AS count\n\t\t\tFROM " . TABLE_PREFIX . "adminmessage\n\t\t\tWHERE varname = '" . $vbulletin->db->escape_string($status['error']) . "'\n\t\t\t\tAND status = 'undone'\n\t\t");
            if ($rows['count'] == 0) {
                $vbulletin->db->query_write("\n\t\t\t\tINSERT INTO " . TABLE_PREFIX . "adminmessage\n\t\t\t\t\t(varname, dismissable, script, action, execurl, method, dateline, status)\n\t\t\t\tVALUES\n\t\t\t\t\t('" . $vbulletin->db->escape_string($status['error']) . "',\n\t\t\t\t\t1,\n\t\t\t\t\t'sitemap.php',\n\t\t\t\t\t'buildsitemap',\n\t\t\t\t\t'sitemap.php?do=buildsitemap',\n\t\t\t\t\t'get',\n\t\t\t\t\t" . TIMENOW . ",\n\t\t\t\t\t'undone')\n\t\t\t");
            }
        }
    }
    exit;
}
$runner->generate();
if ($runner->is_finished) {
    $log_text = $runner->written_filename . ', vbulletin_sitemap_index.xml';
} else {
    $log_text = $runner->written_filename;
开发者ID:0hyeah,项目名称:yurivn,代码行数:31,代码来源:sitemap.php


示例6: array

$queryoptions = array('-1' => '', $vbphrase['all_users'] => array('10' => $vbphrase['yes'] . ' - ' . $vbphrase['invisible_mode'], '80' => $vbphrase['no'] . ' - ' . $vbphrase['invisible_mode'], '20' => $vbphrase['yes'] . ' - ' . $vbphrase['allow_vcard_download'], '90' => $vbphrase['no'] . ' - ' . $vbphrase['allow_vcard_download'], '30' => $vbphrase['yes'] . ' - ' . $vbphrase['receive_admin_emails'], '100' => $vbphrase['no'] . ' - ' . $vbphrase['receive_admin_emails'], '40' => $vbphrase['yes'] . ' - ' . $vbphrase['display_email'], '110' => $vbphrase['no'] . ' - ' . $vbphrase['display_email'], '50' => $vbphrase['yes'] . ' - ' . $vbphrase['receive_private_messages'], '120' => $vbphrase['no'] . ' - ' . $vbphrase['receive_private_messages'], '60' => $vbphrase['yes'] . ' - ' . $vbphrase['send_notification_email_when_a_private_message_is_received'], '130' => $vbphrase['no'] . ' - ' . $vbphrase['send_notification_email_when_a_private_message_is_received'], '70' => $vbphrase['yes'] . ' - ' . $vbphrase['pop_up_notification_box_when_a_private_message_is_received'], '140' => $vbphrase['no'] . ' - ' . $vbphrase['pop_up_notification_box_when_a_private_message_is_received'], '150' => $vbphrase['on'] . ' - ' . $vbphrase['display_signatures'], '180' => $vbphrase['off'] . ' - ' . $vbphrase['display_signatures'], '160' => $vbphrase['on'] . ' - ' . $vbphrase['display_avatars'], '190' => $vbphrase['off'] . ' - ' . $vbphrase['display_avatars'], '170' => $vbphrase['on'] . ' - ' . $vbphrase['display_images'], '200' => $vbphrase['off'] . ' - ' . $vbphrase['display_images'], '175' => $vbphrase['on'] . ' - ' . $vbphrase['display_reputation'], '205' => $vbphrase['off'] . ' - ' . $vbphrase['display_reputation'], '176' => $vbphrase['on'] . ' - ' . $vbphrase['enahnced_attachment_uploading'], '206' => $vbphrase['off'] . ' - ' . $vbphrase['enahnced_attachment_uploading'], 'blank1' => '', '210' => $vbphrase['subscribe_choice_none'], '220' => $vbphrase['subscribe_choice_0'], '230' => $vbphrase['subscribe_choice_1'], '240' => $vbphrase['subscribe_choice_2'], '250' => $vbphrase['subscribe_choice_3'], 'blank2' => '', '270' => $vbphrase['thread_display_mode'] . ' - ' . $vbphrase['linear'], '280' => $vbphrase['thread_display_mode'] . ' - ' . $vbphrase['threaded'], '290' => $vbphrase['thread_display_mode'] . ' - ' . $vbphrase['hybrid'], 'blank3' => '', '260' => $vbphrase['posts'] . ' - ' . $vbphrase['oldest_first'], '265' => $vbphrase['posts'] . ' - ' . $vbphrase['newest_first'], 'blank4' => '', '300' => $vbphrase['do_not_show_editor_toolbar'], '310' => $vbphrase['show_standard_editor_toolbar'], '320' => $vbphrase['show_enhanced_editor_toolbar']), $vbphrase['all_forums'] => array('400' => $vbphrase['show_threads_from_last_day'], '405' => $vbphrase['show_threads_from_last_week'], '410' => $vbphrase['show_threads_from_last_month'], '415' => $vbphrase['show_threads_from_last_year'], '420' => $vbphrase['show_all_threads']));
($hook = vBulletinHook::fetch_hook('admin_queries_auto_options')) ? eval($hook) : false;
// ##################### START DO QUERY #####################
if ($_POST['do'] == 'doquery') {
    require_once DIR . '/includes/functions_misc.php';
    $vbulletin->input->clean_array_gpc('p', array('autoquery' => TYPE_UINT, 'perpage' => TYPE_UINT, 'pagenumber' => TYPE_UINT, 'confirmquery' => TYPE_BOOL));
    $query =& $vbulletin->GPC['query'];
    if ($vbulletin->GPC['pagenumber'] < 1) {
        $vbulletin->GPC['pagenumber'] = 1;
    }
    if (!$vbulletin->GPC['perpage']) {
        $vbulletin->GPC['perpage'] = 20;
    }
    if (!$vbulletin->GPC['confirmquery']) {
        if (!$vbulletin->GPC['autoquery'] and !$query) {
            print_stop_message('please_complete_required_fields');
        }
        if ($vbulletin->GPC['autoquery']) {
            switch ($vbulletin->GPC['autoquery']) {
                case 10:
                    $query = "UPDATE " . TABLE_PREFIX . "user SET options = options + " . $vbulletin->bf_misc_useroptions['invisible'] . " WHERE NOT (options & " . $vbulletin->bf_misc_useroptions['invisible'] . ")";
                    break;
                case 20:
                    $query = "UPDATE " . TABLE_PREFIX . "user SET options = options + " . $vbulletin->bf_misc_useroptions['showvcard'] . " WHERE NOT (options & " . $vbulletin->bf_misc_useroptions['showvcard'] . ")";
                    break;
                case 30:
                    $query = "UPDATE " . TABLE_PREFIX . "user SET options = options + " . $vbulletin->bf_misc_useroptions['adminemail'] . " WHERE NOT (options & " . $vbulletin->bf_misc_useroptions['adminemail'] . ")";
                    break;
                case 40:
                    $query = "UPDATE " . TABLE_PREFIX . "user SET options = options + " . $vbulletin->bf_misc_useroptions['showemail'] . " WHERE NOT (options & " . $vbulletin->bf_misc_useroptions['showemail'] . ")";
                    break;
开发者ID:0hyeah,项目名称:yurivn,代码行数:31,代码来源:queries.php


示例7: xml_import_help_topics

function xml_import_help_topics($xml = false)
{
    global $vbulletin, $vbphrase;
    print_dots_start('<b>' . $vbphrase['importing_admin_help'] . "</b>, {$vbphrase['please_wait']}", ':', 'dspan');
    require_once DIR . '/includes/class_xml.php';
    $xmlobj = new vB_XML_Parser($xml, $GLOBALS['path']);
    if ($xmlobj->error_no == 1) {
        print_dots_stop();
        print_stop_message('no_xml_and_no_path');
    } else {
        if ($xmlobj->error_no == 2) {
            print_dots_stop();
            print_stop_message('please_ensure_x_file_is_located_at_y', 'vbulletin-adminhelp.xml', $GLOBALS['path']);
        }
    }
    if (!($arr = $xmlobj->parse())) {
        print_dots_stop();
        print_stop_message('xml_error_x_at_line_y', $xmlobj->error_string(), $xmlobj->error_line());
    }
    if (!$arr['helpscript']) {
        print_dots_stop();
        print_stop_message('invalid_file_specified');
    }
    $product = empty($arr['product']) ? 'vbulletin' : $arr['product'];
    $has_phrases = !empty($arr['hasphrases']);
    $arr = $arr['helpscript'];
    if ($product == 'vbulletin') {
        $product_sql = "product IN ('vbulletin', '')";
    } else {
        $product_sql = "product = '" . $vbulletin->db->escape_string($product) . "'";
    }
    $vbulletin->db->query_write("\n\t\tDELETE FROM " . TABLE_PREFIX . "adminhelp\n\t\tWHERE {$product_sql}\n\t\t\t AND volatile = 1\n\t");
    if ($has_phrases) {
        $vbulletin->db->query_write("\n\t\t\tDELETE FROM " . TABLE_PREFIX . "phrase\n\t\t\tWHERE {$product_sql}\n\t\t\t\tAND fieldname = 'cphelptext'\n\t\t\t\tAND languageid = -1\n\t\t");
    }
    // Deal with single entry
    if (!is_array($arr[0])) {
        $arr = array($arr);
    }
    foreach ($arr as $helpscript) {
        $help_sql = array();
        $phrase_sql = array();
        $help_sql_len = 0;
        $phrase_sql_len = 0;
        // Deal with single entry
        if (!is_array($helpscript['helptopic'][0])) {
            $helpscript['helptopic'] = array($helpscript['helptopic']);
        }
        foreach ($helpscript['helptopic'] as $topic) {
            $help_sql[] = "\n\t\t\t\t('" . $vbulletin->db->escape_string($helpscript['name']) . "',\n\t\t\t\t'" . $vbulletin->db->escape_string($topic['act']) . "',\n\t\t\t\t'" . $vbulletin->db->escape_string($topic['opt']) . "',\n\t\t\t\t" . intval($topic['disp']) . ",\n\t\t\t\t1,\n\t\t\t\t'" . $vbulletin->db->escape_string($product) . "')\n\t\t\t";
            $help_sql_len += strlen(end($help_sql));
            if ($has_phrases) {
                $phrase_name = fetch_help_phrase_short_name(array('script' => $helpscript['name'], 'action' => $topic['act'], 'optionname' => $topic['opt']));
                if (isset($topic['text']['value'])) {
                    $phrase_sql[] = "\n\t\t\t\t\t\t(-1,\n\t\t\t\t\t\t'cphelptext',\n\t\t\t\t\t\t'{$phrase_name}_text',\n\t\t\t\t\t\t'" . $vbulletin->db->escape_string($topic['text']['value']) . "',\n\t\t\t\t\t\t'" . $vbulletin->db->escape_string($product) . "',\n\t\t\t\t\t\t'" . $vbulletin->db->escape_string($topic['text']['username']) . "',\n\t\t\t\t\t\t" . intval($topic['text']['date']) . ",\n\t\t\t\t\t\t'" . $vbulletin->db->escape_string($topic['text']['version']) . "')\n\t\t\t\t\t";
                    $phrase_sql_len += strlen(end($phrase_sql));
                }
                if (isset($topic['title']['value'])) {
                    $phrase_sql[] = "\n\t\t\t\t\t\t(-1,\n\t\t\t\t\t\t'cphelptext',\n\t\t\t\t\t\t'{$phrase_name}_title',\n\t\t\t\t\t\t'" . $vbulletin->db->escape_string($topic['title']['value']) . "',\n\t\t\t\t\t\t'" . $vbulletin->db->escape_string($product) . "',\n\t\t\t\t\t\t'" . $vbulletin->db->escape_string($topic['title']['username']) . "',\n\t\t\t\t\t\t" . intval($topic['title']['date']) . ",\n\t\t\t\t\t\t'" . $vbulletin->db->escape_string($topic['title']['version']) . "')\n\t\t\t\t\t";
                    $phrase_sql_len += strlen(end($phrase_sql));
                }
            }
            if ($phrase_sql_len > 102400) {
                // insert max of 100k of phrases at a time
                /*insert query*/
                $vbulletin->db->query_write("\n\t\t\t\t\tREPLACE INTO " . TABLE_PREFIX . "phrase\n\t\t\t\t\t\t(languageid, fieldname, varname, text, product, username, dateline, version)\n\t\t\t\t\tVALUES\n\t\t\t\t\t\t" . implode(",\n", $phrase_sql));
                $phrase_sql = array();
                $phrase_sql_len = 0;
            }
            if ($help_sql_len > 102400) {
                // insert max of 100k of phrases at a time
                /*insert query*/
                $vbulletin->db->query_write("\n\t\t\t\t\tREPLACE INTO " . TABLE_PREFIX . "adminhelp\n\t\t\t\t\t\t(script, action, optionname, displayorder, volatile, product)\n\t\t\t\t\tVALUES\n\t\t\t\t\t\t" . implode(",\n\t", $help_sql));
                $help_sql = array();
                $help_sql_len = 0;
            }
        }
        if ($help_sql) {
            /*insert query*/
            $vbulletin->db->query_write("\n\t\t\t\tREPLACE INTO " . TABLE_PREFIX . "adminhelp\n\t\t\t\t\t(script, action, optionname, displayorder, volatile, product)\n\t\t\t\tVALUES\n\t\t\t\t\t" . implode(",\n\t", $help_sql));
        }
        if ($phrase_sql) {
            /*insert query*/
            $vbulletin->db->query_write("\n\t\t\t\t\tREPLACE INTO " . TABLE_PREFIX . "phrase\n\t\t\t\t\t\t(languageid, fieldname, varname, text, product, username, dateline, version)\n\t\t\t\t\tVALUES\n\t\t\t\t\t\t" . implode(",\n", $phrase_sql));
        }
    }
    // stop the 'dots' counter feedback
    print_dots_stop();
    require_once DIR . '/includes/adminfunctions_language.php';
    build_language();
}
开发者ID:0hyeah,项目名称:yurivn,代码行数:91,代码来源:adminfunctions_help.php


示例8: generate_style

/**
* Generates the style for the style generator
*
* @param	array 	contains all color data
* @param	int 	Number for the parent id
* @param	string	Title for the genrated style
* @param	boolean	Override version check
* @param	int		Display order for the style
* @param	boolean	True / False whether it will be user selectable
* @param	int		Version
*
*/

function generate_style($data, $parentid, $title, $anyversion=false, $displayorder, $userselect, $version)
{
	global $vbulletin;
	// Need to check variable for values - Check to make sure we have a name etc

	$arr = explode('{', stripslashes($data)); // checked below
	$hex = array(0 => ''); // start at one
	$match = $match2 = array(); // initialize
	$type = 'lps'; // checked below

	foreach ($arr AS $key => $value)
	{
		if (preg_match("/\"hex\":\"([0-9A-F]{6})\"/", $value, $match) == 1)
		{
			$hex[] = '#' . $match[1];
		}
		if (preg_match("/\"type\":\"([a-z0-9]{3})\"/", $value, $match2) == 1)
		{
			$type = $match2[1];
		}
	}

	switch (count($hex))
	{
		case '11':
			break;

		default:
			print_stop_message('incorrect_color_mapping');
	}

	if ($type == 'lps') // Color : Primary and Secondary (except S3 and S4)
	{
		$sample_file = "style_generator_sample_light.xml";
		$from = array('#FF0000', '#BF3030', '#A60000', '#FF4040', '#FF7373', '#009999', '#1D7373', '#5CCCCC');
		$to = array($hex[1], $hex[2], $hex[3], $hex[4], $hex[5], $hex[6], $hex[7], $hex[10]);
	}
	else if ($type == 'lpt') // White : Similar to the current style
	{
		$sample_file = "style_generator_sample_white.xml";
		$from = array('#A60000', '#BF3030', '#FF4040', '#FF7373');
		$to = array($hex[3], $hex[2], $hex[1], $hex[1]);
	}
	else if ($type == 'gry') // Grey :: Primary 3 and Primary 4 only
	{
		$sample_file = "style_generator_sample_gray.xml";
		$from = array('#A60000', '#FF4040');
		$to = array($hex[1], $hex[4]);
	}
	else if ($type == 'drk') // Dark : Primary 3 and Primary 4 only
	{
		$sample_file = "style_generator_sample_dark.xml";
		$from = array('#A60000', '#FF4040');
		$to = array($hex[1], $hex[4]);
	}
	else // Dark : Default to Dark
	{
		$sample_file = "style_generator_sample_dark.xml";
		$from = array('#A60000', '#FF4040');
		$to = array($hex[1], $hex[4]);
	}

	$style = file(DIR . '/includes/xml/' . $sample_file);

	$decode = $match = array();
	foreach($style AS $name => $value) // read in and decode the sample_*.xml file
	{
		if (preg_match("/name=\"(.*)\" value=\"(.*)\"/", $value, $match) == 1)
		{
			$decode[$match[1]] = base64_decode($match[2]);
		}
	}

	$match = array();
	$output = '';
	foreach ($decode AS $name => $value) // replace the RRGGBB in the sample_*.xml file with chosen colors and re-encode
	{
		if (preg_match("/\"(#[a-zA-Z0-9]{6})\"/", $value, $match) == 1)
		{
			$upper = '"' . strtoupper($match[1]) . '"';
			$value = base64_encode(str_replace($from, $to, preg_replace("/\"(#[a-zA-Z0-9]{6})\"/", $upper, $value)));
			$output .= '		<stylevar name="' . $name . '" value="' . $value . '" />
	';
		}
	}
	if($title===''){$title = 'Style ' . time();}
	$output = '<?xml version="1.0" encoding="ISO-8859-1"?>
//.........这里部分代码省略.........
开发者ID:hungnv0789,项目名称:vhtm,代码行数:101,代码来源:adminfunctions_template.php


示例9: array

}
// *************************************************************************************************
if ($_POST['do'] == 'killreputation') {
    $vbulletin->input->clean_array_gpc('p', array('reputationid' => TYPE_INT));
    $repinfo = verify_id('reputation', $vbulletin->GPC['reputationid'], 0, 1);
    $user = fetch_userinfo($repinfo['userid']);
    if ($user) {
        $userdm =& datamanager_init('User', $vbulletin, ERRTYPE_CP);
        $userdm->set_existing($user);
        $userdm->set('reputation', $user['reputation'] - $repinfo['reputation']);
        $userdm->save();
        unset($userdm);
    }
    $db->query_write("\n\t\tDELETE FROM " . TABLE_PREFIX . "reputation\n\t\tWHERE reputationid = " . $vbulletin->GPC['reputationid']);
    define('CP_REDIRECT', "adminreputation.php?do=list&amp;u={$repinfo['userid']}");
    print_stop_message('deleted_reputation_successfully');
}
// *************************************************************************************************
if ($_REQUEST['do'] == 'deletereputation') {
    $vbulletin->input->clean_array_gpc('r', array('reputationid' => TYPE_INT));
    print_delete_confirmation('reputation', $vbulletin->GPC['reputationid'], 'adminreputation', 'killreputation');
}
if ($_REQUEST['do'] == 'modify') {
    $reputationlevels = $db->query_read("\n\t\tSELECT *\n\t\tFROM " . TABLE_PREFIX . "reputationlevel\n\t\tORDER BY minimumreputation\n\t");
    print_form_header('adminreputation', 'updateminimums');
    print_table_header($vbphrase['user_reputation_manager'], 3);
    print_cells_row(array($vbphrase['reputation_level'], $vbphrase['minimum_reputation_level'], $vbphrase['controls']), 1);
    while ($reputationlevel = $db->fetch_array($reputationlevels)) {
        $reputationlevel['level'] = htmlspecialchars_uni($vbphrase['reputation' . $reputationlevel['reputationlevelid']]);
        $cell = array();
        $cell[] = "{$vbphrase['user']} <b>{$reputationlevel['level']}</b>";
开发者ID:0hyeah,项目名称:yurivn,代码行数:31,代码来源:adminreputation.php


示例10: print_stop_message

            print_stop_message('invalid_locale', $langupdate['locale']);
        }
        if ($langupdate['dateoverride'] == '' or $langupdate['timeoverride'] == '' or $langupdate['registereddateoverride'] == '' or $langupdate['calformat1override'] == '' or $langupdate['calformat2override'] == '' or $langupdate['logdateoverride'] == '') {
            print_stop_message('locale_define_fill_in_all_overrides');
        }
    }
    $query = fetch_query_sql($langupdate, 'language', "WHERE languageid = " . $vbulletin->GPC['dolanguageid']);
    $db->query_write($query);
    if ($vbulletin->GPC['isdefault'] and $vbulletin->GPC['dolanguageid'] != $vbulletin->options['languageid']) {
        $do = 'setdefault';
    } else {
        $do = 'modify';
    }
    build_language_datastore();
    define('CP_REDIRECT', 'language.php?dolanguageid=' . $vbulletin->GPC['dolanguageid'] . '&amp;do=' . $do);
    print_stop_message('saved_language_x_successfully', $newlang['title']);
}
// ##########################################################################
if ($_REQUEST['do'] == 'edit_settings') {
    $language = fetch_languages_array($vbulletin->GPC['dolanguageid']);
    $getoptions = convert_bits_to_array($language['options'], $vbulletin->bf_misc_languageoptions);
    $language = array_merge($language, $getoptions);
    print_form_header('language', 'update_settings');
    construct_hidden_code('dolanguageid', $vbulletin->GPC['dolanguageid']);
    print_table_header(construct_phrase($vbphrase['x_y_id_z'], $vbphrase['language'], $language['title'], $language['languageid']));
    print_description_row($vbphrase['general_settings'], 0, 2, 'thead');
    print_input_row($vbphrase['title'], 'title', $language['title'], 0);
    print_yes_no_row($vbphrase['allow_user_selection'], 'userselect', $language['userselect']);
    print_yes_no_row($vbphrase['is_default_language'], 'isdefault', iif($vbulletin->GPC['dolanguageid'] == $vbulletin->options['languageid'], 1, 0));
    print_yes_no_row($vbphrase['enable_directional_markup_fix'], 'options[dirmark]', $language['dirmark']);
    print_label_row($vbphrase['text_direction'], '<label for="rb_l2r"><input type="radio" name="options[direction]" id="rb_l2r" value="1" tabindex="1"' . iif($language['direction'], ' checked="checked"') . " />{$vbphrase['left_to_right']}</label><br />" . '
开发者ID:holandacz,项目名称:nb4,代码行数:31,代码来源:language.php


示例11: print_forum_chooser

    }
    print_forum_chooser($vbphrase['use_prefix_set_in_these_forums'], 'forumids[]', $enabled_forums, $vbphrase['none'], false, true);
    print_submit_row();
}
// ########################################################################
if ($_POST['do'] == 'displayorder') {
    $vbulletin->input->clean_array_gpc('p', array('prefixset_order' => TYPE_ARRAY_UINT, 'prefix_order' => TYPE_ARRAY_UINT));
    foreach ($vbulletin->GPC['prefixset_order'] as $prefixsetid => $displayorder) {
        $db->query_write("\r\n\t\t\tUPDATE " . TABLE_PREFIX . "prefixset SET\r\n\t\t\t\tdisplayorder =  " . intval($displayorder) . "\r\n\t\t\tWHERE prefixsetid = '" . $db->escape_string($prefixsetid) . "'\r\n\t\t");
    }
    foreach ($vbulletin->GPC['prefix_order'] as $prefixid => $displayorder) {
        $db->query_write("\r\n\t\t\tUPDATE " . TABLE_PREFIX . "prefix SET\r\n\t\t\t\tdisplayorder =  " . intval($displayorder) . "\r\n\t\t\tWHERE prefixid = '" . $db->escape_string($prefixid) . "'\r\n\t\t");
    }
    build_prefix_datastore();
    define('CP_REDIRECT', 'prefix.php?do=list');
    print_stop_message('saved_display_order_successfully');
}
// ########################################################################
if ($_REQUEST['do'] == 'list') {
    $prefixsets_sql = $db->query_read("\r\n\t\tSELECT *\r\n\t\tFROM " . TABLE_PREFIX . "prefixset\r\n\t\tORDER BY displayorder\r\n\t");
    $prefixsets = array();
    while ($prefixset = $db->fetch_array($prefixsets_sql)) {
        $prefixsets["{$prefixset['prefixsetid']}"] = $prefixset;
        $prefixsets["{$prefixset['prefixsetid']}"]['prefixes'] = array();
    }
    $prefixes_sql = $db->query_read("\r\n\t\tSELECT *\r\n\t\tFROM " . TABLE_PREFIX . "prefix\r\n\t\tORDER BY displayorder\r\n\t");
    while ($prefix = $db->fetch_array($prefixes_sql)) {
        if (isset($prefixsets["{$prefix['prefixsetid']}"])) {
            $prefixsets["{$prefix['prefixsetid']}"]['prefixes']["{$prefix['prefixid']}"] = $prefix;
        }
    }
开发者ID:Kheros,项目名称:MMOver,代码行数:31,代码来源:prefix.php


示例12: IN

    if (!empty($vbulletin->GPC['modaction'])) {
        $sqlconds[] = "action LIKE '%" . $db->escape_string_like($vbulletin->GPC['modaction']) . "%'";
    }
    if (!empty($vbulletin->GPC['userid'])) {
        $sqlconds[] = "userid = " . $vbulletin->GPC['userid'];
    }
    if ($vbulletin->GPC['product']) {
        if ($vbulletin->GPC['product'] == 'vbulletin') {
            $sqlconds[] = "product IN ('', 'vbulletin')";
        } else {
            $sqlconds[] = "product = '" . $db->escape_string($vbulletin->GPC['product']) . "'";
        }
    }
    $db->query_write("\n\t\tDELETE FROM " . TABLE_PREFIX . "moderatorlog\n\t\tWHERE " . (!empty($sqlconds) ? implode("\r\n\tAND ", $sqlconds) : "") . "\n\t");
    define('CP_REDIRECT', 'modlog.php?do=choose');
    print_stop_message('pruned_moderator_log_successfully');
}
// ###################### Start modify #######################
if ($_REQUEST['do'] == 'choose') {
    $users = $db->query_read("\n\t\tSELECT DISTINCT moderatorlog.userid, user.username\n\t\tFROM " . TABLE_PREFIX . "moderatorlog AS moderatorlog\n\t\tINNER JOIN " . TABLE_PREFIX . "user AS user USING(userid)\n\t\tORDER BY username\n\t");
    $userlist = array('no_value' => $vbphrase['all_log_entries']);
    while ($user = $db->fetch_array($users)) {
        $userlist["{$user['userid']}"] = $user['username'];
    }
    print_form_header('modlog', 'view');
    print_table_header($vbphrase['moderator_log_viewer']);
    print_input_row($vbphrase['log_entries_to_show_per_page'], 'perpage', 15);
    print_select_row($vbphrase['show_only_entries_generated_by'], 'userid', $userlist);
    print_time_row($vbphrase['start_date'], 'startdate', 0, 0);
    print_time_row($vbphrase['end_date'], 'enddate', 0, 0);
    if (count($products = fetch_product_list()) > 1) {
开发者ID:holandacz,项目名称:nb4,代码行数:31,代码来源:modlog.php


示例13: array

                                }
                            }
                            $userchange["{$fname}"] = $str ? $str : '-';
                        }
                        break;
                }
                // sometimes we need translate the fieldname to show the phrases (database field and phrase have different name)
                $fieldnametrans = array('usergroupid' => 'primary_usergroup', 'membergroupids' => 'additional_usergroups');
                if ($fieldnametrans["{$userchange['fieldname']}"]) {
                    $userchange['fieldname'] = $fieldnametrans["{$userchange['fieldname']}"];
                }
                // print the change
                $text = array();
                $text[] = $vbphrase["{$userchange['fieldname']}"];
                $text[] = $userchange['oldvalue'];
                $text[] = $userchange['newvalue'];
                print_cells_row($text, 0, false, -10);
            }
            print_table_footer();
        } else {
            print_stop_message('no_userchange_history');
        }
    }
}
print_cp_footer();
/*======================================================================*\
|| ####################################################################
|| # Downloaded: 22:41, Fri Oct 10th 2008
|| # CVS: $RCSfile$ - $Revision: 27484 $
|| ####################################################################
\*======================================================================*/
开发者ID:holandacz,项目名称:nb4,代码行数:31,代码来源:user.php


示例14: define

    define('CP_REDIRECT', 'usertitle.php?do=modify');
    print_stop_message('saved_user_title_x_successfully', $vbulletin->GPC['title']);
}
// ###################### Start Remove #######################
if ($_REQUEST['do'] == 'remove') {
    print_form_header('usertitle', 'kill');
    construct_hidden_code('usertitleid', $vbulletin->GPC['usertitleid']);
    print_table_header($vbphrase['confirm_deletion']);
    print_description_row($vbphrase['are_you_sure_you_want_to_delete_this_user_title']);
    print_submit_row($vbphrase['yes'], '', 2, $vbphrase['no']);
}
// ###################### Start Kill #######################
if ($_POST['do'] == 'kill') {
    $db->query_write("DELETE FROM " . TABLE_PREFIX . "usertitle WHERE usertitleid = " . $vbulletin->GPC['usertitleid']);
    define('CP_REDIRECT', 'usertitle.php?do=modify');
    print_stop_message('deleted_user_title_successfully');
}
// ###################### Start modify #######################
if ($_REQUEST['do'] == 'modify') {
    $usertitles = $db->query_read("\r\n\t\tSELECT usertitleid, title, minposts\r\n\t\tFROM " . TABLE_PREFIX . "usertitle\r\n\t\tORDER BY minposts\r\n\t");
    ?>
	<script type="text/javascript">
	function js_usergroup_jump(usertitleid, obj)
	{
		task = obj.options[obj.selectedIndex].value;
		switch (task)
		{
			case 'edit': window.location = "usertitle.php?<?php 
    echo $vbulletin->session->vars['sessionurl_js'];
    ?>
do=edit&usertitleid=" + usertitleid; break;
开发者ID:Kheros,项目名称:MMOver,代码行数:31,代码来源:usertitle.php


示例15: print_form_header

            print_form_header('usergroup', 'processjoinrequests');
            construct_hidden_code('usergroupid', $vbulletin->GPC['usergroupid']);
            print_table_header("{$usergroup['title']} - ({$vbphrase['join_requests']}: {$usergroup['joinrequests']})", 6);
            if (!empty($leaders)) {
                print_description_row("<span style=\"font-weight:normal\">(" . $vbphrase['usergroup_leader'] . ': ' . implode(', ', $leaders) . ')</span>', 0, 6, 'thead');
            }
            print_cells_row(array($vbphrase['username'], $vbphrase['reason'], '<span style="white-space:nowrap">' . $vbphrase['date'] . '</span>', '<input type="button" value="' . $vbphrase['accept'] . '" onclick="js_check_all_option(this.form, 1);" class="button" title="' . $vbphrase['check_all'] . '" />', '<input type="button" value=" ' . $vbphrase['deny'] . ' " onclick="js_check_all_option(this.form, 0);" class="button" title="' . $vbphrase['check_all'] . '" />', '<input type="button" value="' . $vbphrase['ignore'] . '" onclick="js_check_all_option(this.form, -1);" class="button" title="' . $vbphrase['check_all'] . '" />'), 1);
            $i = 0;
            while ($request = $db->fetch_array($requests)) {
                if ($i > 0 and $i % 10 == 0) {
                    print_description_row('<div align="center"><input type="submit" class="button" value="' . $vbphrase['process'] . '" accesskey="s" tabindex="1" /></div>', 0, 6, 'thead');
                }
                $i++;
                $cell = array("<a href=\"user.php?" . $vbulletin->session->vars['sessionurl'] . "do=edit&amp;u={$request['userid']}\"><b>{$request['username']}</b></a>", $request['reason'], '<span class="smallfont">' . vbdate($vbulletin->options['dateformat'], $request['dateline']) . '<br />' . vbdate($vbulletin->options['timeformat'], $request['dateline']) . '</span>', '<label for="a' . $request['usergrouprequestid'] . '" class="smallfont">' . $vbphrase['accept'] . '<input type="radio" name="request[' . $request['usergrouprequestid'] . ']" value="1" id="a' . $request['usergrouprequestid'] . '" tabindex="1" /></label>', '<label for="d' . $request['usergrouprequestid'] . '" class="smallfont">' . $vbphrase['deny'] . '<input type="radio" name="request[' . $request['usergrouprequestid'] . ']" value="0" id="d' . $request['usergrouprequestid'] . '" tabindex="1" /></label>', '<label for="i' . $request['usergrouprequestid'] . '" class="smallfont">' . $vbphrase['ignore'] . '<input type="radio" name="request[' . $request['usergrouprequestid'] . ']" value="-1" id="i' . $request['usergrouprequestid'] . '" tabindex="1" checked="checked" /></label>');
                print_cells_row($cell, 0, '', -5);
            }
            unset($request);
            $db->free_result($requests);
            print_submit_row($vbphrase['process'], $vbphrase['reset'], 6);
        } else {
            print_stop_message('no_join_requests_matched_your_query');
        }
    }
}
print_cp_footer();
/*======================================================================*\
|| ####################################################################
|| # Downloaded: 22:41, Fri Oct 10th 2008
|| # CVS: $RCSfile$ - $Revision: 27232 $
|| ####################################################################
\*======================================================================*/
开发者ID:holandacz,项目名称:nb4,代码行数:31,代码来源:usergroup.php


示例16: redirect

/**
 * Simple vB Redirection Function
 *
 * @param string $do
 * @param string $stopmessage
 * @param string $var
 */
function redirect($do, $stopmessage, $var = '')
{
    define('CP_REDIRECT', "ame.php?do={$do}");
    print_stop_message($stopmessage, $var);
}
开发者ID:rcdesign-cemetery,项目名称:vb-foreign_mod_fixes,代码行数:12,代码来源:ame.php


示例17: array

// #############################################################################
if (empty($_REQUEST['do'])) {
    $_REQUEST['do'] = 'modify';
}
// #############################################################################
if ($_POST['do'] == 'update') {
    $vbulletin->input->clean_array_gpc('p', array('cssprefs' => TYPE_STR, 'dismissednews' => TYPE_STR));
    foreach ($vbulletin->GPC['adminpermissions'] as $key => $value) {
        $admindm->set_bitfield('adminpermissions', $key, $value);
    }
    ($hook = vBulletinHook::fetch_hook('admin_permissions_process')) ? eval($hook) : false;
    $admindm->set('cssprefs', $vbulletin->GPC['cssprefs']);
    $admindm->set('dismissednews', $vbulletin->GPC['dismissednews']);
    $admindm->save();
    define('CP_REDIRECT', "adminpermissions.php?" . $vbulletin->session->vars['sessionurl'] . "#user{$user['userid']}");
    print_stop_message('saved_administrator_permissions_successfully');
}
// #############################################################################
if ($_REQUEST['do'] == 'edit') {
    echo "<p align=\"center\">{$vbphrase['give_admin_access_arbitrary_html']}</p>";
    print_form_header('adminpermissions', 'update');
    construct_hidden_code('userid', $vbulletin->GPC['userid']);
    construct_hidden_code('oldpermissions', $user['adminpermissions']);
    print_table_header(construct_phrase($vbphrase['x_y_id_z'], $vbphrase['administrator_permissions'], $user['username'], $user['userid']));
    print_label_row("{$vbphrase['administrator']}: <a href=\"user.php?" . $vbulletin->session->vars['sessionurl'] . "do=edit&amp;u=" . $vbulletin->GPC['userid'] . "\">{$user['username']}</a>", '<div align="' . $stylevar['right'] . '"><input type="button" class="button" value=" ' . $vbphrase['all_yes'] . ' " onclick="js_check_all_option(this.form, 1);" /> <input type="button" class="button" value=" ' . $vbphrase['all_no'] . ' " onclick="js_check_all_option(this.form, 0);" /></div>', 'thead');
    foreach (convert_bits_to_array($user['adminpermissions'], $ADMINPERMISSIONS) as $field => $value) {
        print_yes_no_row($permsphrase["{$field}"] == '' ? $vbphrase['n_a'] : $permsphrase["{$field}"], "adminpermissions[ 

鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP print_stop_message2函数代码示例发布时间:2022-05-15
下一篇:
PHP print_standard_redirect函数代码示例发布时间:2022-05-15
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap