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


PHP lc_href_link_admin函数代码示例

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


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

示例1: __construct

 function __construct()
 {
     global $lC_Language, $breadcrumb_string;
     $this->_page_title = $lC_Language->get('heading_title');
     $current_category_id = 0;
     if (is_numeric($_GET[$this->_module])) {
         $current_category_id = $_GET[$this->_module];
     }
     $lC_CategoryTree = new lC_CategoryTree_Admin();
     if (!isset($_GET['action'])) {
         $_GET['action'] = '';
     }
     // check if the categories image directory exists
     if (is_dir('../images/categories')) {
         if (!is_writeable('../images/categories')) {
             $_SESSION['error'] = true;
             $_SESSION['errmsg'] = sprintf($lC_Language->get('ms_error_image_directory_not_writable'), realpath('../images/categories'));
         }
     } else {
         $_SESSION['error'] = true;
         $_SESSION['errmsg'] = sprintf($lC_Language->get('ms_error_image_directory_non_existant'), realpath('../images/categories'));
     }
     // setup the breadcrumb
     $breadcrumb_array = array(lc_link_object(lc_href_link_admin(FILENAME_DEFAULT, $this->_module), $lC_Language->get('text_top')));
     foreach ($lC_CategoryTree->getPathArray($current_category_id) as $category) {
         $breadcrumb_array[] = lc_link_object(lc_href_link_admin(FILENAME_DEFAULT, $this->_module . '=' . $category['id']), $category['name']);
     }
     $breadcrumb_string = '<ul>';
     foreach ($breadcrumb_array as $key => $value) {
         $breadcrumb_string .= '<li>' . $value . '</li>';
     }
     $breadcrumb_string .= '</ul>';
 }
开发者ID:abhiesa-tolexo,项目名称:loaded7,代码行数:33,代码来源:categories.php

示例2: __construct

 public function __construct()
 {
     global $lC_Language, $lC_MessageStack;
     parent::__construct();
     $this->_page_contents = 'edit.php';
     if (isset($_POST['subaction']) && $_POST['subaction'] == 'confirm') {
         switch ($_GET['action']) {
             case 'save':
                 $data = array('oid' => $_POST['oid'], 'status' => $_POST['status'], 'comment' => $_POST['comment'], 'notify_customer' => isset($_POST['notify_customer']) && $_POST['notify_customer'] == 1 ? true : false, 'append_comment' => isset($_POST['append_comment']) && $_POST['append_comment'] == 1 ? true : false);
                 /*
                  * Update the order status
                  *
                  * @param integer $data['oid'] The orders id used on status update
                  * @param array $data The order status information
                  * @access public
                  * @return boolean
                  */
                 if (lC_Orders_Admin::updateStatus($data['oid'], $data)) {
                     lc_redirect_admin(lc_href_link_admin(FILENAME_DEFAULT, $this->_module . '=' . $data['oid'] . '&action=save'));
                 } else {
                     $_SESSION['error'] = true;
                     $_SESSION['errmsg'] = $lC_Language->get('ms_error_action_not_performed');
                 }
                 break;
         }
     }
 }
开发者ID:abhiesa-tolexo,项目名称:loaded7,代码行数:27,代码来源:save.php

示例3: __construct

 public function __construct()
 {
     global $lC_Language, $lC_Statistics, $lC_Vqmod, $breadcrumb_string;
     $this->_page_title = $lC_Language->get('heading_title');
     if (!isset($_GET['module'])) {
         $_GET['module'] = '';
     }
     if (!empty($_GET['module']) && !file_exists('includes/modules/statistics/' . $_GET['module'] . '.php')) {
         $_GET['module'] = '';
     }
     if (empty($_GET['module'])) {
         $this->_page_contents = 'listing.php';
     } else {
         include_once $lC_Vqmod->modCheck('includes/modules/statistics/' . $_GET['module'] . '.php');
         $class = 'lC_Statistics_' . str_replace(' ', '_', ucwords(str_replace('_', ' ', $_GET['module'])));
         $lC_Statistics = new $class();
         $lC_Statistics->activate();
         $breadcrumb_array = array(lc_link_object(lc_href_link_admin(FILENAME_DEFAULT, $this->_module), $lC_Language->get('heading_title')));
         $breadcrumb_array[] = lc_link_object(lc_href_link_admin(FILENAME_DEFAULT, $this->_module . '&module=' . $_GET['module']), $lC_Statistics->getTitle());
         $breadcrumb_string = '<ul>';
         foreach ($breadcrumb_array as $key => $value) {
             $breadcrumb_string .= '<li>' . $value . '</li>';
         }
         $breadcrumb_string .= '</ul>';
     }
 }
