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


PHP osc_href_link_admin函数代码示例

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


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

示例1: _setData

 function _setData()
 {
     global $osC_Database, $osC_Language;
     $this->_data = '<table border="0" width="100%" cellspacing="0" cellpadding="2" class="dataTable">' . '  <thead>' . '    <tr>' . '      <th>' . $osC_Language->get('summary_customers_table_heading_customers') . '</th>' . '      <th>' . $osC_Language->get('summary_customers_table_heading_date') . '</th>' . '      <th>' . $osC_Language->get('summary_customers_table_heading_status') . '</th>' . '    </tr>' . '  </thead>' . '  <tbody>';
     $Qcustomers = $osC_Database->query('select customers_id, customers_gender, customers_lastname, customers_firstname, customers_status, date_account_created from :table_customers order by date_account_created desc limit 6');
     $Qcustomers->bindTable(':table_customers', TABLE_CUSTOMERS);
     $Qcustomers->execute();
     $counter = 0;
     while ($Qcustomers->next()) {
         $customer_icon = osc_icon('people.png');
         if (ACCOUNT_GENDER > -1) {
             switch ($Qcustomers->value('customers_gender')) {
                 case 'm':
                     $customer_icon = osc_icon('user_male.png');
                     break;
                 case 'f':
                     $customer_icon = osc_icon('user_female.png');
                     break;
             }
         }
         $this->_data .= '    <tr onmouseover="$(this).addClass(\'mouseOver\');" onmouseout="$(this).removeClass(\'mouseOver\');"' . ($counter % 2 ? ' class="alt"' : '') . '>' . '      <td>' . osc_link_object(osc_href_link_admin(FILENAME_DEFAULT, 'customers&cID=' . $Qcustomers->valueInt('customers_id') . '&action=save'), $customer_icon . '&nbsp;' . $Qcustomers->valueProtected('customers_firstname') . ' ' . $Qcustomers->valueProtected('customers_lastname')) . '</td>' . '      <td>' . $Qcustomers->value('date_account_created') . '</td>' . '      <td align="center">' . osc_icon($Qcustomers->valueInt('customers_status') === 1 ? 'checkbox_ticked.gif' : 'checkbox_crossed.gif', null, null) . '</td>' . '    </tr>';
         $counter++;
     }
     $this->_data .= '  </tbody>' . '</table>';
     $Qcustomers->freeResult();
 }
开发者ID:Jon86,项目名称:oscommerce,代码行数:26,代码来源:customers.php

示例2: __construct

 function __construct()
 {
     global $osC_Language, $osC_MessageStack;
     if (!isset($_GET['set'])) {
         $_GET['set'] = '';
     }
     if (!isset($_GET['action'])) {
         $_GET['action'] = '';
     }
     switch ($_GET['set']) {
         case 'content':
             $this->_page_title = $osC_Language->get('heading_title_content');
             break;
         case 'boxes':
         default:
             $_GET['set'] = 'boxes';
             $this->_page_title = $osC_Language->get('heading_title_boxes');
             break;
     }
     include '../includes/classes/modules.php';
     $osC_Language->load('modules-' . $_GET['set']);
     if (!empty($_GET['action'])) {
         switch ($_GET['action']) {
             case 'info':
                 $this->_page_contents = 'info.php';
                 break;
             case 'save':
                 $this->_page_contents = 'edit.php';
                 if (isset($_POST['subaction']) && $_POST['subaction'] == 'confirm') {
                     $data = array('configuration' => $_POST['configuration']);
                     if ($this->_save($data)) {
                         $osC_MessageStack->add($this->_module, $osC_Language->get('ms_success_action_performed'), 'success');
                     } else {
                         $osC_MessageStack->add($this->_module, $osC_Language->get('ms_error_action_not_performed'), 'error');
                     }
                     osc_redirect_admin(osc_href_link_admin(FILENAME_DEFAULT, $this->_module . '&set=' . $_GET['set']));
                 }
                 break;
             case 'install':
                 if ($this->_install($_GET['module'], $_GET['set'])) {
                     $osC_MessageStack->add($this->_module, $osC_Language->get('ms_success_action_performed'), 'success');
                 } else {
                     $osC_MessageStack->add($this->_module, $osC_Language->get('ms_error_action_not_performed'), 'error');
                 }
                 osc_redirect_admin(osc_href_link_admin(FILENAME_DEFAULT, $this->_module . '&set=' . $_GET['set']));
                 break;
             case 'uninstall':
                 $this->_page_contents = 'uninstall.php';
                 if (isset($_POST['subaction']) && $_POST['subaction'] == 'confirm') {
                     if ($this->_uninstall($_GET['module'], $_GET['set'])) {
                         $osC_MessageStack->add($this->_module, $osC_Language->get('ms_success_action_performed'), 'success');
                     } else {
                         $osC_MessageStack->add($this->_module, $osC_Language->get('ms_error_action_not_performed'), 'error');
                     }
                     osc_redirect_admin(osc_href_link_admin(FILENAME_DEFAULT, $this->_module . '&set=' . $_GET['set']));
                 }
                 break;
         }
     }
 }
