当前位置: 首页>>代码示例>>PHP>>正文


PHP titania::page_footer方法代码示例

本文整理汇总了PHP中titania::page_footer方法的典型用法代码示例。如果您正苦于以下问题:PHP titania::page_footer方法的具体用法?PHP titania::page_footer怎么用?PHP titania::page_footer使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在titania的用法示例。


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

示例1: act

 public function act($template_body, $parent_id = false, $parent_url = false, $post_type = false, $s_post_action = false)
 {
     $action = request_var('action', '');
     switch ($action) {
         case 'post':
             if ($parent_id === false || $parent_url == false || $post_type === false) {
                 throw new exception('Must send parent_id, parent_url, and new post type to allow posting new topics');
             }
             $this->post($parent_id, $parent_url, $post_type, $s_post_action === false ? titania_url::$current_page_url : $s_post_action);
             titania::page_footer(true, $template_body);
             break;
         case 'quote':
             $this->reply(request_var('t', 0), request_var('p', 0));
             titania::page_footer(true, $template_body);
             break;
         case 'reply':
             $this->reply(request_var('t', 0));
             titania::page_footer(true, $template_body);
             break;
         case 'edit':
             $this->edit(request_var('p', 0));
             titania::page_footer(true, $template_body);
             break;
         case 'quick_edit':
             $this->quick_edit(request_var('p', 0));
             titania::page_footer(true, $template_body);
             break;
         case 'delete':
         case 'undelete':
         case 'report':
             $this->{$action}(request_var('p', 0));
             break;
         case 'sticky_topic':
         case 'unsticky_topic':
             $this->toggle_sticky(request_var('t', 0));
             break;
         case 'lock_topic':
         case 'unlock_topic':
         case 'delete_topic':
         case 'undelete_topic':
             $this->{$action}(request_var('t', 0));
             break;
         case 'hard_delete_topic':
             $this->delete_topic(request_var('t', 0), true);
             break;
     }
 }
开发者ID:kairion,项目名称:customisation-db,代码行数:47,代码来源:posting.php

示例2: titania_msg_handler


//.........这里部分代码省略.........
                echo '<b>[phpBB Debug] PHP Notice</b>: in file <b>' . $errfile . '</b> on line <b>' . $errline . '</b>: <b>' . $msg_text . '</b><br />' . "\n";
                // echo '<br /><br />BACKTRACE<br />' . get_backtrace() . '<br />' . "\n";
            }
            return;
            break;
        case E_USER_ERROR:
            if (!empty(phpbb::$user) && !empty(phpbb::$user->lang)) {
                $msg_text = !empty(phpbb::$user->lang[$msg_text]) ? phpbb::$user->lang[$msg_text] : $msg_text;
                $msg_title = !isset($msg_title) ? phpbb::$user->lang['GENERAL_ERROR'] : (!empty(phpbb::$user->lang[$msg_title]) ? phpbb::$user->lang[$msg_title] : $msg_title);
                $l_return_index = sprintf(phpbb::$user->lang['RETURN_INDEX'], '<a href="' . titania::$absolute_path . '">', '</a>');
                $l_notify = '';
                if (!empty(phpbb::$config['board_contact'])) {
                    $l_notify = '<p>' . sprintf(phpbb::$user->lang['NOTIFY_ADMIN_EMAIL'], phpbb::$config['board_contact']) . '</p>';
                }
            } else {
                $msg_title = 'General Error';
                $l_return_index = '<a href="' . titania::$absolute_path . '">Return to index page</a>';
                $l_notify = '';
                if (!empty(phpbb::$config['board_contact'])) {
                    $l_notify = '<p>Please notify the board administrator or webmaster: <a href="mailto:' . phpbb::$config['board_contact'] . '">' . phpbb::$config['board_contact'] . '</a></p>';
                }
            }
            garbage_collection();
            // Try to not call the adm page data...
            echo '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">';
            echo '<html xmlns="http://www.w3.org/1999/xhtml" dir="ltr">';
            echo '<head>';
            echo '<meta http-equiv="content-type" content="text/html; charset=utf-8" />';
            echo '<title>' . $msg_title . '</title>';
            echo '<style type="text/css">' . "\n" . '/* <![CDATA[ */' . "\n";
            echo '* { margin: 0; padding: 0; } html { font-size: 100%; height: 100%; margin-bottom: 1px; background-color: #E4EDF0; } body { font-family: "Lucida Grande", Verdana, Helvetica, Arial, sans-serif; color: #536482; background: #E4EDF0; font-size: 62.5%; margin: 0; } ';
            echo 'a:link, a:active, a:visited { color: #006699; text-decoration: none; } a:hover { color: #DD6900; text-decoration: underline; } ';
            echo '#wrap { padding: 0 20px 15px 20px; min-width: 615px; } #page-header { text-align: right; height: 40px; } #page-footer { clear: both; font-size: 1em; text-align: center; } ';
            echo '.panel { margin: 4px 0; background-color: #FFFFFF; border: solid 1px  #A9B8C2; } ';
            echo '#errorpage #page-header a { font-weight: bold; line-height: 6em; } #errorpage #content { padding: 10px; } #errorpage #content h1 { line-height: 1.2em; margin-bottom: 0; color: #DF075C; } ';
            echo '#errorpage #content div { margin-top: 20px; margin-bottom: 5px; border-bottom: 1px solid #CCCCCC; padding-bottom: 5px; color: #333333; font: bold 1.2em "Lucida Grande", Arial, Helvetica, sans-serif; text-decoration: none; line-height: 120%; text-align: left; } ';
            echo "\n" . '/* ]]> */' . "\n";
            echo '</style>';
            echo '</head>';
            echo '<body id="errorpage">';
            echo '<div id="wrap">';
            echo '	<div id="page-header">';
            echo '		' . $l_return_index;
            echo '	</div>';
            echo '	<div id="acp">';
            echo '	<div class="panel">';
            echo '		<div id="content">';
            echo '			<h1>' . $msg_title . '</h1>';
            echo '			<div>' . $msg_text . '</div>';
            echo '			<div>' . get_backtrace() . '</div>';
            echo $l_notify;
            echo '		</div>';
            echo '	</div>';
            echo '	</div>';
            echo '	<div id="page-footer">';
            echo '		Powered by phpBB &copy; 2000, 2002, 2005, 2007 <a href="http://www.phpbb.com/">phpBB Group</a>';
            echo '	</div>';
            echo '</div>';
            echo '</body>';
            echo '</html>';
            exit_handler();
            // On a fatal error (and E_USER_ERROR *is* fatal) we never want other scripts to continue and force an exit here.
            exit;
            break;
        case E_USER_WARNING:
        case E_USER_NOTICE:
            define('IN_ERROR_HANDLER', true);
            if (empty(phpbb::$user->data)) {
                phpbb::$user->session_begin();
            }
            // We re-init the auth array to get correct results on login/logout
            phpbb::$auth->acl(phpbb::$user->data);
            if (empty(phpbb::$user->lang)) {
                phpbb::$user->setup();
            }
            $msg_text = !empty(phpbb::$user->lang[$msg_text]) ? phpbb::$user->lang[$msg_text] : $msg_text;
            $msg_title = !isset($msg_title) ? phpbb::$user->lang['INFORMATION'] : (!empty(phpbb::$user->lang[$msg_title]) ? phpbb::$user->lang[$msg_title] : $msg_title);
            if (!defined('HEADER_INC')) {
                if (defined('IN_ADMIN') && isset(phpbb::$user->data['session_admin']) && phpbb::$user->data['session_admin']) {
                    adm_page_header($msg_title);
                } else {
                    titania::page_header($msg_title);
                }
            }
            phpbb::$template->set_filenames(array('body' => 'common/message_body.html'));
            phpbb::$template->assign_vars(array('MESSAGE_TITLE' => $msg_title, 'MESSAGE_TEXT' => $msg_text . titania_backtrace(), 'S_USER_WARNING' => $errno == E_USER_WARNING ? true : false, 'S_USER_NOTICE' => $errno == E_USER_NOTICE ? true : false));
            // We do not want the cron script to be called on error messages
            define('IN_CRON', true);
            if (defined('IN_ADMIN') && isset(phpbb::$user->data['session_admin']) && phpbb::$user->data['session_admin']) {
                adm_page_footer();
            } else {
                titania::page_footer(false);
            }
            exit_handler();
            break;
    }
    // If we notice an error not handled here we pass this back to PHP by returning false
    // This may not work for all php versions
    return false;
}
开发者ID:kairion,项目名称:customisation-db,代码行数:101,代码来源:functions.php