开发者ID:abhiesa-tolexo,项目名称:loaded7,代码行数:26,代码来源:statistics.php

示例4: __construct

 public function __construct()
 {
     global $lC_Database, $lC_Language, $lC_MessageStack;
     parent::__construct();
     if (isset($_SESSION['img_resize_flag'])) {
         unset($_SESSION['img_resize_flag']);
     }
     if (!empty($_POST['user_name']) && !empty($_POST['user_password'])) {
         $Qadmin = $lC_Database->query('select * from :table_administrators where user_name = :user_name');
         $Qadmin->bindTable(':table_administrators', TABLE_ADMINISTRATORS);
         $Qadmin->bindValue(':user_name', $_POST['user_name']);
         $Qadmin->execute();
         if ($Qadmin->numberOfRows() > 0) {
             if (lc_validate_password($_POST['user_password'], $Qadmin->value('user_password'))) {
                 $_SESSION['admin'] = array('id' => $Qadmin->valueInt('id'), 'firstname' => $Qadmin->value('first_name'), 'lastname' => $Qadmin->value('last_name'), 'username' => $Qadmin->value('user_name'), 'password' => $Qadmin->value('user_password'), 'access' => lC_Access::getUserLevels($Qadmin->valueInt('access_group_id')), 'language_id' => $Qadmin->value('language_id'));
                 $get_string = null;
                 if (isset($_SESSION['redirect_origin'])) {
                     $get_string = http_build_query($_SESSION['redirect_origin']['get']);
                     if (substr($get_string, -1) == '=') {
                         $get_string = substr($get_string, 0, -1);
                     }
                     unset($_SESSION['redirect_origin']);
                 }
                 if (defined('INSTALLATION_ID') && INSTALLATION_ID != NULL) {
                     lc_redirect_admin(lc_href_link_admin(FILENAME_DEFAULT, $get_string));
                 } else {
                     // redirect to login=register
                     lc_redirect_admin(lc_href_link_admin(FILENAME_DEFAULT, 'login&action=register'));
                 }
             }
         }
     }
     $_SESSION['error'] = true;
     $_SESSION['errmsg'] = $lC_Language->get('ms_error_login_invalid');
 }
开发者ID:abhiesa-tolexo,项目名称:loaded7,代码行数:35,代码来源:process.php

示例5: getAll

 public static function getAll()
 {
     global $lC_Language;
     $media = $_GET['media'];
     $lC_DirectoryListing = new lC_DirectoryListing(DIR_FS_BACKUP);
     $lC_DirectoryListing->setIncludeDirectories(false);
     $lC_DirectoryListing->setCheckExtension('zip');
     $lC_DirectoryListing->setCheckExtension('sql');
     $lC_DirectoryListing->setCheckExtension('gz');
     $cnt = 0;
     $result = array('aaData' => array());
     foreach ($lC_DirectoryListing->getFiles() as $file) {
         $downloadLink = lc_href_link_admin(FILENAME_DEFAULT, 'backup&action=download&file=' . $file['name']);
         $check = '<td><input class="batch" type="checkbox" name="batch[]" value="' . $file['name'] . '" id="' . $file['name'] . '"></td>';
         $filename = '<td><a href="' . $downloadLink . '"><span class="icon-download icon-orange with-tooltip" title="' . $lC_Language->icon_download . '">&nbsp;' . $file['name'] . '</a></td>';
         $date = '<td>' . lC_DateTime::getShort(lC_DateTime::fromUnixTimestamp(@filemtime(DIR_FS_BACKUP . $file['name'])), true) . '</td>';
         $size = '<td>' . number_format(@filesize(DIR_FS_BACKUP . $file['name'])) . '</td>';
         $action = '<td class="align-right vertical-center"><span class="button-group compact">
   <a href="' . ((int) ($_SESSION['admin']['access']['backup'] < 3) ? '#' : 'javascript://" onclick="restoreEntry(\'' . $file['name'] . '\')') . '" class="button icon-pencil' . ((int) ($_SESSION['admin']['access']['backup'] < 3) ? ' disabled' : NULL) . '">' . ($media === 'mobile-portrait' || $media === 'mobile-landscape' ? NULL : $lC_Language->get('icon_restore')) . '</a>
   <a href="' . ((int) ($_SESSION['admin']['access']['backup'] < 4) ? '#' : 'javascript://" onclick="deleteEntry(\'' . $file['name'] . '\', \'' . urlencode($file['name']) . '\')') . '" class="button icon-trash with-tooltip' . ((int) ($_SESSION['admin']['access']['backup'] < 4) ? ' disabled' : NULL) . '" title="' . $lC_Language->get('icon_delete') . '"></a>
   </span></td>';
         $result['aaData'][] = array("{$check}", "{$filename}", "{$date}", "{$size}", "{$action}");
         $cnt++;
     }
     $result['total'] = $cnt;
     return $result;
 }
