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


PHP CI::view方法代码示例

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


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

示例1: load

 function load()
 {
     $plugin_name = $this->uri->segment(4);
     $this->template['functionName'] = strtolower(__FUNCTION__);
     $this->template['pluginName'] = $plugin_name;
     $this->load->vars($this->template);
     $layout = CI::view('admin/layout', true, true);
     $primarycontent = '';
     $secondarycontent = '';
     $plugindata = CI::model('core')->plugins_getPluginConfig($plugin_name);
     //
     //print  PLUGINS_DIRNAME . $dirname .$plugin_name.'/'.$plugindata['plugin_admin_dir']. '/controller.php' ;
     if (is_file(PLUGINS_DIRNAME . $dirname . $plugin_name . '/' . $plugindata['plugin_admin_dir'] . '/controller.php') == true) {
         $firecms = get_instance();
         define('THIS_PLUGIN_URL', site_url('admin/plugins/load') . '/' . $plugin_name . '/');
         define('THIS_PLUGIN_DIRNAME', PLUGINS_DIRNAME . $dirname . $plugin_name . '/');
         define('THIS_PLUGIN_DIRNAME_ADMIN', PLUGINS_DIRNAME . $dirname . $plugin_name . '/' . $plugindata['plugin_admin_dir'] . '/');
         require_once PLUGINS_DIRNAME . $dirname . $plugin_name . '/' . $plugindata['plugin_admin_dir'] . '/controller.php';
     }
     //$primarycontent = CI::view ( 'admin/comments/index', true, true );
     //$secondarycontent = CI::view ( 'admin/content/sidebar', true, true );
     $layout = str_ireplace('{primarycontent}', $primarycontent, $layout);
     $layout = str_ireplace('{secondarycontent}', $secondarycontent, $layout);
     //CI::view('welcome_message');
     CI::library('output')->set_output($layout);
 }
开发者ID:Gninety,项目名称:Microweber,代码行数:26,代码来源:plugins.php

示例2: edit

 function edit()
 {
     $this->template['functionName'] = strtolower(__FUNCTION__);
     $this->load->vars($this->template);
     if ($_POST) {
         $save = $this->cacaomail_model->saveMailAccounts($_POST);
         redirect('mailaccounts');
     }
     $segs = $this->uri->segment_array();
     $the_id = false;
     foreach ($segs as $segment) {
         if (stristr($segment, 'id:') == true) {
             $the_id = $segment;
             $the_id = substr($the_id, 3, strlen($the_id));
         }
     }
     if (intval($the_id) != 0) {
         $form_values = $this->cacaomail_model->getMailAccounts(array('id' => $the_id), 1);
         $form_values = $form_values[0];
         $this->template['form_values'] = $form_values;
     } else {
         //$this->template ['form_values'] = false;
     }
     $this->template['form_values']['account_groups'] = $this->cacaomail_model->getMailAccountsGroups();
     $this->load->vars($this->template);
     $layout = CI::view('layout', true, true);
     $primarycontent = '';
     $secondarycontent = '';
     $primarycontent = CI::view('mailaccounts/edit', true, true);
     $secondarycontent = CI::view('mailaccounts/sidebar', true, true);
     $layout = str_ireplace('{primarycontent}', $primarycontent, $layout);
     $layout = str_ireplace('{secondarycontent}', $secondarycontent, $layout);
     //CI::view('welcome_message');
     CI::library('output')->set_output($layout);
 }
开发者ID:Gninety,项目名称:Microweber,代码行数:35,代码来源:mailaccounts.php

示例3: index

 function index()
 {
     $this->template['functionName'] = strtolower(__FUNCTION__);
     $data = array();
     $data['is_moderated'] = 'n';
     $form_values = CI::model('comments')->commentsGet($data);
     $this->template['new_comments'] = $form_values;
     $this->load->vars($this->template);
     $data = array();
     $data['is_moderated'] = 'y';
     $limit[0] = 0;
     $limit[1] = 100;
     $form_values = CI::model('comments')->commentsGet($data);
     $this->template['old_comments'] = $form_values;
     $this->load->vars($this->template);
     $this->load->vars($this->template);
     $layout = CI::view('admin/layout', true, true);
     $primarycontent = '';
     $secondarycontent = '';
     $primarycontent = CI::view('admin/comments/index', true, true);
     //$secondarycontent = CI::view ( 'admin/content/sidebar', true, true );
     $layout = str_ireplace('{primarycontent}', $primarycontent, $layout);
     $layout = str_ireplace('{secondarycontent}', $secondarycontent, $layout);
     //CI::view('welcome_message');
     CI::library('output')->set_output($layout);
 }