示例3: substr

				$url_params = substr($url_base, (strrpos($url_base, '/') + 1));
				$url_base = substr($url_base, 0, (strrpos($url_base, '/') + 1));
			}

			phpbb::$template->assign_block_vars('searchresults', array(
				'TOPIC_TITLE'		=> censor_text($document->title),

				'TOPIC_AUTHOR_FULL'	=> users_overlord::get_user($document->author, '_full'),
				'FIRST_POST_TIME'	=> phpbb::$user->format_date($document->date),

				'U_VIEW_TOPIC'		=> titania_url::build_url($url_base, $url_params),

				'S_TOPIC_REPORTED'		=> ($document->reported) ? true : false,
				//'S_TOPIC_UNAPPROVED'	=> (!$document->approved) ? true : false,
			));
		}
	break;

	default : */
foreach ($results['documents'] as $document) {
    $url_base = $url_params = '';
    titania_url::split_base_params($url_base, $url_params, $document->url);
    phpbb::$template->assign_block_vars('searchresults', array('POST_SUBJECT' => censor_text($document->title), 'MESSAGE' => titania_generate_text_for_display($document->text, $document->text_uid, $document->text_bitfield, $document->text_options), 'POST_AUTHOR_FULL' => $document->author ? users_overlord::get_user($document->author, '_full') : false, 'POST_DATE' => $document->date ? phpbb::$user->format_date($document->date) : false, 'U_VIEW_POST' => titania_url::build_url($url_base, $url_params), 'S_POST_REPORTED' => $document->reported ? true : false));
}
/*	break;
}*/
$sort->build_pagination(titania_url::$current_page, titania_url::$params);
titania::page_header('SEARCH');
phpbb::$template->assign_vars(array('SEARCH_WORDS' => $keywords, 'SEARCH_MATCHES' => $sort->total == 1 ? sprintf(phpbb::$user->lang['FOUND_SEARCH_MATCH'], $sort->total) : sprintf(phpbb::$user->lang['FOUND_SEARCH_MATCHES'], $sort->total), 'U_SEARCH_WORDS' => titania_url::build_url(titania_url::$current_page, titania_url::$params), 'U_SEARCH' => titania_url::build_url($mode == 'find-contribution' ? 'find-contribution' : 'search'), 'S_IN_SEARCH' => true, 'S_SEARCH_ACTION' => titania_url::$current_page_url));
titania::page_footer(true, 'search_results.html');
开发者ID:kairion,项目名称:customisation-db,代码行数:30,代码来源:search.php