开发者ID:rajeshb001,项目名称:itpl_loaded7,代码行数:27,代码来源:backup.php

示例6: getAll

 /**
  * Returns the featured products datatable data for listings
  *
  * @access public
  * @return array
  */
 public static function getAll()
 {
     global $lC_Database, $lC_Language, $lC_Currencies, $_module;
     $media = $_GET['media'];
     $Qfeatured = $lC_Database->query('select * from :table_featured_products');
     $Qfeatured->bindTable(':table_featured_products', TABLE_FEATURED_PRODUCTS);
     $Qfeatured->execute();
     $result = array('aaData' => array());
     while ($Qfeatured->next()) {
         $Qname = $lC_Database->query('select products_name from :table_products_description where products_id = :products_id');
         $Qname->bindTable(':table_products_description', TABLE_PRODUCTS_DESCRIPTION);
         $Qname->bindInt(':products_id', $Qfeatured->value('products_id'));
         $Qname->execute();
         $check = '<td><input class="batch" type="checkbox" name="batch[]" value="' . $Qfeatured->valueInt('id') . '" id="' . $Qfeatured->valueInt('id') . '"></td>';
         $name = '<td>' . $Qname->value('products_name') . '</td>';
         $expires = '<td><span' . (date("Y-m-d H:i:s") > $Qfeatured->value('expires_date') && $Qfeatured->value('expires_date') != '0000-00-00 00:00:00' ? ' class="red bold with-tooltip" title="' . $lC_Language->get('text_featured_product_expired') . '"' : '') . '>' . ($Qfeatured->value('expires_date') != '0000-00-00 00:00:00' ? lC_DateTime::getShort($Qfeatured->value('expires_date')) : $lC_Language->get('text_featured_product_no_expiration')) . '</span></td>';
         $status = '<td><span id="status_' . $Qfeatured->value('id') . '" onclick="updateStatus(\'' . $Qfeatured->valueInt('id') . '\', \'' . ($Qfeatured->valueInt('status') == 1 ? -1 : 1) . '\');">' . ($Qfeatured->valueInt('status') == 1 ? '<span class="icon-tick icon-size2 icon-green cursor-pointer with-tooltip" title="' . $lC_Language->get('text_disable') . '"></span>' : '<span class="icon-cross icon-size2 icon-red cursor-pointer with-tooltip" title="' . $lC_Language->get('text_enable') . '"></span>') . '</span></td>';
         $action = '<td class="align-right vertical-center">
                <span class="button-group">
                  <a href="' . ((int) ($_SESSION['admin']['access'][$_module] < 3) ? '#' : lc_href_link_admin(FILENAME_DEFAULT, $_module . '=' . $Qfeatured->valueInt('id') . '&action=save')) . '" class="button icon-pencil' . ((int) ($_SESSION['admin']['access'][$_module] < 3) ? ' disabled' : NULL) . '">' . ($media === 'mobile-portrait' || $media === 'mobile-landscape' ? NULL : $lC_Language->get('icon_edit')) . '</a>
                </span>
                <span class="button-group">
                  <a href="' . ((int) ($_SESSION['admin']['access'][$_module] < 4) ? '#' : 'javascript://" onclick="deleteFeaturedProduct(\'' . $Qfeatured->valueInt('id') . '\', \'' . $Qname->value('products_name') . '\')') . '" class="button icon-trash with-tooltip' . ((int) ($_SESSION['admin']['access'][$_module] < 4) ? ' disabled' : NULL) . '" title="' . $lC_Language->get('icon_delete') . '"></a>
                </span>
              </td>';
         $result['aaData'][] = array("{$check}", "{$name}", "{$expires}", "{$status}", "{$action}");
     }
     $Qfeatured->freeResult;
     return $result;
 }