开发者ID:Gninety,项目名称:Microweber,代码行数:26,代码来源:comments.php

示例4: register

 function register()
 {
     $this->template['functionName'] = strtolower(__FUNCTION__);
     $rules['username'] = "trim|required|xss_clean|callback_username_check";
     $rules['password'] = "trim|required|matches[passconf]";
     $rules['passconf'] = "trim|required";
     $rules['email'] = "trim|required|valid_email|xss_clean|callback_useremail_check";
     $rules['accept'] = "callback_acceptterms_check|required|xss_clean";
     $rules['captcha'] = "callback_captcha_check|required|xss_clean";
     $this->validation->set_rules($rules);
     $fields['username'] = 'Username';
     $fields['password'] = 'Password';
     $fields['passconf'] = 'Password Confirmation';
     $fields['email'] = 'Email Address';
     //$fields ['accept'] = 'Please accept the Terms and Conditions';
     $this->validation->set_fields($fields);
     $this->validation->set_error_delimiters('<div class="error">', '</div>');
     if ($this->validation->run() == FALSE) {
         $primarycontent = CI::view('me/register', true, true);
     } else {
         $register = array();
         $register['username'] = $this->input->post('username');
         $register['password'] = $this->input->post('password');
         $register['email'] = $this->input->post('email');
         $register['is_active'] = 1;
         CI::model('users')->saveUser($register);
         $primarycontent = CI::view('me/register_done', true, true);
     }
     $this->load->vars($this->template);
     $layout = CI::view('layout', true, true);
     $layout = str_ireplace('{primarycontent}', $primarycontent, $layout);
     CI::library('output')->set_output($layout);
 }
开发者ID:Gninety,项目名称:Microweber,代码行数:33,代码来源:me.php

示例5: index

 function index()
 {
     $this->template['functionName'] = strtolower(__FUNCTION__);
     $tags = CI::model('core')->getParamFromURL('tags');
     $data = array();
     $this->template['search_by_keyword'] = '';
     if ($tags) {
         $data['search_by_keyword'] = $tags;
         $this->template['search_by_keyword'] = $tags;
     }
     $results_count = CI::model('comments')->commentsGet($data, false, true);
     $items_per_page = CI::model('core')->optionsGetByKey('admin_default_items_per_page');
     $content_pages_count = ceil($results_count / $items_per_page);
     $curent_page = CI::model('core')->getParamFromURL('curent_page');
     if (intval($curent_page) < 1 || intval($curent_page) > $content_pages_count) {
         $curent_page = 1;
     }
     $page_start = ($curent_page - 1) * $items_per_page;
     $page_end = $page_start + $items_per_page;
     //$data ['is_moderated'] = 'n';
     $form_values = CI::model('comments')->commentsGet($data, array($page_start, $page_end), false);
     $new_comments = array();
     $old_comments = array();
     for ($i = 0; $i < count($form_values); $i++) {
         if ($form_values[$i]['is_moderated'] == 'n') {
             $new_comments[] = $form_values[$i];
         } else {
             $old_comments[] = $form_values[$i];
         }
     }
     $this->template['content_pages_count'] = $content_pages_count;
     //var_dump($content_pages_count);
     $this->template['content_pages_curent_page'] = $curent_page;
     //get paging urls
     $content_pages = CI::model('content')->pagingPrepareUrls(false, $content_pages_count);
     $this->template['content_pages_links'] = $content_pages;
     $this->template['new_comments'] = $new_comments;
     $this->load->vars($this->template);
     /*
     $data = array ( );
     $data ['is_moderated'] = 'y';
     $limit [0] = 0;
     $limit [1] = 100;
     
     $form_values = CI::model('comments')->commentsGet ( $data );
     */
     $this->template['old_comments'] = $old_comments;
     $this->load->vars($this->template);
     $this->load->vars($this->template);
     $layout = CI::view('admin/layout', true, true);
     $primarycontent = '';
     $secondarycontent = '';
     $primarycontent = CI::view('admin/comments/index', true, true);
     //$secondarycontent = CI::view ( 'admin/content/sidebar', true, true );
     $layout = str_ireplace('{primarycontent}', $primarycontent, $layout);
     $layout = str_ireplace('{secondarycontent}', $secondarycontent, $layout);
     //CI::view('welcome_message');
     CI::library('output')->set_output($layout);
 }
