本文整理汇总了PHP中fn_add_breadcrumb函数的典型用法代码示例。如果您正苦于以下问题:PHP fn_add_breadcrumb函数的具体用法?PHP fn_add_breadcrumb怎么用?PHP fn_add_breadcrumb使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了fn_add_breadcrumb函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: modePayment
function modePayment()
{
$rid = $_REQUEST['order_id'];
$orderId = $_SESSION['pw_order_id'];
$iframe = '';
$matchOrder = $rid == $orderId;
$orderInfo = fn_get_order_info($orderId);
if ($matchOrder && $orderInfo) {
// Prepare Widget
$iframe = fn_paymentwall_generateWidget($orderInfo, fn_paymentwall_getPaymentConfigs($orderInfo['payment_id']));
}
fn_add_breadcrumb('Paymentwall Payment', '#', true);
Tygh::$app['view']->assign('params', array('matchOrder' => $matchOrder, 'orderId' => $orderId, 'baseUrl' => fn_url(), 'iframe' => $iframe));
}
示例2: fn_get_user_info
if (fn_request_usergroup($auth['user_id'], $_REQUEST['usergroup_id'], $_REQUEST['type'])) {
$user_data = fn_get_user_info($auth['user_id']);
Mailer::sendMail(array('to' => 'default_company_users_department', 'from' => 'default_company_users_department', 'reply_to' => $user_data['email'], 'data' => array('user_data' => $user_data, 'usergroups' => fn_get_usergroups('F', Registry::get('settings.Appearance.backend_default_language')), 'usergroup_id' => $_REQUEST['usergroup_id']), 'tpl' => 'profiles/usergroup_request.tpl', 'company_id' => $user_data['company_id']), 'A', Registry::get('settings.Appearance.backend_default_language'));
}
return array(CONTROLLER_STATUS_OK, "profiles.update");
} elseif ($mode == 'success_add') {
if (empty($auth['user_id'])) {
return array(CONTROLLER_STATUS_REDIRECT, "profiles.add");
}
fn_add_breadcrumb(__('registration'));
} elseif ($mode == "profile_home_page") {
if (empty($auth['user_id'])) {
return array(CONTROLLER_STATUS_REDIRECT, "auth.login_form?return_url=" . urlencode(Registry::get('config.current_url')));
}
$profile_id = empty($_REQUEST['profile_id']) ? 0 : $_REQUEST['profile_id'];
fn_add_breadcrumb(__('profile_home'));
if (!empty($_REQUEST['profile']) && $_REQUEST['profile'] == 'new') {
$user_data = fn_get_user_info($auth['user_id'], false);
} else {
$user_data = fn_get_user_info($auth['user_id'], true, $profile_id);
}
if (empty($user_data)) {
return array(CONTROLLER_STATUS_NO_PAGE);
}
$restored_user_data = fn_restore_post_data('user_data');
if ($restored_user_data) {
$user_data = fn_array_merge($user_data, $restored_user_data);
}
Registry::set('navigation.tabs.general', array('title' => __('general'), 'js' => true));
$show_usergroups = true;
if (Registry::get('settings.General.allow_usergroup_signup') != 'Y') {
示例3: elseif
} elseif ($mode == 'on_sale') {
$title = __("on_sale");
$params['on_sale'] = true;
} elseif ($mode == 'bestsellers') {
$title = __("bestsellers");
$params['bestsellers'] = true;
$params['sales_amount_from'] = Registry::get('addons.bestsellers.sales_amount_from');
} elseif ($mode == 'newest') {
$title = __("newest");
$params['sort_by'] = empty($params['sort_by']) ? 'timestamp' : $params['sort_by'];
$params['plain'] = true;
$params['visible'] = true;
$period = Registry::get('addons.bestsellers.period');
$params['period'] = 'A';
if ($period == 'today') {
$params['period'] = 'D';
} elseif ($period == 'last_days') {
$params['period'] = 'HC';
$params['last_days'] = Registry::get('addons.bestsellers.last_days');
}
} else {
$title = __('products');
}
fn_add_breadcrumb($title);
list($products, $search) = fn_get_products($params, Registry::get('settings.Appearance.products_per_page'));
fn_gather_additional_products_data($products, array('get_icon' => true, 'get_detailed' => true, 'get_additional' => true, 'get_options' => true));
$selected_layout = fn_get_products_layout($params);
Registry::get('view')->assign('products', $products);
Registry::get('view')->assign('search', $search);
Registry::get('view')->assign('selected_layout', $selected_layout);
}
示例4: array
if ($mode == 'login_form') {
if (defined('AJAX_REQUEST') && empty($auth)) {
exit;
}
if (!empty($auth['user_id'])) {
return array(CONTROLLER_STATUS_REDIRECT, $index_script);
}
fn_add_breadcrumb(fn_get_lang_var('my_account'));
} elseif ($mode == 'password_change' && AREA == 'A') {
if (defined('AJAX_REQUEST') && empty($auth)) {
exit;
}
if (empty($auth['user_id'])) {
return array(CONTROLLER_STATUS_REDIRECT, $index_script);
}
fn_add_breadcrumb(fn_get_lang_var('my_account'));
$profile_id = 0;
$user_data = fn_get_user_info($auth['user_id'], true, $profile_id);
$view->assign('user_data', $user_data);
$view->assign('view_mode', 'simple');
} elseif ($mode == 'change_login') {
$auth = $_SESSION['auth'];
if (!empty($auth['user_id'])) {
// Log user logout
fn_log_event('users', 'session', array('user_id' => $auth['user_id'], 'time' => TIME - $auth['this_login'], 'timeout' => false));
}
unset($_SESSION['auth'], $_SESSION['cart']['user_data']);
fn_delete_cookies(AREA_NAME . '_user_id', AREA_NAME . '_password');
return array(CONTROLLER_STATUS_OK, fn_url('checkout.checkout'));
}
function fn_auth_routines($request)
示例5: db_get_field
$allowed_id = db_get_field("SELECT user_id FROM ?:orders WHERE user_id = ?i AND order_id = ?i", $auth['user_id'], $_REQUEST['order_id']);
}
fn_set_hook('is_order_allowed', $_REQUEST['order_id'], $allowed_id);
if (empty($allowed_id)) {
// Access denied
return array(CONTROLLER_STATUS_DENIED);
}
$order_info = fn_get_order_info($_REQUEST['order_id']);
if (!empty($order_info['is_parent_order']) && $order_info['is_parent_order'] == 'Y') {
$order_info['child_ids'] = implode(',', db_get_fields("SELECT order_id FROM ?:orders WHERE parent_order_id = ?i", $_REQUEST['order_id']));
}
if (!empty($order_info)) {
Tygh::$app['view']->assign('order_info', $order_info);
}
}
fn_add_breadcrumb(__('landing_header'));
} elseif ($mode == 'process_payment') {
if (fn_allow_place_order($cart, $auth) == true) {
$order_info = $cart;
$order_info['products'] = $cart['products'];
$order_info = fn_array_merge($order_info, $cart['user_data']);
$order_info['order_id'] = $order_id = TIME . "_" . (!empty($auth['user_id']) ? $auth['user_id'] : 0);
unset($order_info['user_data']);
list($is_processor_script, $processor_data) = fn_check_processor_script($order_info['payment_id']);
if ($is_processor_script) {
set_time_limit(300);
fn_define('IFRAME_MODE', true);
include Registry::get('config.dir.payments') . $processor_data['processor_script'];
fn_finish_payment($order_id, $pp_response, array());
fn_order_placement_routines('route', $order_id);
}
示例6: fn_add_breadcrumb
}
if (AREA != 'A') {
fn_add_breadcrumb(__('hybrid_auth.connect_social'));
}
$user_id = fn_is_user_exists(0, array('email' => $email));
if (!empty($user_id)) {
$user_data = fn_get_user_short_info($user_id);
$user_login = $user_data['email'];
} else {
$user_login = '';
}
Tygh::$app['view']->assign('user_login', $user_login);
Tygh::$app['view']->assign('identifier', $identifier);
Tygh::$app['view']->assign('view_mode', 'simple');
} elseif ($mode == 'specify_email') {
if (!empty($_REQUEST['user_email'])) {
fn_hybrid_auth_process('login_provider', $redirect_url);
$_REQUEST['redirect_url'] = $redirect_url;
return array(CONTROLLER_STATUS_REDIRECT, fn_url($redirect_url));
}
$identifier = !empty($_SESSION['hybrid_auth']['identifier']) ? $_SESSION['hybrid_auth']['identifier'] : '';
$provider = !empty($_SESSION['hybrid_auth']['provider']) ? $_SESSION['hybrid_auth']['provider'] : '';
$redirect_url = !empty($_SESSION['hybrid_auth']['redirect_url']) ? $_SESSION['hybrid_auth']['redirect_url'] : fn_url();
if (AREA != 'A') {
fn_add_breadcrumb(__('hybrid_auth.specify_email'));
}
Tygh::$app['view']->assign('identifier', $identifier);
Tygh::$app['view']->assign('provider', $provider);
Tygh::$app['view']->assign('redirect_url', $redirect_url);
Tygh::$app['view']->assign('view_mode', 'simple');
}
示例7: fn_get_category_name
Tygh::$app['view']->assign('search', $search);
Tygh::$app['view']->assign('selected_layout', $selected_layout);
Tygh::$app['view']->assign('category_data', $category_data);
// If page title for this category is exist than assign it to template
if (!empty($category_data['page_title'])) {
Tygh::$app['view']->assign('page_title', $category_data['page_title']);
}
// [Breadcrumbs]
if (!empty($category_parent_ids)) {
Registry::set('runtime.active_category_ids', $category_parent_ids);
$cats = fn_get_category_name($category_parent_ids);
foreach ($category_parent_ids as $c_id) {
fn_add_breadcrumb($cats[$c_id], "categories.view?category_id={$c_id}");
}
}
fn_add_breadcrumb($category_data['category'], empty($_REQUEST['features_hash']) ? '' : "categories.view?category_id={$_REQUEST['category_id']}");
// [/Breadcrumbs]
} else {
return array(CONTROLLER_STATUS_NO_PAGE);
}
} elseif ($mode == 'picker') {
$category_count = db_get_field("SELECT COUNT(*) FROM ?:categories");
if ($category_count < CATEGORY_THRESHOLD) {
$params = array('simple' => false);
list($categories_tree, ) = fn_get_categories($params);
Tygh::$app['view']->assign('show_all', true);
} else {
$params = array('category_id' => $_REQUEST['category_id'], 'current_category_id' => $_REQUEST['category_id'], 'visible' => true, 'simple' => false);
list($categories_tree, ) = fn_get_categories($params);
}
if (!empty($_REQUEST['root'])) {
示例8: fn_set_notification
}
Tygh::$app['view']->assign('verify_data', $verify_data);
} else {
fn_set_notification('W', __('warning'), __('error_gift_cert_code'));
if (defined('AJAX_REQUEST')) {
exit;
}
}
} elseif ($mode == 'add') {
fn_add_breadcrumb(__('gift_certificates'));
Tygh::$app['view']->assign('templates', fn_get_gift_certificate_templates());
Tygh::$app['view']->assign('states', fn_get_all_states());
Tygh::$app['view']->assign('countries', fn_get_simple_countries(true, CART_LANGUAGE));
} elseif ($mode == 'update') {
if (!empty($_REQUEST['gift_cert_id']) && !isset($_SESSION['cart']['gift_certificates'][$_REQUEST['gift_cert_id']])) {
return array(CONTROLLER_STATUS_REDIRECT, 'gift_certificates.add');
}
fn_add_breadcrumb(__('gift_certificates'));
if (!empty($_REQUEST['gift_cert_id'])) {
$gift_cert_data = fn_get_gift_certificate_info($_REQUEST['gift_cert_id'], 'C');
if (!empty($gift_cert_data['extra']['exclude_from_calculate'])) {
return array(CONTROLLER_STATUS_NO_PAGE);
}
Tygh::$app['view']->assign('gift_cert_data', $gift_cert_data);
Tygh::$app['view']->assign('gift_cert_id', $_REQUEST['gift_cert_id']);
}
Tygh::$app['view']->assign('templates', fn_get_gift_certificate_templates());
Tygh::$app['view']->assign('states', fn_get_all_states());
Tygh::$app['view']->assign('countries', fn_get_simple_countries(true, CART_LANGUAGE));
Tygh::$app['view']->assign('type', 'C');
}
示例9: var_dump
//
// Check if store is closed
//
if (Registry::get('settings.store_mode') == 'closed') {
if (!empty($_REQUEST['store_access_key'])) {
$_SESSION['store_access_key'] = $_GET['store_access_key'];
}
var_dump($_SESSION['store_access_key']);
if (empty($_SESSION['store_access_key']) || $_SESSION['store_access_key'] != Registry::get('settings.General.store_access_key')) {
return array(CONTROLLER_STATUS_REDIRECT, Registry::get('config.current_location') . '/store_closed.html');
}
}
if (empty($_REQUEST['product_id']) && empty($_REQUEST['category_id'])) {
unset($_SESSION['current_category_id']);
}
fn_add_breadcrumb(fn_get_lang_var('home'), $index_script);
$request_params = $_REQUEST;
$request_params['location'] = fn_get_blocks_location(CONTROLLER);
list($blocks) = fn_get_blocks($request_params);
$view->assign('blocks', $blocks);
$view->assign('location_data', fn_get_location_data($request_params['location'], true));
// Get quick links
Registry::register_cache('quick_links', array('static_data'), CACHE_LEVEL_LOCALE);
if (Registry::is_exist('quick_links') == false) {
Registry::set('quick_links', fn_get_static_data_section('N'));
}
// Get top menu
Registry::register_cache('top_menu', array('static_data', 'categories', 'pages'), CACHE_LEVEL_LOCALE_AUTH);
if (Registry::is_exist('top_menu') == false) {
Registry::set('top_menu', fn_top_menu_form(fn_get_static_data_section('A', true)));
}
示例10: define
****************************************************************************
* PLEASE READ THE FULL TEXT OF THE SOFTWARE LICENSE AGREEMENT IN THE *
* "copyright.txt" FILE PROVIDED WITH THIS DISTRIBUTION PACKAGE. *
****************************************************************************/
use Tygh\Registry;
if (!defined('BOOTSTRAP')) {
define('FORCE_SESSION_START', true);
//it will be merged with the $_REQUEST later
$_GET['dispatch'] = 'checkout.cresecure_template';
require './init_payment.php';
require Registry::get('config.dir.root') . '/app/controllers/frontend/init.php';
Tygh::$app['view']->assign('display_base_href', true);
//We should assign this information to display in the default checkout blocks (Order summary and Products in your order)
Tygh::$app['view']->assign('cart', Tygh::$app['session']['cart']);
Tygh::$app['view']->assign('cart_products', Tygh::$app['session']['cart']['products']);
fn_add_breadcrumb(__('payment_information'));
Tygh::$app['view']->assign('content_tpl', 'views/orders/processors/cresecure.tpl');
Tygh::$app['view']->display(Registry::get('runtime.root_template'));
} else {
if (defined('PAYMENT_NOTIFICATION')) {
if ($mode == 'return') {
//NOTE: do not remove intval() !
$order_id = intval($_REQUEST['order_id']);
$pp_response = array();
$payment_id = db_get_field("SELECT payment_id FROM ?:orders WHERE order_id=?i", $order_id);
$processor_data = fn_get_processor_data($payment_id);
if (empty($_REQUEST['error']) && !empty($_REQUEST['msg']) && ($_REQUEST['msg'] == 'Success' || $_REQUEST['msg'] == 'Approved')) {
$pp_response['order_status'] = 'P';
$pp_response['reason_text'] = $_REQUEST['msg'];
$pp_response['transaction_id'] = $_REQUEST['TxnGUID'];
$pp_response['card_number'] = $_REQUEST['mPAN'];
示例11: array
Registry::set('navigation.tabs', array('general' => array('title' => fn_get_lang_var('general'), 'js' => true), 'products' => array('title' => fn_get_lang_var('products'), 'js' => true)));
list($steps) = fn_get_configurator_steps($_REQUEST);
$view->assign('steps', $steps);
} elseif ($mode == 'update_class') {
fn_add_breadcrumb(fn_get_lang_var('product_classes'), "configurator.manage?selected_section=classes");
$product_class = db_get_row("SELECT ?:conf_classes.*, ?:conf_class_descriptions.class_name FROM ?:conf_classes LEFT JOIN ?:conf_class_descriptions ON ?:conf_class_descriptions.class_id = ?:conf_classes.class_id WHERE ?:conf_class_descriptions.lang_code = ?s AND ?:conf_classes.class_id = ?i", DESCR_SL, $_REQUEST['class_id']);
// Get class products
$product_class['product_ids'] = db_get_fields("SELECT ?:products.product_id FROM ?:products LEFT JOIN ?:conf_class_products ON ?:conf_class_products.product_id = ?:products.product_id WHERE ?:conf_class_products.class_id = ?i", $_REQUEST['class_id']);
$product_class['compatible_classes'] = db_get_fields("SELECT ?:conf_compatible_classes.slave_class_id FROM ?:conf_compatible_classes WHERE master_class_id = ?i", $_REQUEST['class_id']);
Registry::set('navigation.tabs', array('general' => array('title' => fn_get_lang_var('general'), 'js' => true), 'products' => array('title' => fn_get_lang_var('products'), 'js' => true)));
$view->assign('product_class', $product_class);
list($groups) = fn_get_configurator_groups($_REQUEST);
$view->assign('groups', $groups);
$view->assign('classes', fn_get_configurator_classes(array('simple' => true)));
} elseif ($mode == 'add_class') {
fn_add_breadcrumb(fn_get_lang_var('product_classes'), "configurator.manage?selected_section=classes");
Registry::set('navigation.tabs', array('general' => array('title' => fn_get_lang_var('general'), 'js' => true), 'products' => array('title' => fn_get_lang_var('products'), 'js' => true)));
list($groups) = fn_get_configurator_groups($_REQUEST);
$view->assign('groups', $groups);
$view->assign('classes', fn_get_configurator_classes(array('simple' => true)));
} elseif ($mode == 'manage') {
list($classes, $search) = fn_get_configurator_classes($_REQUEST);
$view->assign('classes', $classes);
$view->assign('classes_search', $search);
list($steps, $search) = fn_get_configurator_steps($_REQUEST);
$view->assign('steps', $steps);
$view->assign('steps_search', $search);
list($groups, $search) = fn_get_configurator_groups($_REQUEST, Registry::get('settings.Appearance.admin_elements_per_page'));
$view->assign('groups', $groups);
$view->assign('groups_search', $search);
list($all_groups) = fn_get_configurator_groups($_REQUEST);
示例12: die
<?php
/***************************************************************************
* *
* (c) 2004 Vladimir V. Kalynyak, Alexey V. Vinokurov, Ilya M. Shalnev *
* *
* This is commercial software, only users who have purchased a valid *
* license and accept to the terms of the License Agreement can install *
* and use this program. *
* *
****************************************************************************
* PLEASE READ THE FULL TEXT OF THE SOFTWARE LICENSE AGREEMENT IN THE *
* "copyright.txt" FILE PROVIDED WITH THIS DISTRIBUTION PACKAGE. *
****************************************************************************/
use Tygh\Registry;
if (!defined('BOOTSTRAP')) {
die('Access denied');
}
if ($mode == 'results') {
$params = $_REQUEST;
$params['objects'] = array_keys(fn_search_get_customer_objects());
unset($params['compact']);
list($search_results, $search) = fn_search($params, Registry::get('settings.Appearance.products_per_page'));
Tygh::$app['view']->assign('search_results', $search_results);
Tygh::$app['view']->assign('search', $search);
fn_add_breadcrumb(__('search_results'));
}
示例13: array_pop
if (!empty($shipment)) {
$shipment = array_pop($shipment);
foreach ($order_info['items'] as $item_id => $item) {
if (isset($shipment['items'][$item_id])) {
$order_info['items'][$item_id]['amount'] = $shipment['items'][$item_id];
} else {
$order_info['items'][$item_id]['amount'] = 0;
}
}
} else {
$shipment = array();
}
$view->assign('shipment', $shipment);
}
fn_add_breadcrumb(fn_get_lang_var('shipments'), 'shipments.manage.reset_view');
fn_add_breadcrumb(fn_get_lang_var('search_results'), "shipments.manage.last_view");
$view->assign('shippings', $shippings);
$view->assign('order_info', $order_info);
} elseif ($mode == 'manage') {
list($shipments, $search, $totals) = fn_get_shipments_info($params);
$view->assign('shipments', $shipments);
$view->assign('search', $search);
$view->assign('totals', $totals);
} elseif ($mode == 'packing_slip' && !empty($_REQUEST['shipment_ids'])) {
$html = array();
$params = $_REQUEST;
foreach ($params['shipment_ids'] as $k => $v) {
list($shipment, $order_info) = fn_get_packing_info($v);
$view_mail->assign('order_info', $order_info);
$view_mail->assign('shipment', $shipment);
if (DISPATCH_EXTRA == 'pdf') {
示例14: fn_get_page_object_by_type
$view->assign('all_pages_list', $pages_tree);
$view->assign('page_type', $page_type);
$view->assign('page_type_data', fn_get_page_object_by_type($page_type));
$view->assign('companies', fn_get_short_companies());
//
// 'page update' page
//
} elseif ($mode == 'update') {
Registry::set('navigation.tabs', array('basic' => array('title' => fn_get_lang_var('general'), 'js' => true), 'blocks' => array('title' => fn_get_lang_var('blocks'), 'js' => true), 'addons' => array('title' => fn_get_lang_var('addons'), 'js' => true)));
// Get current page data
$page_data = fn_get_page_data($page_id, DESCR_SL);
if (!$page_data) {
return array(CONTROLLER_STATUS_NO_PAGE);
}
// [Breadcrumbs]
fn_add_breadcrumb(fn_get_lang_var('pages'), "pages.manage&get_tree=multi_level");
// [/Breadcrumbs]
if ($page_data['page_type'] == PAGE_TYPE_LINK) {
Registry::set('navigation.selected_tab', 'content');
Registry::set('navigation.subsection', 'links');
}
// [Block manager]
list($blocks) = fn_get_blocks(array('location' => 'pages', 'block_type' => 'B', 'all' => true));
if (!empty($blocks)) {
$view->assign('blocks', $blocks);
$view->assign('selected_block', fn_get_selected_block_data($_REQUEST, $blocks, $_REQUEST['page_id'], 'pages'));
$view->assign('block_properties', fn_get_block_properties());
}
// [/Block manager]
list($pages_tree, $params) = fn_get_pages(array('get_tree' => 'plain'));
$view->assign('all_pages_list', $pages_tree);
示例15: array
}
if ($mode == 'clear') {
$wishlist = array();
fn_save_cart_content($wishlist, $auth['user_id'], 'W');
return array(CONTROLLER_STATUS_REDIRECT, "wishlist.view");
} elseif ($mode == 'delete' && !empty($_REQUEST['cart_id'])) {
fn_delete_wishlist_product($wishlist, $_REQUEST['cart_id']);
fn_save_cart_content($wishlist, $auth['user_id'], 'W');
return array(CONTROLLER_STATUS_OK, "wishlist.view");
} elseif ($mode == 'delete_footer' && !empty($_REQUEST['cart_id'])) {
fn_delete_wishlist_product($wishlist, $_REQUEST['cart_id']);
fn_save_cart_content($wishlist, $auth['user_id'], 'W');
exit;
} elseif ($mode == 'view') {
if (!$auth['user_id']) {
fn_add_breadcrumb(__('wishlist_content'));
}
$products = !empty($wishlist['products']) ? $wishlist['products'] : array();
$extra_products = array();
$wishlist_is_empty = fn_cart_is_empty($wishlist);
if (!empty($products)) {
foreach ($products as $k => $v) {
$_options = array();
$extra = $v['extra'];
if (!empty($v['product_options'])) {
$_options = $v['product_options'];
}
$products[$k] = fn_get_product_data($v['product_id'], $auth, CART_LANGUAGE, '', true, true, true, false, false, true, false, true);
if (empty($products[$k])) {
unset($products[$k], $wishlist['products'][$k]);
continue;