开发者ID:abhiesa-tolexo,项目名称:loaded7,代码行数:36,代码来源:featured_products.php

示例7: getAll

 public static function getAll()
 {
     global $_module, $lC_Database, $lC_Language;
     $media = $_GET['media'];
     $Qgroups = $lC_Database->query('select id, title, sort_order from :table_products_variants_groups where languages_id = :languages_id order by sort_order, title');
     $Qgroups->bindTable(':table_products_variants_groups', TABLE_PRODUCTS_VARIANTS_GROUPS);
     $Qgroups->bindInt(':languages_id', $lC_Language->getID());
     $Qgroups->execute();
     $result = array('aaData' => array());
     while ($Qgroups->next()) {
         $Qentries = $lC_Database->query('select count(*) as total from :table_products_variants_values where products_variants_groups_id = :products_variants_groups_id and  languages_id = :languages_id');
         $Qentries->bindTable(':table_products_variants_values', TABLE_PRODUCTS_VARIANTS_VALUES);
         $Qentries->bindInt(':products_variants_groups_id', $Qgroups->valueInt('id'));
         $Qentries->bindInt(':languages_id', $lC_Language->getID());
         $Qentries->execute();
         $check = '<td><input class="batch" type="checkbox" name="batch[]" value="' . $Qgroups->valueInt('id') . '" id="' . $Qgroups->valueInt('id') . '"></td>';
         $group = '<td>' . lc_link_object(lc_href_link_admin(FILENAME_DEFAULT, $_module . '=' . $Qgroups->valueInt('id')), '<span class="icon-folder icon-orange"></span>&nbsp;' . $Qgroups->value('title')) . '</td>';
         $total = '<td>' . $Qentries->valueInt('total') . '</td>';
         $sort = '<td>' . $Qgroups->valueInt('sort_order') . '</td>';
         $action = '<td class="align-right vertical-center">
                <span class="button-group">
                  <a href="' . ((int) ($_SESSION['admin']['access']['product_variants'] < 3) ? '#' : 'javascript://" onclick="editGroup(\'' . $Qgroups->valueInt('id') . '\')') . '" class="button icon-pencil ' . ((int) ($_SESSION['admin']['access']['product_variants'] < 3) ? 'disabled' : NULL) . '">' . ($media === 'mobile-portrait' || $media === 'mobile-landscape' ? NULL : $lC_Language->get('icon_edit')) . '</a>
                </span>
                <span class="button-group">
                  <a href="' . ((int) ($_SESSION['admin']['access']['product_variants'] < 4) ? '#' : 'javascript://" onclick="deleteGroup(\'' . $Qgroups->valueInt('id') . '\', \'' . urlencode($Qgroups->valueProtected('title')) . '\');') . '" class="button icon-trash with-tooltip' . ((int) ($_SESSION['admin']['access']['product_variants'] < 4) ? 'disabled' : NULL) . '" title="' . $lC_Language->get('icon_delete') . '"></a>
                </span>
              </td>';
         $result['aaData'][] = array("{$check}", "{$group}", "{$total}", "{$sort}", "{$action}");
         $Qentries->freeResult();
     }
     $Qgroups->freeResult();
     return $result;
 }
开发者ID:rajeshb001,项目名称:itpl_loaded7,代码行数:33,代码来源:product_variants.php

示例8: __construct

 function __construct()
 {
     global $lC_Language, $lC_MessageStack;
     $this->_page_title = $lC_Language->get('heading_title');
     if (!isset($_GET['action'])) {
         $_GET['action'] = '';
     }
     // check if the graphs directory exists
     $_SESSION['errArr'] = array();
     if (!empty($_GET['action']) && !$_SESSION['error']) {
         switch ($_GET['action']) {
             case 'save':
                 //echo '<pre>';print_r($_POST);exit;
                 $shipping_name = serialize($_POST['ups']);
                 $data = array('title' => $_POST['title'], 'shipping_name' => $shipping_name);
                 /*
                  * Save the banner information
                  *
                  * @param integer $_GET['bid'] The banner id
                  * @param array $data The banner information
                  * @access public
                  * @return boolean
                  */
                 if (lC_Restrict_shipping_Admin::save(isset($_GET['bid']) && is_numeric($_GET['bid']) ? $_GET['bid'] : null, $data)) {
                     lc_redirect_admin(lc_href_link_admin(FILENAME_DEFAULT, $this->_module));
                 } else {
                     $_SESSION['error'] = true;
                     $_SESSION['errmsg'] = $lC_Language->get('ms_error_action_not_performed');
                 }
                 break;
         }
     }
 }