开发者ID:Gninety,项目名称:Microweber,代码行数:59,代码来源:comments.php

示例6: edit

 function edit()
 {
     //CI::library ( 'session' )->set_userdata ( 'editmode', false );
     $is_admin = is_admin();
     if ($is_admin == false) {
         $go = site_url('login');
         safe_redirect($go);
     }
     $layout = CI::view('admin/iframe', true, true);
     $layout = CI::model('template')->parseMicrwoberTags($layout);
     //$layout = CI::model('template')->parseMicrwoberTags ( $layout );
     CI::library('output')->set_output($layout);
 }
开发者ID:Gninety,项目名称:Microweber,代码行数:13,代码来源:index.php

示例7: index

 function index()
 {
     $this->template['functionName'] = strtolower(__FUNCTION__);
     if (CI::library('session')->userdata('user') == false) {
         //redirect ( 'index' );
     }
     $this->load->vars($this->template);
     $layout = CI::view('admin/layout', true, true);
     $primarycontent = '';
     $secondarycontent = '';
     $primarycontent = CI::view('admin/index', true, true);
     //$layout = str_ireplace ( '{primarycontent }', $primarycontent, $layout );
     //$layout = str_ireplace ( '{secondarycontent}', $secondarycontent, $layout );
     //CI::view('welcome_message');
     CI::library('output')->set_output($layout);
 }
开发者ID:Gninety,项目名称:Microweber,代码行数:16,代码来源:core.php

示例8: login

 function login()
 {
     $back_to = CI::model('core')->getParamFromURL('back_to');
     global $cms_db_tables;
     $table = $cms_db_tables['table_users'];
     $username = $this->input->post('username', TRUE);
     $password = $this->input->post('password', TRUE);
     $user_action = $this->input->post('user_action', TRUE);
     if ($user_action == 'register') {
         $q = "select username from " . $table . " where username='{$username}' ";
         $query = CI::db()->query($q);
         $query = $query->row_array();
         $query = array_values($query);
         $username = $query[0];
         if ($username != '') {
             $this->template['message'] = 'This user exists, try another one!';
         } else {
             $data = array('updated_on' => date("Y-m-d h:i:s"), 'is_active' => 0, 'username' => $username, 'password' => $password);
             $this->db->insert($table, $data);
             $this->template['message'] = 'Success, try login now!';
         }
     } else {
         $q = "select * from " . $table . " where username='{$username}' and password='{$password}' and is_active=1";
         $query = CI::db()->query($q);
         $query = $query->row_array();
         if (empty($query)) {
             $this->template['message'] = 'Wrong username or password, or user is disabled!';
         } else {
             CI::library('session')->set_userdata('user', $query);
             if ($back_to == false) {
                 redirect('dashboard');
             } else {
                 redirect(base64_decode($back_to));
             }
         }
     }
     $this->load->vars($this->template);
     $layout = CI::view('layout', true, true);
     $primarycontent = '';
     $secondarycontent = '';
     $primarycontent = CI::view('login', true, true);
     $layout = str_ireplace('{primarycontent}', $primarycontent, $layout);
     $layout = str_ireplace('{secondarycontent}', $secondarycontent, $layout);
     //CI::view('welcome_message');
     //CI::library('output')->set_output ( $layout );
 }
开发者ID:Gninety,项目名称:Microweber,代码行数:46,代码来源:index.php