示例4: login_box


//.........这里部分代码省略.........
     }
     if (isset($_POST['login'])) {
         // Get credential
         if ($admin) {
             $credential = request_var('credential', '');
             if (strspn($credential, 'abcdef0123456789') !== strlen($credential) || strlen($credential) != 32) {
                 if (self::$user->data['is_registered']) {
                     add_log('admin', 'LOG_ADMIN_AUTH_FAIL');
                 }
                 trigger_error('NO_AUTH_ADMIN');
             }
             $password = request_var('password_' . $credential, '', true);
         } else {
             $password = request_var('password', '', true);
         }
         $username = request_var('username', '', true);
         $autologin = !empty($_POST['autologin']) ? true : false;
         $viewonline = !empty($_POST['viewonline']) ? 0 : 1;
         $admin = $admin ? 1 : 0;
         $viewonline = $admin ? self::$user->data['session_viewonline'] : $viewonline;
         // Check if the supplied username is equal to the one stored within the database if re-authenticating
         if ($admin && utf8_clean_string(self::$username) != utf8_clean_string(self::$user->data['username'])) {
             // We log the attempt to use a different username...
             add_log('admin', 'LOG_ADMIN_AUTH_FAIL');
             trigger_error('NO_AUTH_ADMIN_USER_DIFFER');
         }
         // If authentication is successful we redirect user to previous page
         $result = self::$auth->login($username, $password, $autologin, $viewonline, $admin);
         // If admin authentication and login, we will log if it was a success or not...
         // We also break the operation on the first non-success login - it could be argued that the user already knows
         if ($admin) {
             if ($result['status'] == LOGIN_SUCCESS) {
                 add_log('admin', 'LOG_ADMIN_AUTH_SUCCESS');
             } else {
                 // Only log the failed attempt if a real user tried to.
                 // anonymous/inactive users are never able to go to the ACP even if they have the relevant permissions
                 if (self::$user->data['is_registered']) {
                     add_log('admin', 'LOG_ADMIN_AUTH_FAIL');
                 }
             }
         }
         // The result parameter is always an array, holding the relevant information...
         if ($result['status'] == LOGIN_SUCCESS) {
             $redirect = request_var('redirect', '');
             if ($redirect) {
                 $redirect = titania_url::unbuild_url($redirect);
                 $base = $append = false;
                 titania_url::split_base_params($base, $append, $redirect);
                 redirect(titania_url::build_url($base, $append));
             } else {
                 redirect(titania_url::build_url(titania_url::$current_page, titania_url::$params));
             }
         }
         // Something failed, determine what...
         if ($result['status'] == LOGIN_BREAK) {
             trigger_error($result['error_msg']);
         }
         // Special cases... determine
         switch ($result['status']) {
             case LOGIN_ERROR_ATTEMPTS:
                 $captcha = phpbb_captcha_factory::get_instance(self::$config['captcha_plugin']);
                 $captcha->init(CONFIRM_LOGIN);
                 // $captcha->reset();
                 // Parse the captcha template
                 self::reset_template();
                 self::$template->set_filenames(array('captcha' => $captcha->get_template()));
                 // Correct confirm image link
                 self::$template->assign_var('CONFIRM_IMAGE_LINK', self::append_sid('ucp', 'mode=confirm&amp;confirm_id=' . $captcha->confirm_id . '&amp;type=' . $captcha->type));
                 self::$template->assign_display('captcha', 'CAPTCHA', false);
                 titania::set_custom_template();
                 $err = self::$user->lang[$result['error_msg']];
                 break;
             case LOGIN_ERROR_PASSWORD_CONVERT:
                 $err = sprintf(self::$user->lang[$result['error_msg']], self::$config['email_enable'] ? '<a href="' . self::append_sid('ucp', 'mode=sendpassword') . '">' : '', self::$config['email_enable'] ? '</a>' : '', self::$config['board_contact'] ? '<a href="mailto:' . htmlspecialchars(self::$config['board_contact']) . '">' : '', self::$config['board_contact'] ? '</a>' : '');
                 break;
                 // Username, password, etc...
             // Username, password, etc...
             default:
                 $err = self::$user->lang[$result['error_msg']];
                 // Assign admin contact to some error messages
                 if ($result['error_msg'] == 'LOGIN_ERROR_USERNAME' || $result['error_msg'] == 'LOGIN_ERROR_PASSWORD') {
                     $err = !self::$config['board_contact'] ? sprintf(self::$user->lang[$result['error_msg']], '', '') : sprintf(self::$user->lang[$result['error_msg']], '<a href="mailto:' . htmlspecialchars(self::$config['board_contact']) . '">', '</a>');
                 }
                 break;
         }
     }
     // Assign credential for username/password pair
     $credential = $admin ? md5(unique_id()) : false;
     $s_hidden_fields = array('sid' => self::$user->session_id);
     if ($redirect) {
         $s_hidden_fields['redirect'] = $redirect;
     }
     if ($admin) {
         $s_hidden_fields['credential'] = $credential;
     }
     $s_hidden_fields = build_hidden_fields($s_hidden_fields);
     titania::page_header('LOGIN');
     self::$template->assign_vars(array('LOGIN_ERROR' => $err, 'LOGIN_EXPLAIN' => $l_explain, 'U_SEND_PASSWORD' => self::$config['email_enable'] ? self::append_sid('ucp', 'mode=sendpassword') : '', 'U_RESEND_ACTIVATION' => self::$config['require_activation'] == USER_ACTIVATION_SELF && self::$config['email_enable'] ? self::append_sid('ucp', 'mode=resend_act') : '', 'U_TERMS_USE' => self::append_sid('ucp', 'mode=terms'), 'U_PRIVACY' => self::append_sid('ucp', 'mode=privacy'), 'S_DISPLAY_FULL_LOGIN' => $s_display ? true : false, 'S_HIDDEN_FIELDS' => $s_hidden_fields, 'S_ADMIN_AUTH' => $admin, 'USERNAME' => $admin ? self::$user->data['username'] : '', 'USERNAME_CREDENTIAL' => 'username', 'PASSWORD_CREDENTIAL' => $admin ? 'password_' . $credential : 'password'));
     titania::page_footer(true, 'login_body.html');
 }