开发者ID:rajeshb001,项目名称:itpl_loaded7,代码行数:33,代码来源:restrict_shipping.php

示例9: __construct

 public function __construct()
 {
     global $lC_Database, $lC_Language, $lC_MessageStack, $rInfo;
     parent::__construct();
     if (!isset($_SESSION['verify_key_valid']) || $_SESSION['verify_key_valid'] === false) {
         lc_redirect_admin(lc_href_link_admin(FILENAME_DEFAULT, $this->_module));
     }
 }
开发者ID:abhiesa-tolexo,项目名称:loaded7,代码行数:8,代码来源:password_change.php

示例10: getAll

 public static function getAll()
 {
     global $lC_Language;
     if (!defined('LC_ADMIN_FILE_MANAGER_ROOT_PATH')) {
         define('LC_ADMIN_FILE_MANAGER_ROOT_PATH', substr(DIR_FS_CATALOG, 0, -1));
     }
     $media = $_GET['media'];
     $goto_array = array(array('id' => '', 'text' => $lC_Language->get('top_level')));
     if ($_SESSION['fm_directory'] != LC_ADMIN_FILE_MANAGER_ROOT_PATH) {
         $path_array = explode('/', substr($_SESSION['fm_directory'], strlen(LC_ADMIN_FILE_MANAGER_ROOT_PATH) + 1));
         foreach ($path_array as $value) {
             if (sizeof($goto_array) < 2) {
                 $goto_array[] = array('id' => $value, 'text' => $value);
             } else {
                 $parent = end($goto_array);
                 $goto_array[] = array('id' => $parent['id'] . '/' . $value, 'text' => $parent['id'] . '/' . $value);
             }
         }
     }
     $lC_DirectoryListing = new lC_DirectoryListing($_SESSION['fm_directory']);
     $lC_DirectoryListing->setStats(true);
     $result = array('aaData' => array());
     if ($_SESSION['fm_directory'] != LC_ADMIN_FILE_MANAGER_ROOT_PATH) {
         $files = '<td>' . lc_link_object(lc_href_link_admin(FILENAME_DEFAULT, 'file_manager&goto=' . $goto_array[sizeof($goto_array) - 2]['id']), '<span class="icon-up-fat icon-blue">&nbsp;' . $lC_Language->get('parent_level')) . '</td>';
         $result['aaData'][] = array("{$files}", "", "", "", "", "", "", "");
     }
     $cnt = 0;
     foreach ($lC_DirectoryListing->getFiles() as $file) {
         $file_owner = posix_getpwuid($file['user_id']);
         $group_owner = posix_getgrgid($file['group_id']);
         if ($file['is_directory'] === true) {
             $entry_url = lc_href_link_admin(FILENAME_DEFAULT, 'file_manager&directory=' . $file['name']);
             $files = '<td>' . lc_link_object($entry_url, '<span class="icon-folder icon-orange">&nbsp;' . $file['name']) . '</td>';
         } else {
             $entry_url = lc_href_link_admin(FILENAME_DEFAULT, 'file_manager&entry=' . $file['name'] . '&action=save');
             $files = '<td><a href="javascript:void(0);" onclick="editEntry(\'' . $file['name'] . '\')">' . '<span class="icon-page-list icon-blue">&nbsp;' . $file['name'] . '</a></td>';
         }
         $size = '<td>' . number_format($file['size']) . '</td>';
         $perms = '<td>' . lc_get_file_permissions($file['permissions']) . '</td>';
         $user = '<td>' . $file_owner['name'] . '</td>';
         $group = '<td>' . $group_owner['name'] . '</td>';
         $write = '<td>' . is_writable($lC_DirectoryListing->getDirectory() . '/' . $file['name']) ? '<span class="icon-tick icon-green">' : '<span class="icon-cross icon-red">' . '</td>';
         $last = '<td>' . lC_DateTime::getShort(@date('Y-m-d H:i:s', $file['last_modified']), true) . '</td>';
         if ($file['is_directory'] === false) {
             $action_links = '<a href="' . ((int) ($_SESSION['admin']['access']['file_manager'] < 3) ? '#' : 'javascript://" onclick="editEntry(\'' . $file['name'] . '\')') . '" class="button icon-pencil' . ((int) ($_SESSION['admin']['access']['file_manager'] < 3) ? ' disabled' : NULL) . '">' . ($media === 'mobile-portrait' || $media === 'mobile-landscape' ? NULL : $lC_Language->get('icon_edit')) . '</a>' . '<a href="' . ((int) ($_SESSION['admin']['access']['file_manager'] < 2) ? '#' : lc_href_link_admin(FILENAME_DEFAULT, 'file_manager&entry=' . $file['name'] . '&action=download')) . '" class="button icon-download with-tooltip' . ((int) ($_SESSION['admin']['access']['file_manager'] < 2) ? ' disabled' : NULL) . '" title="' . $lC_Language->get('icon_download') . '"></a>' . '<a href="' . ((int) ($_SESSION['admin']['access']['file_manager'] < 4) ? '#' : 'javascript://" onclick="deleteEntry(\'' . $file['name'] . '\', \'' . urlencode($file['name']) . '\')"') . '" class="button icon-trash with-tooltip' . ((int) ($_SESSION['admin']['access']['file_manager'] < 4) ? ' disabled' : NULL) . '" title="' . $lC_Language->get('icon_delete') . '"></a>';
         } else {
             $action_links = '<a href="' . ((int) ($_SESSION['admin']['access']['file_manager'] < 4) ? '#' : 'javascript://" onclick="deleteEntry(\'' . $file['name'] . '\', \'' . urlencode($file['name']) . '\')"') . '" class="button icon-trash' . ((int) ($_SESSION['admin']['access']['file_manager'] < 4) ? ' disabled' : NULL) . '" title="' . $lC_Language->get('icon_delete') . '"></a>';
         }
         $action = '<td class="align-right vertical-center"><span class="button-group compact">
                ' . $action_links . '
              </span></td>';
         $result['aaData'][] = array("{$files}", "{$size}", "{$perms}", "{$user}", "{$group}", "{$write}", "{$last}", "{$action}");
         $cnt++;
     }
     $result['total'] = $cnt;
     return $result;
 }