示例9: edit

 function edit()
 {
     $this->template['functionName'] = strtolower(__FUNCTION__);
     $this->load->vars($this->template);
     if ($_POST) {
         $save = $this->cacaomail_model->saveMailCampaigns($_POST);
         redirect('mailcampaigns');
     }
     $segs = $this->uri->segment_array();
     $the_id = false;
     foreach ($segs as $segment) {
         if (stristr($segment, 'id:') == true) {
             $the_id = $segment;
             $the_id = substr($the_id, 3, strlen($the_id));
         }
     }
     if (intval($the_id) != 0) {
         $form_values = $this->cacaomail_model->getMailCampaigns(array('id' => $the_id), 1);
         $form_values = $form_values[0];
         $this->template['form_values'] = $form_values;
         //$mailist_groups_titles = $this->cacaomail_model->getMailAccountsGroups();
         //$this->template ['form_values']['mailist_groups_titles'] = $mailist_groups_titles;
     }
     $mailist_account_groups = $this->cacaomail_model->getMailAccountsGroups();
     $this->template['form_values']['mail_accounts_groups'] = $mailist_account_groups;
     $mailist_account_single = $this->cacaomail_model->getMailAccounts();
     $this->template['form_values']['mail_accounts_singles'] = $mailist_account_single;
     $temp = $this->cacaomail_model->getJobfeedsGroups();
     $this->template['form_values']['mail_lists_groups'] = $temp;
     $temp = $this->cacaomail_model->getJobfeeds();
     $this->template['form_values']['mail_lists_singles'] = $temp;
     //`mailists_groups_ids` text,
     //`mailists_single_id` int(11) default NULL,
     $this->load->vars($this->template);
     $layout = CI::view('layout', true, true);
     $primarycontent = '';
     $secondarycontent = '';
     $primarycontent = CI::view('mailcampaigns/edit', true, true);
     $secondarycontent = CI::view('mailcampaigns/sidebar', true, true);
     $layout = str_ireplace('{primarycontent}', $primarycontent, $layout);
     $layout = str_ireplace('{secondarycontent}', $secondarycontent, $layout);
     //CI::view('welcome_message');
     CI::library('output')->set_output($layout);
 }
开发者ID:Gninety,项目名称:Microweber,代码行数:44,代码来源:mailcampaigns.php

示例10: index

 function index()
 {
     $this->template['functionName'] = strtolower(__FUNCTION__);
     $data = array();
     $reports_for = CI::model('core')->getParamFromURL('t');
     if ($reports_for != false) {
         // $data['to_table'] = $reports_for;
         $data[] = array('to_table', $reports_for);
     }
     $reports = CI::model('reports')->reportsGet($data, false);
     $this->template['reports'] = $reports;
     $this->load->vars($this->template);
     $layout = CI::view('admin/layout', true, true);
     $primarycontent = '';
     $secondarycontent = '';
     $primarycontent = CI::view('admin/reports/index', true, true);
     //$secondarycontent = CI::view ( 'admin/content/sidebar', true, true );
     $layout = str_ireplace('{primarycontent}', $primarycontent, $layout);
     $layout = str_ireplace('{secondarycontent}', $secondarycontent, $layout);
     //CI::view('welcome_message');
     CI::library('output')->set_output($layout);
 }
开发者ID:Gninety,项目名称:Microweber,代码行数:22,代码来源:reports.php

示例11: index

 function index()
 {
     $gogo = site_url('admin/content/posts_manage') . $togo_categories . $togo_tags;
     $gogo = reduce_double_slashes($gogo);
     header("Location: {$gogo} ");
     //var_dump ( $gogo );
     exit;
     //http://test3.ooyes.net/admin
     $this->template['functionName'] = strtolower(__FUNCTION__);
     if (CI::library('session')->userdata('user') == false) {
         //redirect ( 'index' );
     }
     $this->load->vars($this->template);
     $layout = CI::view('admin/layout', true, true);
     $primarycontent = '';
     $secondarycontent = '';
     $primarycontent = CI::view('admin/index', true, true);
     //$layout = str_ireplace ( '{primarycontent }', $primarycontent, $layout );
     //$layout = str_ireplace ( '{secondarycontent}', $secondarycontent, $layout );
     //CI::view('welcome_message');
     CI::library('output')->set_output($layout);
 }
开发者ID:Gninety,项目名称:Microweber,代码行数:22,代码来源:index.php

示例12: id

 function id($id)
 {
     global $cms_db_tables;
     $data = array();
     //parent::ajax_json_get_items_for_order_id();
     if ($id) {
         $q = "SELECT * FROM {$cms_db_tables['table_cart_orders']} WHERE id={$id}";
         $q = CI::model('core')->dbQuery($q);
         $array_buf = $q[0];
         $array_buf2 = array();
         foreach ($array_buf as $key => $val) {
             if ($key != 'cvv2') {
                 if ($key == 'cardholdernumber') {
                     $val = substr_replace($val, "######", 0, strlen($val) - 4);
                 }
                 $array_buf2[$key] = $val;
             }
         }
         $data['order_info'] = $array_buf2;
     }
     $primarycontent = CI::view('admin/popup', $data);
 }
开发者ID:Gninety,项目名称:Microweber,代码行数:22,代码来源:orderinfo.php