开发者ID:kairion,项目名称:customisation-db,代码行数:101,代码来源:phpbb.php

示例5: define

if (!defined('PHP_EXT')) {
    define('PHP_EXT', substr(strrchr(__FILE__, '.'), 1));
}
require TITANIA_ROOT . 'common.' . PHP_EXT;
titania::add_lang('faq', false, true);
/**
* From phpBB faq.php
*/
// Pull the array data from the lang pack
$switch_column = $found_switch = false;
$help_blocks = array();
foreach (phpbb::$user->help as $help_ary) {
    if ($help_ary[0] == '--') {
        if ($help_ary[1] == '--') {
            $switch_column = true;
            $found_switch = true;
            continue;
        }
        phpbb::$template->assign_block_vars('faq_block', array('BLOCK_TITLE' => $help_ary[1], 'SWITCH_COLUMN' => $switch_column));
        if ($switch_column) {
            $switch_column = false;
        }
        continue;
    }
    phpbb::$template->assign_block_vars('faq_block.faq_row', array('FAQ_QUESTION' => $help_ary[0], 'FAQ_ANSWER' => $help_ary[1]));
}
// Lets build a page ...
phpbb::$template->assign_vars(array('L_FAQ_TITLE' => phpbb::$user->lang['FAQ_EXPLAIN'], 'L_BACK_TO_TOP' => phpbb::$user->lang['BACK_TO_TOP'], 'SWITCH_COLUMN_MANUALLY' => !$found_switch ? true : false));
titania::page_header('FAQ_EXPLAIN');
titania::page_footer(true, 'faq_body.html');
开发者ID:kairion,项目名称:customisation-db,代码行数:30,代码来源:faq.php

示例6: foreach

                $queue->move($new_tag);
            } else {
                // Generate the list of tags we can move it to
                $extra = '<select name="id">';
                foreach ($tags as $tag_id => $row) {
                    $extra .= '<option value="' . $tag_id . '">' . (isset(phpbb::$user->lang[$row['tag_field_name']]) ? phpbb::$user->lang[$row['tag_field_name']] : $row['tag_field_name']) . '</option>';
                }
                $extra .= '</select>';
                phpbb::$template->assign_var('CONFIRM_EXTRA', $extra);
                titania::confirm_box(false, 'MOVE_QUEUE');
            }
            redirect(titania_url::append_url($base_url, array('q' => $queue->queue_id)));
            break;
    }
    // Display the main queue item
    $data = queue_overlord::display_queue_item($queue_id);
    // Handle replying/editing/etc
    $posting_helper = new titania_posting();
    $posting_helper->act('manage/queue_post.html');
    // Display the posts in the queue (after the posting helper acts)
    posts_overlord::display_topic_complete($data['topic']);
    titania::page_header(queue_overlord::$queue[$queue_id]['topic_subject']);
} else {
    // Subscriptions
    titania_subscriptions::handle_subscriptions(TITANIA_QUEUE, $queue_type, titania_url::$current_page_url);
    queue_overlord::display_queue($queue_type, $tag);
    queue_overlord::display_categories($queue_type, $tag);
    titania::page_header('VALIDATION_QUEUE');
}
titania::page_footer(true, 'manage/queue.html');
开发者ID:Noxwizard,项目名称:customisation-db,代码行数:30,代码来源:queue.php

示例7:

<?php

/**
 *
 * @package titania
 * @version $Id$
 * @copyright (c) 2008 phpBB Customisation Database Team
 * @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
 *
 */
/**
* @ignore
*/
if (!defined('IN_TITANIA')) {
    exit;
}
// Setup the sort tool to sort by contribution name ascending
$sort = contribs_overlord::build_sort();
$sort->set_url(titania::$author->get_url('contributions'));
$sort->set_defaults(false, 'c', 'a');
contribs_overlord::display_contribs('author', titania::$author->user_id, $sort);
phpbb::$template->assign_vars(array('S_AUTHOR_LIST' => true, 'U_CANONICAL' => $sort->build_canonical()));
titania::page_header(titania::$author->get_username_string('username') . ' - ' . phpbb::$user->lang['AUTHOR_CONTRIBS']);
titania::page_footer(true, 'authors/author_contributions.html');
开发者ID:Gfksx,项目名称:customisation-db,代码行数:24,代码来源:contributions.php

示例8: array