开发者ID:abhiesa-tolexo,项目名称:loaded7,代码行数:57,代码来源:file_manager.php

示例11: __construct

 public function __construct()
 {
     global $lC_Language;
     $lC_Language->loadIniFile('modules/summary/revenue.php');
     $this->_title = $lC_Language->get('summary_revenue_title');
     $this->_title_link = lc_href_link_admin(FILENAME_DEFAULT, 'revenue');
     if (lC_Access::hasAccess('orders')) {
         $this->_setData();
     }
 }
开发者ID:abhiesa-tolexo,项目名称:loaded7,代码行数:10,代码来源:revenue.php

示例12: __construct

 public function __construct()
 {
     global $lC_Language, $lC_MessageStack;
     parent::__construct();
     unset($_SESSION['admin']);
     if (isset($_SESSION['img_resize_flag'])) {
         unset($_SESSION['img_resize_flag']);
     }
     lc_redirect_admin(lc_href_link_admin(FILENAME_DEFAULT));
 }
开发者ID:rajeshb001,项目名称:itpl_loaded7,代码行数:10,代码来源:logoff.php

示例13: __construct

 public function __construct()
 {
     global $lC_Language;
     $lC_Language->loadIniFile('modules/summary/administrators_log.php');
     $lC_Language->loadIniFile('administrators_log.php');
     $this->_title = $lC_Language->get('summary_administrators_log_title');
     $this->_title_link = lc_href_link_admin(FILENAME_DEFAULT, 'administrators_log');
     if (lC_Access::hasAccess('administrators_log')) {
         $this->_setData();
     }
 }
开发者ID:abhiesa-tolexo,项目名称:loaded7,代码行数:11,代码来源:administrators_log.php

