Пример #1
0
}

if ($_REQUEST['do'] == 'list')
{
	$current_user = new vB_Legacy_CurrentUser();
	$vbulletin->input->clean_array_gpc('p', array(
		'search_type' => TYPE_UINT));

	if ($vbulletin->GPC_exists['search_type'])
	{
		vB_Search_Searchtools::getUiXml($vbulletin->GPC['search_type'],
			vB_Search_Searchtools::searchIntroFetchPrefs($current_user, $vbulletin->GPC['search_type']));
	}
	else
	{
		vB_Search_Searchtools::getUiXml(vB_Search_Core::TYPE_COMMON,
			vB_Search_Searchtools::searchIntroFetchPrefs($current_user, vB_Search_Core::TYPE_COMMON));
	}
}

if ($_POST['do'] == 'loadimageconfig')
{
	$vbulletin->input->clean_array_gpc('p', array(
		'attachmentid' => TYPE_UINT,
	));

	$xml = new vB_AJAX_XML_Builder($vbulletin, 'text/xml');
	$xml->add_group('settings');

		if ($attachment = $db->query_first("
			SELECT settings
			FROM " . TABLE_PREFIX . "attachment
Пример #2
0
        $templater->register('styles', $settings['styles']);
    }
    $html = $templater->render(false);
    $xml = new vB_AJAX_XML_Builder($vbulletin, 'text/xml');
    $xml->add_tag('html', $html);
    $xml->print_xml();
}
if ($_POST['do'] == 'list') {
    $current_user = new vB_Legacy_CurrentUser();
    $vbulletin->input->clean_array_gpc('p', array('search_type' => TYPE_UINT));
    if (isset($vbulletin->GPC['search_type'])) {
        $prefs = vB_Search_Searchtools::searchIntroFetchPrefs($current_user, $vbulletin->GPC['search_type']);
    } else {
        $prefs = vB_Search_Searchtools::searchIntroFetchPrefs($current_user, vB_Search_Core::TYPE_COMMON);
    }
    vB_Search_Searchtools::getUiXml($vbulletin->GPC['search_type'], $prefs);
}
if ($_POST['do'] == 'loadimageconfig') {
    $vbulletin->input->clean_array_gpc('p', array('attachmentid' => TYPE_UINT));
    $xml = new vB_AJAX_XML_Builder($vbulletin, 'text/xml');
    $xml->add_group('settings');
    if ($attachment = $db->query_first("\r\n\t\t\tSELECT settings\r\n\t\t\tFROM " . TABLE_PREFIX . "attachment\r\n\t\t\tWHERE attachmentid = " . $vbulletin->GPC['attachmentid'] . "\r\n\t\t")) {
        $settings = unserialize($attachment['settings']);
        foreach ($settings as $key => $value) {
            $xml->add_tag($key, $value);
        }
    }
    $xml->close_group('settings');
    $xml->print_xml();
}
if ($_POST['do'] == 'saveimageconfig') {