if ($topic_id) {
    // Subscriptions
    titania_subscriptions::handle_subscriptions(TITANIA_TOPIC, $topic_id, $topic->get_url());
    // Check access level
    if ($topic->topic_access < titania::$access_level || $topic->topic_type == TITANIA_QUEUE_DISCUSSION && !titania::$contrib->is_author && !titania::$contrib->is_active_coauthor && !titania_types::$types[titania::$contrib->contrib_type]->acl_get('queue_discussion')) {
        titania::needs_auth();
    }
    posts_overlord::display_topic_complete($topic);
    titania::page_header(censor_text($topic->topic_subject) . ' - ' . titania::$contrib->contrib_name);
    if (phpbb::$auth->acl_get('u_titania_post')) {
        phpbb::$template->assign_var('U_POST_REPLY', titania_url::append_url($topic->get_url(), array('action' => 'reply')));
    }
    // Canonical URL
    phpbb::$template->assign_var('U_CANONICAL', $topic->get_url());
} else {
    // Subscriptions
    titania_subscriptions::handle_subscriptions(TITANIA_SUPPORT, titania::$contrib->contrib_id, titania::$contrib->get_url('support'));
    // Mark all topics read
    if (request_var('mark', '') == 'topics') {
        titania_tracking::track(TITANIA_SUPPORT, titania::$contrib->contrib_id);
    }
    $data = topics_overlord::display_forums_complete('support', titania::$contrib);
    titania::page_header(titania::$contrib->contrib_name . ' - ' . phpbb::$user->lang['CONTRIB_SUPPORT']);
    if (phpbb::$auth->acl_get('u_titania_topic') && titania::$config->support_in_titania) {
        phpbb::$template->assign_var('U_POST_TOPIC', titania_url::append_url(titania::$contrib->get_url('support'), array('action' => 'post')));
    }
    $data['sort']->set_url(titania::$contrib->get_url('support'));
    phpbb::$template->assign_vars(array('U_MARK_TOPICS' => titania_url::append_url(titania::$contrib->get_url('support'), array('mark' => 'topics')), 'U_CANONICAL' => $data['sort']->build_canonical(), 'S_DISPLAY_SEARCHBOX' => true, 'S_SEARCHBOX_ACTION' => titania_url::build_url('search', array('type' => TITANIA_SUPPORT, 'contrib' => titania::$contrib->contrib_id))));
}
titania::page_footer(true, 'contributions/contribution_support.html');
开发者ID:Gfksx,项目名称:customisation-db,代码行数:30,代码来源:support.php

示例9: utf8_normalize_nfc

    }
    titania::add_lang('posting');
    phpbb::$user->add_lang('mcp');
    if (titania::confirm_box(true)) {
        $message = utf8_normalize_nfc(request_var('report_text', '', true));
        titania::$contrib->report($message);
        // Notifications
        redirect(titania::$contrib->get_url());
    } else {
        //phpbb::$template->assign_var('S_CAN_NOTIFY', ((phpbb::$user->data['is_registered']) ? true : false));
        titania::confirm_box(false, 'REPORT_CONTRIBUTION', '', array(), 'posting/report_body.html');
    }
    redirect(titania::$contrib->get_url());
}
titania::$contrib->get_download();
titania::$contrib->get_revisions();
titania::$contrib->get_screenshots();
titania::$contrib->get_rating();
titania::$contrib->assign_details();
if (!phpbb::$user->data['is_bot']) {
    titania::$contrib->increase_view_counter();
}
// Set tracking
titania_tracking::track(TITANIA_CONTRIB, titania::$contrib->contrib_id);
// Subscriptions
titania_subscriptions::handle_subscriptions(TITANIA_CONTRIB, titania::$contrib->contrib_id, titania::$contrib->get_url());
// Canonical URL
phpbb::$template->assign_var('U_CANONICAL', titania::$contrib->get_url());
titania::page_header(titania::$contrib->contrib_name . ' - ' . phpbb::$user->lang['CONTRIB_DETAILS']);
titania::page_footer(true, 'contributions/contribution_details.html');
开发者ID:kairion,项目名称:customisation-db,代码行数:30,代码来源:details.php

示例10:

<?php

/**
 *
 * @package titania
 * @version $Id$
 * @copyright (c) 2008 phpBB Customisation Database Team
 * @license http://opensource.org/licenses/gpl-license.php GNU Public License
 *
 */
/**
* @ignore
*/
if (!defined('IN_TITANIA')) {
    exit;
}
titania::$author->get_rating();
titania::$author->assign_details();
// Canonical URL
phpbb::$template->assign_var('U_CANONICAL', titania::$author->get_url());
titania::page_header(titania::$author->get_username_string('username') . ' - ' . phpbb::$user->lang['AUTHOR_DETAILS']);
titania::page_footer(true, 'authors/author_details.html');
开发者ID:kairion,项目名称:customisation-db,代码行数:22,代码来源:details.php

