catalog/controller/common/currency.php
(开头部分) 1KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
<?php
class ControllerCommonCurrency extends Controller {
public function index() {
$this->load->language('common/currency');
$data['action'] = $this->url->link('common/currency/currency');
$data['code'] = $this->session->data['currency'];
$this->load->model('localisation/currency');
$data['currencies'] = array();
$results = $this->model_localisation_currency->getCurrencies();
foreach ($results as $result) {
if ($result['status']) {
$data['currencies'][] = array(
'title' => $result['title'],
'code' => $result['code'],
'symbol_left' => $result['symbol_left'],
'symbol_right' => $result['symbol_right']
);
}
}
if (!isset($this->request->get['route'])) {
$data['redirect'] = $this->url->link('common/home');
} else {
$url_data = $this->request->get;
unset($url_data['_route_']);
$route = $url_data['route'];
unset($url_data['route']);
$url = '';
if ($url_data) {
$url = '&' . urldecode(http_build_query($url_data, '', '&'));
}
$data['redirect'] = $this->url->link($route, $url);
}
$data['no_trans'] = 1;
return $this->load->view('common/currency', $data);
}
public function currency() {
if (isset($this->request->post['code'])) {
$this->session->data['currency'] = $this->request->post['code'];
unset($this->session->data['shipping_method']);
unset($this->session->data['shipping_methods']);
}
if (isset($this->request->post['redirect'])) {
$this->response->redirect($this->request->post['redirect']);
} else {
后面还有 4 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