示例13: add

 function add()
 {
     $this->template['functionName'] = strtolower(__FUNCTION__);
     if ($_POST) {
         CI::model('core')->cacheDelete('cache_group', 'options');
         CI::model('core')->optionsSave($_POST);
         redirect('admin/options/index');
     }
     $all_options = CI::model('core')->optionsGet(false);
     $this->template['all_options'] = $all_options;
     $this->load->vars($this->template);
     $layout = CI::view('admin/layout', true, true);
     $primarycontent = '';
     $secondarycontent = '';
     $primarycontent = CI::view('admin/options/add', true, true);
     $nav = CI::view('admin/options/subnav', true, true);
     $primarycontent = $nav . $primarycontent;
     //	$secondarycontent = CI::view ( 'admin/content/sidebar', true, true );
     $layout = str_ireplace('{primarycontent}', $primarycontent, $layout);
     $layout = str_ireplace('{secondarycontent}', $secondarycontent, $layout);
     //CI::view('welcome_message');
     CI::library('output')->set_output($layout);
 }
开发者ID:Gninety,项目名称:Microweber,代码行数:23,代码来源:options.php

示例14: sitemaps

 function sitemaps()
 {
     ob_clean();
     header("Content-Type: text/xml; charset=UTF-8");
     //header ( "Content-Type: application/rss+xml" );
     global $cms_db_tables;
     $table = $cms_db_tables['table_content'];
     $sitemaps_count = false;
     $q = "select count(*) as qty from {$table}  ";
     $q = CI::model('core')->dbQuery($q);
     $q = $q[0]['qty'];
     $q = intval($q);
     $maps_count = ceil($q / 200);
     $this->template['maps_count'] = $maps_count;
     $map_id = $this->uri->segment(3);
     $map_id = intval($map_id);
     if ($map_id == 0) {
         $this->template['the_index'] = true;
         $this->load->vars($this->template);
         $upperLimit = $maps_count;
         $lowerLimit = 1;
         $updates = array();
         $sitemaps_urls = array();
         while ($lowerLimit <= $upperLimit) {
             $some = ($upperLimit - $lowerLimit) * 200 + 0;
             $some2 = ($upperLimit - $lowerLimit) * 200 + 1;
             $q = "select updated_on from {$table}  order by updated_on DESC limit 0,1 ";
             //var_dump($q);
             $q = CI::model('core')->dbQuery($q);
             $q = $q[0]['updated_on'];
             $updates[] = $q;
             $sitemaps_urls[] = urlencode(site_url('main/sitemaps/' . $lowerLimit));
             $lowerLimit++;
         }
         $this->template['updates'] = $updates;
         $this->load->vars($this->template);
         foreach ($sitemaps_urls as $item1) {
             $ch = curl_init("http://www.google.com/webmasters/tools/ping?sitemap=" . $item1);
             curl_setopt($ch, CURLOPT_HEADER, 0);
             curl_setopt($ch, CURLOPT_POST, 1);
             curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
             $output = curl_exec($ch);
             curl_close($ch);
             //echo $output;
             $ch = curl_init("http://search.yahooapis.com/SiteExplorerService/V1/ping?sitemap=" . $item1);
             curl_setopt($ch, CURLOPT_HEADER, 0);
             curl_setopt($ch, CURLOPT_POST, 1);
             curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
             $output = curl_exec($ch);
             curl_close($ch);
         }
     } else {
         $some = 200 * ($map_id - 1);
         $some2 = 200 * ($map_id + 0);
         $q = "select id, updated_on from {$table}  order by updated_on DESC limit {$some},{$some2} ";
         $q = CI::model('core')->dbQuery($q);
         $updates = $q;
         $this->template['updates'] = $updates;
         $this->load->vars($this->template);
     }
     //www.google.com/webmasters/tools/ping?sitemap=http%3A%2F%2Fwww.yoursite.com%2Fsitemap.gz
     $this->template['posts'] = $posts;
     $this->load->vars($this->template);
     $layout = CI::view('sitemap.php', true, true);
     CI::library('output')->set_output($layout);
 }
开发者ID:Gninety,项目名称:Microweber,代码行数:66,代码来源:main.php