示例11: foreach

            // Parents
            foreach (array_reverse(titania::$cache->get_category_parents($category_id)) as $row) {
                $category_object->__set_array($categories_ary[$row['category_id']]);
                titania::generate_breadcrumbs(array(isset(phpbb::$user->lang[$categories_ary[$row['category_id']]['category_name']]) ? phpbb::$user->lang[$categories_ary[$row['category_id']]['category_name']] : $categories_ary[$row['category_id']]['category_name'] => titania_url::build_url('manage/categories', array('c' => $row['category_id']))));
            }
            // Self
            $category_object->__set_array($categories_ary[$category_id]);
            titania::generate_breadcrumbs(array(isset(phpbb::$user->lang[$categories_ary[$category_id]['category_name']]) ? phpbb::$user->lang[$categories_ary[$category_id]['category_name']] : $categories_ary[$category_id]['category_name'] => titania_url::build_url('manage/categories', array('c' => $category_id))));
            // Second set of breadcrumbs for category navigation
            // Parents
            foreach (array_reverse(titania::$cache->get_category_parents($category_id)) as $row) {
                $category_object->__set_array($categories_ary[$row['category_id']]);
                titania::generate_breadcrumbs(array(isset(phpbb::$user->lang[$categories_ary[$row['category_id']]['category_name']]) ? phpbb::$user->lang[$categories_ary[$row['category_id']]['category_name']] : $categories_ary[$row['category_id']]['category_name'] => titania_url::build_url('manage/categories', array('c' => $row['category_id']))), $block = 'nav_categories');
            }
            // Self
            $category_object->__set_array($categories_ary[$category_id]);
            titania::generate_breadcrumbs(array(isset(phpbb::$user->lang[$categories_ary[$category_id]['category_name']]) ? phpbb::$user->lang[$categories_ary[$category_id]['category_name']] : $categories_ary[$category_id]['category_name'] => titania_url::build_url('manage/categories', array('c' => $category_id))), $block = 'nav_categories');
            unset($categories_ary, $category_object);
        }
        phpbb::$template->assign_vars(array('ICON_MOVE_UP' => '<img src="' . titania::$images_path . 'icon_up.gif" alt="' . phpbb::$user->lang['MOVE_UP'] . '" title="' . phpbb::$user->lang['MOVE_UP'] . '" />', 'ICON_MOVE_UP_DISABLED' => '<img src="' . titania::$images_path . 'icon_up_disabled.gif" alt="' . phpbb::$user->lang['MOVE_UP'] . '" title="' . phpbb::$user->lang['MOVE_UP'] . '" />', 'ICON_MOVE_DOWN' => '<img src="' . titania::$images_path . 'icon_down.gif" alt="' . phpbb::$user->lang['MOVE_DOWN'] . '" title="' . phpbb::$user->lang['MOVE_DOWN'] . '" />', 'ICON_MOVE_DOWN_DISABLED' => '<img src="' . titania::$images_path . 'icon_down_disabled.gif" alt="' . phpbb::$user->lang['MOVE_DOWN'] . '" title="' . phpbb::$user->lang['MOVE_DOWN'] . '" />', 'ICON_EDIT' => '<img src="' . titania::$images_path . 'icon_edit.gif" alt="' . phpbb::$user->lang['EDIT'] . '" title="' . phpbb::$user->lang['EDIT'] . '" />', 'ICON_EDIT_DISABLED' => '<img src="' . titania::$images_path . 'icon_edit_disabled.gif" alt="' . phpbb::$user->lang['EDIT'] . '" title="' . phpbb::$user->lang['EDIT'] . '" />', 'ICON_DELETE' => '<img src="' . titania::$images_path . 'icon_delete.gif" alt="' . phpbb::$user->lang['DELETE'] . '" title="' . phpbb::$user->lang['DELETE'] . '" />', 'ICON_DELETE_DISABLED' => '<img src="' . titania::$images_path . 'icon_delete_disabled.gif" alt="' . phpbb::$user->lang['DELETE'] . '" title="' . phpbb::$user->lang['DELETE'] . '" />', 'SECTION_NAME' => '<a href="' . titania_url::build_url('manage/categories') . '">' . phpbb::$user->lang['MANAGE_CATEGORIES'] . '</a>', 'U_CREATE_CATEGORY' => titania_url::build_url('manage/categories', array('c' => $category_id, 'action' => 'add')), 'U_MANAGE_CATEGORIES' => titania_url::build_url('manage/categories'), 'S_MANAGE' => true));
        break;
}
function trigger_back($message)
{
    $message = isset(phpbb::$user->lang[$message]) ? phpbb::$user->lang[$message] : $message;
    $message .= '<br /><br /><a href="' . titania_url::build_url('manage/categories') . '">' . phpbb::$user->lang['BACK'] . '</a>';
    trigger_error($message);
}
titania::page_header('MANAGE_CATEGORIES');
titania::page_footer(true, 'manage/categories.html');
开发者ID:Gfksx,项目名称:customisation-db,代码行数:30,代码来源:categories.php