示例14: __construct

 public function __construct()
 {
     global $lC_Language, $lC_MessageStack, $lC_Currencies, $lC_DateTime;
     parent::__construct();
     $this->_page_contents = 'edit.php';
     if (isset($_POST['subaction']) && $_POST['subaction'] == 'confirm') {
         // validate the input
         $type = isset($_POST['type']) && $_POST['type'] != NULL ? preg_replace('/[^A-Z\\s]/', '', $_POST['type']) : 'R';
         $name = isset($_POST['name']) && $_POST['name'] != NULL ? preg_replace('/[^A-Za-z0-9\\s]/', '', $_POST['name']) : NULL;
         $reward = isset($_POST['reward']) && $_POST['reward'] != NULL ? preg_replace('/[^0-9\\s\\.\\%]/', '', $_POST['reward']) : 0.0;
         $mode = isset($_POST['mode']) && $_POST['mode'] != NULL ? preg_replace('/[^a-z\\s]/', '', $_POST['mode']) : 'coupon';
         $code = isset($_POST['code']) && $_POST['code'] != NULL ? preg_replace('/[^A-Za-z0-9\\s]/', '', $_POST['code']) : substr(str_shuffle(str_repeat('ABCEFGHJKLMNPRSTUVWXYZabcdefghjklmnpqrstuvwxyz23456789', 7)), 0, 7);
         $purchase_over = isset($_POST['purchase_over']) && $_POST['purchase_over'] != NULL ? preg_replace('/[^0-9\\s\\.\\%]/', '', $_POST['purchase_over']) : 0.0;
         $start_date = isset($_POST['start_date']) && $_POST['start_date'] != NULL ? preg_replace('/[^0-9\\s\\/]/', '', $_POST['start_date']) : NULL;
         $expires_date = isset($_POST['expires_date']) && $_POST['expires_date'] != NULL ? preg_replace('/[^0-9\\s\\/]/', '', $_POST['expires_date']) : NULL;
         $uses_per_coupon = isset($_POST['uses_per_coupon']) && $_POST['uses_per_coupon'] != NULL ? preg_replace('/[^0-9\\s]/', '', $_POST['uses_per_coupon']) : 1;
         $uses_per_customer = isset($_POST['uses_per_customer']) && $_POST['uses_per_customer'] != NULL ? preg_replace('/[^0-9\\s]/', '', $_POST['uses_per_customer']) : 1;
         $restrict_to_products = isset($_POST['restrict_to_products']) && $_POST['restrict_to_products'] != NULL ? preg_replace('/[^0-9\\s]/', '', $_POST['restrict_to_products']) : -1;
         $restrict_to_categories = isset($_POST['restrict_to_categories']) && $_POST['restrict_to_categories'] != NULL ? preg_replace('/[^0-9\\s]/', '', $_POST['restrict_to_categories']) : -1;
         $restrict_to_customers = isset($_POST['restrict_to_customers']) && $_POST['restrict_to_customers'] != NULL ? preg_replace('/[^0-9\\s]/', '', $_POST['restrict_to_customers']) : -1;
         $status = isset($_POST['status']) && $_POST['status'] == 'on' ? 1 : -1;
         $sale_exclude = isset($_POST['sale_exclude']) && $_POST['sale_exclude'] == 'on' ? 1 : -1;
         $notes = isset($_POST['notes']) && $_POST['notes'] != NULL ? preg_replace('/[^a-zA-Z0-9\\s\\.\\%\\,]/', '', $_POST['notes']) : NULL;
         switch ($type) {
             case 'R':
                 // regular
             // regular
             case 'T':
                 // percent
                 if (strstr($reward, '%')) {
                     $type = 'T';
                 }
                 break;
             case 'S':
                 // free shipping
                 break;
             case 'P':
                 // free product
                 break;
         }
         $data = array('name' => $name, 'type' => $type, 'mode' => $mode, 'code' => $code, 'reward' => str_replace("%", "", $reward), 'purchase_over' => $purchase_over, 'start_date' => $start_date, 'expires_date' => $expires_date, 'uses_per_coupon' => $uses_per_coupon, 'uses_per_customer' => $uses_per_customer, 'restrict_to_products' => $restrict_to_products, 'restrict_to_categories' => $restrict_to_categories, 'restrict_to_customers' => $restrict_to_customers, 'status' => $status, 'sale_exclude' => $sale_exclude, 'notes' => $notes);
         $id = lC_Coupons_Admin::save(isset($_GET[$this->_module]) && is_numeric($_GET[$this->_module]) ? $_GET[$this->_module] : null, $data);
         if (is_numeric($id) && isset($id)) {
             if (!empty($_POST['save_close'])) {
                 lc_redirect_admin(lc_href_link_admin(FILENAME_DEFAULT, $this->_module));
             } else {
                 lc_redirect_admin(lc_href_link_admin(FILENAME_DEFAULT, $this->_module . '=' . $id . '&action=save'));
             }
         } else {
             $lC_MessageStack->add($this->_module, $lC_Language->get('ms_error_action_not_performed'), 'error');
             lc_redirect_admin(lc_href_link_admin(FILENAME_DEFAULT, $this->_module));
         }
     }
 }