开发者ID:digitaldevelopers,项目名称:oscommerce,代码行数:60,代码来源:templates_modules.php

示例3: _setData

 function _setData()
 {
     global $osC_Database, $osC_Language, $osC_Currencies;
     if (!isset($osC_Currencies)) {
         if (!class_exists('osC_Currencies')) {
             include '../includes/classes/currencies.php';
         }
         $osC_Currencies = new osC_Currencies();
     }
     $this->_data = '<table border="0" width="100%" cellspacing="0" cellpadding="2" class="dataTable">' . '  <thead>' . '    <tr>' . '      <th>' . $osC_Language->get('summary_products_table_heading_products') . '</th>' . '      <th>' . $osC_Language->get('summary_products_table_heading_price') . '</th>' . '      <th>' . $osC_Language->get('summary_products_table_heading_date') . '</th>' . '      <th>' . $osC_Language->get('summary_products_table_heading_status') . '</th>' . '    </tr>' . '  </thead>' . '  <tbody>';
     $Qproducts = $osC_Database->query('select products_id, greatest(products_date_added, products_last_modified) as date_last_modified from :table_products where parent_id = 0 order by date_last_modified desc limit 6');
     $Qproducts->bindTable(':table_products', TABLE_PRODUCTS);
     $Qproducts->execute();
     while ($Qproducts->next()) {
         $data = osC_Products_Admin::get($Qproducts->valueInt('products_id'));
         $products_icon = osc_icon('products.png');
         $products_price = $data['products_price'];
         if (!empty($data['variants'])) {
             $products_icon = osc_icon('attach.png');
             $products_price = null;
             foreach ($data['variants'] as $variant) {
                 if ($products_price === null || $variant['data']['price'] < $products_price) {
                     $products_price = $variant['data']['price'];
                 }
             }
             if ($products_price === null) {
                 $products_price = 0;
             }
         }
         $this->_data .= '    <tr onmouseover="rowOverEffect(this);" onmouseout="rowOutEffect(this);">' . '      <td>' . osc_link_object(osc_href_link_admin(FILENAME_DEFAULT, 'products=' . (int) $data['products_id'] . '&action=save'), $products_icon . '&nbsp;' . osc_output_string_protected($data['products_name'])) . '</td>' . '      <td>' . (!empty($data['variants']) ? 'from ' : '') . $osC_Currencies->format($products_price) . '</td>' . '      <td>' . $Qproducts->value('date_last_modified') . '</td>' . '      <td align="center">' . osc_icon((int) $data['products_status'] === 1 ? 'checkbox_ticked.gif' : 'checkbox_crossed.gif', null, null) . '</td>' . '    </tr>';
     }
     $this->_data .= '  </tbody>' . '</table>';
     $Qproducts->freeResult();
 }
开发者ID:heshuai64,项目名称:gamestore,代码行数:34,代码来源:products.php

示例4: __construct

 public function __construct()
 {
     global $osC_Language, $osC_MessageStack;
     parent::__construct();
     if (isset($_POST['batch']) && is_array($_POST['batch']) && !empty($_POST['batch'])) {
         $this->_page_contents = 'batch_edit.php';
         if (isset($_POST['subaction']) && $_POST['subaction'] == 'confirm') {
             $error = false;
             foreach ($_POST['batch'] as $id) {
                 if (!osC_Administrators_Admin::setAccessLevels($id, $_POST['modules'], $_POST['mode'])) {
                     $error = true;
                     break;
                 }
             }
             if ($error === false) {
                 $osC_MessageStack->add($this->_module, $osC_Language->get('ms_success_action_performed'), 'success');
                 if (in_array($_SESSION['admin']['id'], $_POST['batch'])) {
                     $_SESSION['admin']['access'] = osC_Access::getUserLevels($_SESSION['admin']['id']);
                 }
             } else {
                 $osC_MessageStack->add($this->_module, $osC_Language->get('ms_error_action_not_performed'), 'error');
             }
             osc_redirect_admin(osc_href_link_admin(FILENAME_DEFAULT, $this->_module));
         }
     }
 }