示例12: array

            $sql_ary = array('SELECT' => 'f.*', 'FROM' => array(TITANIA_CONTRIB_FAQ_TABLE => 'f'), 'WHERE' => 'f.contrib_id = ' . titania::$contrib->contrib_id . '
						AND f.faq_access >= ' . titania::$access_level, 'ORDER_BY' => 'f.left_id ASC');
            // Main SQL Query
            $sql = phpbb::$db->sql_build_query('SELECT', $sql_ary);
            // Handle pagination
            if ($sort->sql_count($sql_ary, 'faq_id')) {
                $sort->build_pagination($faq->get_url());
                // Get the data
                $result = phpbb::$db->sql_query_limit($sql, $sort->limit, $sort->start);
                while ($row = phpbb::$db->sql_fetchrow($result)) {
                    $faqs[$row['faq_id']] = $row;
                }
                phpbb::$db->sql_freeresult($result);
                // Grab the tracking info
                titania_tracking::get_tracks(TITANIA_FAQ, array_keys($faqs));
            }
            // Output
            foreach ($faqs as $id => $row) {
                // @todo probably should setup an edit time or something for better read tracking in case it was edited
                $folder_img = $folder_alt = '';
                $unread = titania_tracking::get_track(TITANIA_FAQ, $id, true) === 0 ? true : false;
                titania_topic_folder_img($folder_img, $folder_alt, 0, $unread);
                phpbb::$template->assign_block_vars('faqlist', array('U_FAQ' => $faq->get_url('', $row['faq_id']), 'SUBJECT' => $row['faq_subject'], 'VIEWS' => $row['faq_views'], 'FOLDER_IMG' => phpbb::$user->img($folder_img, $folder_alt), 'FOLDER_IMG_SRC' => phpbb::$user->img($folder_img, $folder_alt, false, '', 'src'), 'FOLDER_IMG_ALT' => phpbb::$user->lang[$folder_alt], 'FOLDER_IMG_ALT' => phpbb::$user->lang[$folder_alt], 'FOLDER_IMG_WIDTH' => phpbb::$user->img($folder_img, '', false, '', 'width'), 'FOLDER_IMG_HEIGHT' => phpbb::$user->img($folder_img, '', false, '', 'height'), 'U_MOVE_UP' => phpbb::$auth->acl_get('u_titania_mod_faq_mod') || titania::$contrib->is_author || titania::$contrib->is_active_coauthor ? $faq->get_url('move_up', $row['faq_id']) : false, 'U_MOVE_DOWN' => phpbb::$auth->acl_get('u_titania_mod_faq_mod') || titania::$contrib->is_author || titania::$contrib->is_active_coauthor ? $faq->get_url('move_down', $row['faq_id']) : false, 'U_EDIT' => phpbb::$auth->acl_get('u_titania_mod_faq_mod') || phpbb::$auth->acl_get('u_titania_faq_edit') && (titania::$contrib->is_author || titania::$contrib->is_active_coauthor) ? $faq->get_url('edit', $row['faq_id']) : false, 'U_DELETE' => phpbb::$auth->acl_get('u_titania_mod_faq_mod') || phpbb::$auth->acl_get('u_titania_faq_delete') && (titania::$contrib->is_author || titania::$contrib->is_active_coauthor) ? $faq->get_url('delete', $row['faq_id']) : false, 'S_ACCESS_TEAMS' => $row['faq_access'] == TITANIA_ACCESS_TEAMS ? true : false, 'S_ACCESS_AUTHORS' => $row['faq_access'] == TITANIA_ACCESS_AUTHORS ? true : false));
            }
            phpbb::$template->assign_vars(array('ICON_MOVE_UP' => '<img src="' . titania::$images_path . 'icon_up.gif" alt="' . phpbb::$user->lang['MOVE_UP'] . '" title="' . phpbb::$user->lang['MOVE_UP'] . '" />', 'ICON_MOVE_UP_DISABLED' => '<img src="' . titania::$images_path . 'icon_up_disabled.gif" alt="' . phpbb::$user->lang['MOVE_UP'] . '" title="' . phpbb::$user->lang['MOVE_UP'] . '" />', 'ICON_MOVE_DOWN' => '<img src="' . titania::$images_path . 'icon_down.gif" alt="' . phpbb::$user->lang['MOVE_DOWN'] . '" title="' . phpbb::$user->lang['MOVE_DOWN'] . '" />', 'ICON_MOVE_DOWN_DISABLED' => '<img src="' . titania::$images_path . 'icon_down_disabled.gif" alt="' . phpbb::$user->lang['MOVE_DOWN'] . '" title="' . phpbb::$user->lang['MOVE_DOWN'] . '" />', 'ICON_EDIT' => '<img src="' . titania::$images_path . 'icon_edit.gif" alt="' . phpbb::$user->lang['EDIT'] . '" title="' . phpbb::$user->lang['EDIT'] . '" />', 'ICON_EDIT_DISABLED' => '<img src="' . titania::$images_path . 'icon_edit_disabled.gif" alt="' . phpbb::$user->lang['EDIT'] . '" title="' . phpbb::$user->lang['EDIT'] . '" />', 'ICON_DELETE' => '<img src="' . titania::$images_path . 'icon_delete.gif" alt="' . phpbb::$user->lang['DELETE'] . '" title="' . phpbb::$user->lang['DELETE'] . '" />', 'ICON_DELETE_DISABLED' => '<img src="' . titania::$images_path . 'icon_delete_disabled.gif" alt="' . phpbb::$user->lang['DELETE'] . '" title="' . phpbb::$user->lang['DELETE'] . '" />', 'S_LIST' => true, 'U_CREATE_FAQ' => phpbb::$auth->acl_get('u_titania_mod_faq_mod') || phpbb::$auth->acl_get('u_titania_faq_create') && (titania::$contrib->is_author || titania::$contrib->is_active_coauthor) ? $faq->get_url('create') : false, 'U_CANONICAL' => $sort->build_canonical()));
        }
        break;
}
phpbb::$template->assign_vars(array('CONTRIB_NAME' => titania::$contrib->contrib_name));
titania::page_footer(false, 'contributions/contribution_faq.html');
开发者ID:kairion,项目名称:customisation-db,代码行数:30,代码来源:faq.php