开发者ID:abhiesa-tolexo,项目名称:loaded7,代码行数:54,代码来源:save.php

示例15: __construct

 function __construct()
 {
     global $lC_Language;
     $this->_page_title = $lC_Language->get('heading_title');
     if (!isset($_GET['action'])) {
         $_GET['action'] = '';
     }
     if (!empty($_GET['action']) && !$_SESSION['error']) {
         switch ($_GET['action']) {
             case 'save':
                 $branding_image = $_POST['branding_manager_logo'];
                 $branding_name = $_POST['branding_name'];
                 $branding_slogan = $_POST['branding_slogan'];
                 $branding_chat_code = $_POST['branding_chat_code'];
                 $branding_address = $_POST['branding_address'];
                 $branding_support_phone = $_POST['branding_support_phone'];
                 $branding_support_email = $_POST['branding_support_email'];
                 $branding_sales_phone = $_POST['branding_sales_phone'];
                 $branding_sales_email = $_POST['branding_sales_email'];
                 $branding_meta_description = $_POST['branding_meta_description'];
                 $branding_meta_keywords = $_POST['branding_meta_keywords'];
                 $branding_graph_site_thumbnail = $_POST['branding_graph_site_thumbnail'];
                 $branding_meta_title = $_POST['branding_meta_title'];
                 $branding_meta_title_prefix = $_POST['branding_meta_title_prefix'];
                 $branding_meta_title_suffix = $_POST['branding_meta_title_suffix'];
                 $branding_meta_title_delimeter = $_POST['branding_meta_title_delimeter'];
                 $branding_social_fb_page = $_POST['branding_social_fb_page'];
                 $branding_social_twitter = $_POST['branding_social_twitter'];
                 $branding_social_pinterest = $_POST['branding_social_pinterest'];
                 $branding_social_google_plus = $_POST['branding_social_google_plus'];
                 $branding_social_youtube = $_POST['branding_social_youtube'];
                 $branding_social_linkedin = $_POST['branding_social_linkedin'];
                 $branding_footer_text = $_POST['branding_footer_text'];
                 $branding_home_page_text = $_POST['branding_home_page_text'];
                 $branding_customcss = $_POST['branding_customcss'];
                 $data = array('site_image' => $branding_image, 'name' => $branding_name, 'slogan' => $branding_slogan, 'chat_code' => $branding_chat_code, 'address' => $branding_address, 'support_phone' => $branding_support_phone, 'support_email' => $branding_support_email, 'sales_phone' => $branding_sales_phone, 'sales_email' => $branding_sales_email, 'meta_description' => $branding_meta_description, 'meta_keywords' => $branding_meta_keywords, 'og_image' => $branding_graph_site_thumbnail, 'meta_title' => $branding_meta_title, 'meta_title_prefix' => $branding_meta_title_prefix, 'meta_title_suffix' => $branding_meta_title_suffix, 'meta_delimeter' => $branding_meta_title_delimeter, 'social_facebook_page' => $branding_social_fb_page, 'social_twitter' => $branding_social_twitter, 'social_pinterest' => $branding_social_pinterest, 'social_google_plus' => $branding_social_google_plus, 'social_youtube' => $branding_social_youtube, 'social_linkedin' => $branding_social_linkedin, 'footer_text' => $branding_footer_text, 'home_page_text' => $branding_home_page_text, 'custom_css' => $branding_customcss);
                 /*
                  * Save the Branding information
                  *
                  * @param array $data The Branding information
                  * @access public
                  * @return boolean
                  */
                 if (lC_Branding_manager_Admin::save($data)) {
                     lc_redirect_admin(lc_href_link_admin(FILENAME_DEFAULT, $this->_module));
                 } else {
                     $_SESSION['error'] = true;
                     $_SESSION['errmsg'] = $lC_Language->get('ms_error_action_not_performed');
                 }
                 break;
         }
     }
 }
开发者ID:abhiesa-tolexo,项目名称:loaded7,代码行数:53,代码来源:branding_manager.php


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