开发者ID:heshuai64,项目名称:gamestore,代码行数:26,代码来源:batch_save.php

示例5: __construct

 public function __construct()
 {
     global $osC_Language, $osC_MessageStack;
     parent::__construct();
     if (isset($_GET['aID']) && is_numeric($_GET['aID'])) {
         $this->_page_contents = 'edit.php';
     } else {
         $this->_page_contents = 'new.php';
     }
     if (isset($_POST['subaction']) && $_POST['subaction'] == 'confirm') {
         $data = array('username' => $_POST['user_name'], 'password' => $_POST['user_password']);
         switch (osC_Administrators_Admin::save(isset($_GET['aID']) && is_numeric($_GET['aID']) ? $_GET['aID'] : null, $data, isset($_POST['modules']) ? $_POST['modules'] : null)) {
             case 1:
                 if (isset($_GET['aID']) && is_numeric($_GET['aID']) && $_GET['aID'] == $_SESSION['admin']['id']) {
                     $_SESSION['admin']['access'] = osC_Access::getUserLevels($_GET['aID']);
                 }
                 $osC_MessageStack->add($this->_module, $osC_Language->get('ms_success_action_performed'), 'success');
                 osc_redirect_admin(osc_href_link_admin(FILENAME_DEFAULT, $this->_module));
                 break;
             case -1:
                 $osC_MessageStack->add($this->_module, $osC_Language->get('ms_error_action_not_performed'), 'error');
                 osc_redirect_admin(osc_href_link_admin(FILENAME_DEFAULT, $this->_module));
                 break;
             case -2:
                 $osC_MessageStack->add($this->_module, $osC_Language->get('ms_error_username_already_exists'), 'error');
                 break;
         }
     }
 }
开发者ID:heshuai64,项目名称:gamestore,代码行数:29,代码来源:save.php

示例6: __construct

 public function __construct()
 {
     global $osC_Language, $osC_MessageStack;
     parent::__construct();
     if (isset($_GET['cID']) && is_numeric($_GET['cID'])) {
         $this->_page_contents = 'edit.php';
     } else {
         $this->_page_contents = 'new.php';
     }
     if (isset($_POST['subaction']) && $_POST['subaction'] == 'confirm') {
         $data = array('name' => $_POST['categories_name'], 'image' => isset($_FILES['categories_image']) ? $_FILES['categories_image'] : null, 'sort_order' => $_POST['sort_order']);
         if (!isset($_GET['cID'])) {
             $data['parent_id'] = $_POST['parent_id'];
         }
         $error = false;
         foreach ($data['name'] as $key => $value) {
             if (empty($value)) {
                 $osC_MessageStack->add($this->_module, sprintf($osC_Language->get('ms_warning_category_name_empty'), $osC_Language->getData($key, 'name')), 'warning');
                 $error = true;
             }
         }
         if ($error === false) {
             if (osC_Categories_Admin::save(isset($_GET['cID']) && is_numeric($_GET['cID']) ? $_GET['cID'] : null, $data)) {
                 $osC_MessageStack->add($this->_module, $osC_Language->get('ms_success_action_performed'), 'success');
             } else {
                 $osC_MessageStack->add($this->_module, $osC_Language->get('ms_error_action_not_performed'), 'error');
             }
             osc_redirect_admin(osc_href_link_admin(FILENAME_DEFAULT, $this->_module . '=' . $_GET[$this->_module]));
         }
     }
 }
开发者ID:heshuai64,项目名称:gamestore,代码行数:31,代码来源:save.php

示例7: __construct

 public function __construct()
 {
     global $osC_Language, $osC_MessageStack;
     parent::__construct();
     unset($_SESSION['admin']);
     $osC_MessageStack->add('header', $osC_Language->get('ms_success_logged_out'), 'success');
     osc_redirect_admin(osc_href_link_admin(FILENAME_DEFAULT));
 }