示例13: array

                if (empty($content)) {
                    continue;
                }
                phpbb::$template->assign_block_vars('options', array('KEY' => $name, 'TITLE' => isset(phpbb::$user->lang[$vars['lang']]) ? phpbb::$user->lang[$vars['lang']] : $vars['lang'], 'S_EXPLAIN' => $vars['explain'], 'TITLE_EXPLAIN' => $l_explain, 'CONTENT' => $content['tpl'], 'S_FIND_USER' => isset($content['find_user']) ? true : false, 'U_FIND_USER' => isset($content['find_user']) ? phpbb::append_sid('memberlist', array('mode' => 'searchuser', 'form' => 'select_user', 'field' => 'username', 'select_single' => 'true', 'form' => 'stk', 'field' => $content['find_user_field'])) : ''));
            }
            titania::page_footer(true, 'manage/tool_options.html');
        } else {
            if (is_string($options)) {
                if (titania::confirm_box(true) || isset($_GET['submit']) && check_link_hash(request_var('hash', ''), 'manage')) {
                    $tool->run_tool();
                } else {
                    titania::confirm_box(false, $options, titania_url::build_url('manage/administration', array('t' => $plugin->tool_id)));
                }
            } else {
                // The page should have been setup by the tool.  We will exit to prevent the redirect from below.
                exit;
            }
        }
    }
    // Should never get here...
    redirect(titania_url::build_url('manage/administration'));
} else {
    titania::page_header('ADMINISTRATION');
    titania::page_footer(true, 'manage/administration.html');
}
function trigger_back($message)
{
    $message = isset(phpbb::$user->lang[$message]) ? phpbb::$user->lang[$message] : $message;
    $message .= '<br /><br /><a href="' . titania_url::build_url('manage/administration') . '">' . phpbb::$user->lang['BACK'] . '</a>';
    trigger_error($message);
}
开发者ID:kairion,项目名称:customisation-db,代码行数:31,代码来源:administration.php

示例14: titania_message

}
$message = new titania_message(titania::$author);
$message->set_auth(array('bbcode' => phpbb::$auth->acl_get('u_titania_bbcode'), 'smilies' => phpbb::$auth->acl_get('u_titania_smilies')));
$message->set_settings(array('display_error' => false, 'display_subject' => false));
$submit = isset($_POST['submit']) ? true : false;
if ($submit) {
    titania::$author->post_data($message);
    titania::$author->__set_array(array('author_realname' => utf8_normalize_nfc(request_var('realname', '', true)), 'author_website' => request_var('website', '')));
    $error = titania::$author->validate();
    if (($validate_form_key = $message->validate_form_key()) !== false) {
        $error[] = $validate_form_key;
    }
    if (!sizeof($error)) {
        // Enhanced editor data is stored in the users table
        $titania_enhanced_editor = isset($_POST['enhanced_editor']) ? true : false;
        if (titania::$author->user_id == phpbb::$user->data['user_id'] && $titania_enhanced_editor != phpbb::$user->data['titania_enhanced_editor']) {
            $sql = 'UPDATE ' . USERS_TABLE . '
				SET titania_enhanced_editor = ' . (int) $titania_enhanced_editor . '
				WHERE user_id = ' . phpbb::$user->data['user_id'];
            phpbb::$db->sql_query($sql);
        }
        titania::$author->submit();
        redirect(titania::$author->get_url());
    }
}
titania::$author->assign_details();
$message->display();
$template->assign_vars(array('S_POST_ACTION' => titania::$author->get_url('manage'), 'S_DISPLAY_ENHANCED_EDITOR' => titania::$author->user_id == phpbb::$user->data['user_id'] ? true : false, 'S_ENHANCED_EDITOR' => phpbb::$user->data['titania_enhanced_editor'], 'AUTHOR_WEBSITE' => titania::$author->get_website_url() || phpbb::$user->data['user_id'] != titania::$author->user_id ? titania::$author->get_website_url() : phpbb::$user->data['user_website'], 'ERROR_MSG' => $submit && sizeof($error) ? implode('<br />', $error) : false));
titania::page_header(titania::$author->get_username_string('username') . ' - ' . phpbb::$user->lang['MANAGE_AUTHOR']);
titania::page_footer(true, 'authors/author_manage.html');
开发者ID:kairion,项目名称:customisation-db,代码行数:30,代码来源:manage.php

示例15: foreach

            $queue_type = $authed[0];
        } else {
            foreach ($authed as $type_id) {
                $sql = 'SELECT COUNT(topic_id) AS cnt FROM ' . TITANIA_TOPICS_TABLE . '
				WHERE topic_type = ' . TITANIA_QUEUE_DISCUSSION . '
					AND topic_category = ' . (int) $type_id;
                phpbb::$db->sql_query($sql);
                $cnt = phpbb::$db->sql_fetchfield('cnt');
                phpbb::$db->sql_freeresult();
                phpbb::$template->assign_block_vars('categories', array('U_VIEW_CATEGORY' => titania_url::append_url($base_url, array('queue' => titania_types::$types[$type_id]->url)), 'CATEGORY_NAME' => titania_types::$types[$type_id]->lang, 'CATEGORY_CONTRIBS' => $cnt));
            }
            phpbb::$template->assign_vars(array('S_QUEUE_LIST' => true));
            titania::page_header('QUEUE_DISCUSSION');
            titania::page_footer(true, 'manage/queue.html');
        }
    }
} else {
    if (!titania_types::$types[$queue_type]->acl_get('queue_discussion')) {
        titania::needs_auth();
    }
}
// Add the queue type to the base url
$base_url = titania_url::append_url($base_url, array('queue' => titania_types::$types[$queue_type]->url));
// Add to Breadcrumbs
titania::generate_breadcrumbs(array(titania_types::$types[$queue_type]->lang => $base_url));
topics_overlord::display_forums_complete('queue_discussion', false, array('topic_category' => $queue_type));
// Mark all topics read
phpbb::$template->assign_var('U_MARK_TOPICS', titania_url::append_url($base_url, array('mark' => 'topics')));
titania::page_header('QUEUE_DISCUSSION');
titania::page_footer(true, 'manage/queue_discussion.html');
开发者ID:kairion,项目名称:customisation-db,代码行数:30,代码来源:queue_discussion.php


注:本文中的titania::page_footer方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。