示例15: id

 function id($id, $image = '')
 {
     global $cms_db_tables;
     $opt = array();
     $query = "SELECT * from {$cms_db_tables['table_cart_orders']} WHERE id={$id}";
     $tracking_number = CI::model('core')->dbQuery($query);
     $opt['shipping_service'] = $tracking_number[0]['shipping_service'];
     $opt['transactionid'] = $tracking_number[0]['transactionid'];
     $opt['user_shipper_company_name'] = $tracking_number[0]['scompany'];
     $opt['user_shipper_person_name'] = $tracking_number[0]['sname'];
     $opt['user_phone_dial_plan_number'] = trim(substr($tracking_number[0]['sphone'], 0, 6));
     $opt['user_phone_line_number'] = trim(substr($tracking_number[0]['sphone'], 6));
     $opt['user_shipper_company_address1'] = $tracking_number[0]['saddress1'];
     $opt['user_shipper_company_address2'] = $tracking_number[0]['saddress2'];
     $opt['user_shipper_company_city'] = $tracking_number[0]['scity'];
     $opt['user_shipper_state'] = $tracking_number[0]['sstate'];
     $opt['user_shipper_zip'] = $tracking_number[0]['szipcode'];
     $query = "SELECT * from {$cms_db_tables['table_cart']} WHERE order_id='{$tracking_number[0]['order_id']}'";
     $shipment = CI::model('core')->dbQuery($query);
     $opt['shipment_weight'] = $shipment[0]['weight'];
     $opt['shipment_length'] = $shipment[0]['length'];
     $opt['shipment_width'] = $shipment[0]['width'];
     $opt['shipment_height'] = $shipment[0]['height'];
     if ($image) {
         $dat = base64_decode($tracking_number[0]["tracking_number"]);
         $data['image'] = $dat["tracking_number"];
     } else {
         if (trim($tracking_number[0]["tracking_number"]) != '') {
             $tr = array();
             $tr_buf = array();
             $tr_buf = explode('|', base64_decode($tracking_number[0]["tracking_number"]));
             for ($i = 0; $i < count($tr_buf); $i++) {
                 $res = explode(':', $tr_buf[$i]);
                 if ($res[0] != 'graphic_image') {
                     $tr[$res[0]] = $res[1];
                 }
             }
             $data['output_xml'] = $tr;
         } else {
             $options = array();
             $options = CI::model('core')->optionsGetByKey('shop_ups_xml_key', true);
             $opt['ups_xml_access_key'] = $options['option_value'];
             $options = CI::model('core')->optionsGetByKey('shop_ups_username', true);
             $opt['ups_userid'] = $options['option_value'];
             $options = CI::model('core')->optionsGetByKey('shop_ups_password', true);
             $opt['ups_password'] = $options['option_value'];
             $options = CI::model('core')->optionsGetByKey('shop_ups_shipper_number', true);
             $opt['ups_shipper_number'] = $options['option_value'];
             $opt['shop_ups_shipper_company_name'] = CI::model('core')->optionsGetByKey("shop_ups_shipper_company_name", false);
             $opt['shop_ups_shipper_person_name'] = CI::model('core')->optionsGetByKey("shop_ups_shipper_person_name", false);
             $opt['phone_dial_plan_number'] = trim(substr(CI::model('core')->optionsGetByKey("shop_ups_shipper_company_phone", false), 0, 6));
             $opt['phone_line_number'] = trim(substr(CI::model('core')->optionsGetByKey("shop_ups_shipper_company_phone", false), 6));
             $opt['shop_ups_shipper_company_address'] = CI::model('core')->optionsGetByKey("shop_ups_shipper_company_address", false);
             $opt['shop_ups_shipper_company_city'] = CI::model('core')->optionsGetByKey("shop_ups_shipper_company_city", false);
             $opt['shop_orders_ship_from_zip'] = CI::model('core')->optionsGetByKey("shop_orders_ship_from_zip", false);
             $result = $this->getUPS($opt);
             if (!empty($result) && $result["tracking_number"]) {
                 $bufer = "";
                 foreach ($result as $key => $val) {
                     $bufer .= "{$key}:{$val}|";
                 }
                 $bufer = rtrim($bufer, '|');
                 $dat = base64_encode($bufer);
                 $query = "UPDATE {$cms_db_tables['table_cart_orders']} set tracking_number='{$dat}' WHERE id={$id}";
                 CI::model('core')->dbQ($query);
                 $data['output_xml'] = $result;
             }
         }
         $data['id'] = $id;
     }
     CI::view('admin/ups', $data);
 }
开发者ID:Gninety,项目名称:Microweber,代码行数:72,代码来源:ups_order.php


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