开发者ID:heshuai64,项目名称:gamestore,代码行数:8,代码来源:logoff.php

示例8: __construct

 function __construct()
 {
     global $osC_Language;
     $osC_Language->loadIniFile('modules/summary/error_log.php');
     $this->_title = $osC_Language->get('summary_error_log_title');
     $this->_title_link = osc_href_link_admin(FILENAME_DEFAULT, 'error_log');
     if (osC_Access::hasAccess('error_log')) {
         $this->_setData();
     }
 }
开发者ID:Jon86,项目名称:oscommerce,代码行数:10,代码来源:error_log.php

示例9: __construct

 function __construct()
 {
     global $osC_Language, $osC_MessageStack;
     $this->_page_title = $osC_Language->get('heading_title');
     if (!isset($_GET['action'])) {
         $_GET['action'] = '';
     }
     if (!isset($_GET['page']) || isset($_GET['page']) && !is_numeric($_GET['page'])) {
         $_GET['page'] = 1;
     }
     if (!isset($_GET['fm'])) {
         $_GET['fm'] = '';
     }
     if (!isset($_GET['fu']) || !is_numeric($_GET['fu'])) {
         $_GET['fu'] = '';
     }
     if (!empty($_GET['action'])) {
         switch ($_GET['action']) {
             case 'info':
                 $this->_page_contents = 'info.php';
                 break;
             case 'delete':
                 $this->_page_contents = 'delete.php';
                 if (isset($_POST['subaction']) && $_POST['subaction'] == 'confirm') {
                     if (osC_AdministratorsLog_Admin::delete($_GET['lID'])) {
                         $osC_MessageStack->add($this->_module, $osC_Language->get('ms_success_action_performed'), 'success');
                     } else {
                         $osC_MessageStack->add($this->_module, $osC_Language->get('ms_error_action_not_performed'), 'error');
                     }
                     osc_redirect_admin(osc_href_link_admin(FILENAME_DEFAULT, $this->_module . '&page=' . $_GET['page'] . '&fm=' . $_GET['fm'] . '&fu=' . $_GET['fu']));
                 }
                 break;
             case 'batchDelete':
                 if (isset($_POST['batch']) && is_array($_POST['batch']) && !empty($_POST['batch'])) {
                     $this->_page_contents = 'batch_delete.php';
                     if (isset($_POST['subaction']) && $_POST['subaction'] == 'confirm') {
                         $error = false;
                         foreach ($_POST['batch'] as $id) {
                             if (!osC_AdministratorsLog_Admin::delete($id)) {
                                 $error = true;
                                 break;
                             }
                         }
                         if ($error === false) {
                             $osC_MessageStack->add($this->_module, $osC_Language->get('ms_success_action_performed'), 'success');
                         } else {
                             $osC_MessageStack->add($this->_module, $osC_Language->get('ms_error_action_not_performed'), 'error');
                         }
                         osc_redirect_admin(osc_href_link_admin(FILENAME_DEFAULT, $this->_module . '&page=' . $_GET['page'] . '&fm=' . $_GET['fm'] . '&fu=' . $_GET['fu']));
                     }
                 }
                 break;
         }
     }
 }
开发者ID:digitaldevelopers,项目名称:oscommerce,代码行数:55,代码来源:administrators_log.php

示例10: osc_redirect_admin

/**
 * Redirect to a URL address
 *
 * @param string $url The URL address to redirect to
 * @access public
 */
function osc_redirect_admin($url)
{
    if (strpos($url, "\n") !== false || strpos($url, "\r") !== false) {
        $url = osc_href_link_admin(FILENAME_DEFAULT);
    }
    if (strpos($url, '&amp;') !== false) {
        $url = str_replace('&amp;', '&', $url);
    }
    header('Location: ' . $url);
    exit;
}
开发者ID:kdexter,项目名称:oscommerce,代码行数:17,代码来源:general.php

示例11: __construct

 public function __construct()
 {
     global $osC_Language, $osC_MessageStack;
     parent::__construct();
     $this->_page_contents = 'definitions_delete.php';
     if (isset($_POST['subaction']) && $_POST['subaction'] == 'confirm') {
         if (osC_Languages_Admin::deleteDefinitions($_GET[$this->_module], $_GET['group'], array($_GET['dID']))) {
             $osC_MessageStack->add($this->_module, $osC_Language->get('ms_success_action_performed'), 'success');
         } else {
             $osC_MessageStack->add($this->_module, $osC_Language->get('ms_error_action_not_performed'), 'error');
         }
         osc_redirect_admin(osc_href_link_admin(FILENAME_DEFAULT, $this->_module . '=' . $_GET[$this->_module]) . (isset($_GET['group']) ? '&group=' . $_GET['group'] : ''));
     }
 }
开发者ID:heshuai64,项目名称:gamestore,代码行数:14,代码来源:delete_definition.php

示例12: _setData

 function _setData()
 {
     global $osC_Database, $osC_Currencies;
     $this->_data = array();
     $this->_resultset = $osC_Database->query('select o.orders_id, o.customers_name, ot.value from :table_orders o, :table_orders_total ot where o.orders_id = ot.orders_id and ot.class = :class order by value desc');
     $this->_resultset->bindTable(':table_orders', TABLE_ORDERS);
     $this->_resultset->bindTable(':table_orders_total', TABLE_ORDERS_TOTAL);
     $this->_resultset->bindValue(':class', 'total');
     $this->_resultset->setBatchLimit($_GET['page'], MAX_DISPLAY_SEARCH_RESULTS);
     $this->_resultset->execute();
     while ($this->_resultset->next()) {
         $this->_data[] = array(osc_link_object(osc_href_link_admin(FILENAME_DEFAULT, 'orders&oID=' . $this->_resultset->value('orders_id') . '&action=save'), $this->_icon . '&nbsp;' . $this->_resultset->value('customers_name')), $osC_Currencies->format($this->_resultset->valueInt('value')));
     }
 }
开发者ID:heshuai64,项目名称:gamestore,代码行数:14,代码来源:orders.php

示例13: __construct

 public function __construct()
 {
     global $osC_Language, $osC_MessageStack;
     parent::__construct();
     $this->_page_contents = 'copy.php';
     if (isset($_POST['subaction']) && $_POST['subaction'] == 'confirm') {
         if (osC_Products_Admin::copy($_GET[$this->_module], $_POST['new_category_id'], $_POST['copy_as'])) {
             $osC_MessageStack->add($this->_module, $osC_Language->get('ms_success_action_performed'), 'success');
         } else {
             $osC_MessageStack->add($this->_module, $osC_Language->get('ms_error_action_not_performed'), 'error');
         }
         osc_redirect_admin(osc_href_link_admin(FILENAME_DEFAULT, $this->_module . '&cID=' . $_GET['cID']));
     }
 }
开发者ID:digitaldevelopers,项目名称:oscommerce,代码行数:14,代码来源:copy.php

示例14: __construct

 public function __construct()
 {
     global $osC_MessageStack;
     parent::__construct();
     $this->_page_contents = 'entries_delete.php';
     if (isset($_POST['subaction']) && $_POST['subaction'] == 'confirm') {
         if (osC_ProductTypes_Admin::deleteAssignments($_GET[$this->_module], $_GET['aID'])) {
             $osC_MessageStack->add($this->_module, OSCOM::getDef('ms_success_action_performed'), 'success');
         } else {
             $osC_MessageStack->add($this->_module, OSCOM::getDef('ms_error_action_not_performed'), 'error');
         }
         osc_redirect_admin(osc_href_link_admin(FILENAME_DEFAULT, $this->_module . '=' . $_GET[$this->_module]));
     }
 }
开发者ID:digitaldevelopers,项目名称:oscommerce,代码行数:14,代码来源:entry_delete.php

示例15: __construct

 public function __construct()
 {
     global $osC_Language, $osC_MessageStack;
     parent::__construct();
     $this->_page_contents = 'delete.php';
     if (isset($_POST['subaction']) && $_POST['subaction'] == 'confirm') {
         if (osC_CreditCards_Admin::delete($_GET['ccID'])) {
             $osC_MessageStack->add($this->_module, $osC_Language->get('ms_success_action_performed'), 'success');
         } else {
             $osC_MessageStack->add($this->_module, $osC_Language->get('ms_error_action_not_performed'), 'error');
         }
         osc_redirect_admin(osc_href_link_admin(FILENAME_DEFAULT, $this->_module));
     }
 }
开发者ID:heshuai64,项目名称:gamestore,代码行数:14,代码来源:delete.php


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