@@ -59,7 +59,7 @@ |
||
59 | 59 | if (isset($this->request->get['manufacturer_id'])) { |
60 | 60 | $manufacturer_id = ($this->request->get['manufacturer_id']); |
61 | 61 | } else { |
62 | - $manufacturer_id = null; |
|
62 | + $manufacturer_id = null; |
|
63 | 63 | } |
64 | 64 | |
65 | 65 | $filter_data = array( |
@@ -66,7 +66,7 @@ |
||
66 | 66 | if (isset($this->request->get['manufacturer_id'])) { |
67 | 67 | $manufacturer_id = ($this->request->get['manufacturer_id']); |
68 | 68 | } else { |
69 | - $manufacturer_id = null; |
|
69 | + $manufacturer_id = null; |
|
70 | 70 | } |
71 | 71 | |
72 | 72 |
@@ -38,7 +38,7 @@ discard block |
||
38 | 38 | ); |
39 | 39 | |
40 | 40 | if (isset($this->request->get['information_id'])) { |
41 | - $information_id = (int) $this->request->get['information_id']; |
|
41 | + $information_id = (int)$this->request->get['information_id']; |
|
42 | 42 | } else { |
43 | 43 | $information_id = 0; |
44 | 44 | } |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | |
66 | 66 | $data['breadcrumbs'][] = array( |
67 | 67 | 'text' => $information_info['title'], |
68 | - 'href' => $this->url->link('information/information', 'information_id=' . $information_id) |
|
68 | + 'href' => $this->url->link('information/information', 'information_id=' . $information_id) |
|
69 | 69 | ); |
70 | 70 | |
71 | 71 | $data['button_continue'] = $this->language->get('button_continue'); |
@@ -115,7 +115,7 @@ discard block |
||
115 | 115 | $this->load->model('catalog/information'); |
116 | 116 | |
117 | 117 | if (isset($this->request->get['information_id'])) { |
118 | - $information_id = (int) $this->request->get['information_id']; |
|
118 | + $information_id = (int)$this->request->get['information_id']; |
|
119 | 119 | } else { |
120 | 120 | $information_id = 0; |
121 | 121 | } |
@@ -67,7 +67,7 @@ discard block |
||
67 | 67 | } |
68 | 68 | |
69 | 69 | if (isset($this->request->get['limit'])) { |
70 | - $limit = ((int) $this->request->get['limit'] > 100 ? 100 : (int) $this->request->get['limit']); |
|
70 | + $limit = ((int)$this->request->get['limit'] > 100 ? 100 : (int)$this->request->get['limit']); |
|
71 | 71 | $this->document->setRobots('noindex,follow'); |
72 | 72 | } else { |
73 | 73 | $limit = $this->config->get('config_limit_store'); |
@@ -97,15 +97,15 @@ discard block |
||
97 | 97 | |
98 | 98 | $path = ''; |
99 | 99 | |
100 | - $parts = explode('_', (string) $this->request->get['path']); |
|
100 | + $parts = explode('_', (string)$this->request->get['path']); |
|
101 | 101 | |
102 | - $category_id = (int) array_pop($parts); |
|
102 | + $category_id = (int)array_pop($parts); |
|
103 | 103 | |
104 | 104 | foreach ($parts as $path_id) { |
105 | 105 | if (!$path) { |
106 | - $path = (int) $path_id; |
|
106 | + $path = (int)$path_id; |
|
107 | 107 | } else { |
108 | - $path .= '_' . (int) $path_id; |
|
108 | + $path .= '_' . (int)$path_id; |
|
109 | 109 | } |
110 | 110 | |
111 | 111 | $category_info = $this->model_catalog_category->getCategory($path_id); |
@@ -241,7 +241,7 @@ discard block |
||
241 | 241 | $price = false; |
242 | 242 | } |
243 | 243 | |
244 | - if ((float) $result['special']) { |
|
244 | + if ((float)$result['special']) { |
|
245 | 245 | $special = $this->currency->format($result['special'], $this->session->data['currency']); |
246 | 246 | } else { |
247 | 247 | $special = false; |
@@ -253,7 +253,7 @@ discard block |
||
253 | 253 | $description = \voku\helper\UTF8::substr(strip_tags(html_entity_decode($result['description'], ENT_QUOTES, 'UTF-8')), 0, $this->config->get($this->config->get('config_theme') . '_product_description_length')) . '..'; |
254 | 254 | } |
255 | 255 | |
256 | - if ((float) $result['special']) { |
|
256 | + if ((float)$result['special']) { |
|
257 | 257 | $yousave_percent = round(((($result['price'] - $result['special']) / $result['price']) * 100), 0); |
258 | 258 | } else { |
259 | 259 | $yousave_percent = false; |
@@ -51,9 +51,9 @@ discard block |
||
51 | 51 | if (isset($this->request->get['path'])) { |
52 | 52 | $path = ''; |
53 | 53 | |
54 | - $parts = explode('_', (string) $this->request->get['path']); |
|
54 | + $parts = explode('_', (string)$this->request->get['path']); |
|
55 | 55 | |
56 | - $category_id = (int) array_pop($parts); |
|
56 | + $category_id = (int)array_pop($parts); |
|
57 | 57 | |
58 | 58 | foreach ($parts as $path_id) { |
59 | 59 | if (!$path) { |
@@ -186,7 +186,7 @@ discard block |
||
186 | 186 | |
187 | 187 | // product_id |
188 | 188 | if (isset($this->request->get['product_id'])) { |
189 | - $product_id = (int) $this->request->get['product_id']; |
|
189 | + $product_id = (int)$this->request->get['product_id']; |
|
190 | 190 | } else { |
191 | 191 | $product_id = 0; |
192 | 192 | } |
@@ -325,7 +325,7 @@ discard block |
||
325 | 325 | $data['tab_attribute'] = $this->language->get('tab_attribute'); |
326 | 326 | $data['tab_review'] = sprintf($this->language->get('tab_review'), $product_info['reviews']); |
327 | 327 | |
328 | - $data['product_id'] = (int) $this->request->get['product_id']; |
|
328 | + $data['product_id'] = (int)$this->request->get['product_id']; |
|
329 | 329 | $data['manufacturer'] = $product_info['manufacturer']; |
330 | 330 | |
331 | 331 | // +++ category-in-the-product-page | All linked categories |
@@ -378,19 +378,19 @@ discard block |
||
378 | 378 | $data['price'] = false; |
379 | 379 | } |
380 | 380 | |
381 | - if ((float) $product_info['special']) { |
|
381 | + if ((float)$product_info['special']) { |
|
382 | 382 | $data['special'] = $this->currency->format($product_info['special'], $this->session->data['currency']); |
383 | 383 | } else { |
384 | 384 | $data['special'] = false; |
385 | 385 | } |
386 | 386 | |
387 | - if ((float) $product_info['special']) { |
|
387 | + if ((float)$product_info['special']) { |
|
388 | 388 | $data['yousave_money'] = $this->currency->format(($product_info['price'] - $product_info['special']), $this->session->data['currency']); |
389 | 389 | } else { |
390 | 390 | $data['yousave_money'] = false; |
391 | 391 | } |
392 | 392 | |
393 | - if ((float) $product_info['special']) { |
|
393 | + if ((float)$product_info['special']) { |
|
394 | 394 | $data['yousave_percent'] = round(((($product_info['price'] - $product_info['special']) / $product_info['price']) * 100), 0); |
395 | 395 | } else { |
396 | 396 | $data['yousave_percent'] = false; |
@@ -442,7 +442,7 @@ discard block |
||
442 | 442 | |
443 | 443 | foreach ($option['product_option_value'] as $option_value) { |
444 | 444 | if (!$option_value['subtract'] || ($option_value['quantity'] > 0)) { |
445 | - if ((($this->config->get('config_customer_price') && $this->customer->isLogged()) || !$this->config->get('config_customer_price')) && (float) $option_value['price']) { |
|
445 | + if ((($this->config->get('config_customer_price') && $this->customer->isLogged()) || !$this->config->get('config_customer_price')) && (float)$option_value['price']) { |
|
446 | 446 | $price = $this->currency->format($option_value['price'], $this->session->data['currency']); |
447 | 447 | } else { |
448 | 448 | $price = false; |
@@ -492,7 +492,7 @@ discard block |
||
492 | 492 | $data['customer_name'] = ''; |
493 | 493 | } |
494 | 494 | |
495 | - $data['reviews'] = sprintf($this->language->get('text_reviews'), (int) $product_info['reviews']); |
|
495 | + $data['reviews'] = sprintf($this->language->get('text_reviews'), (int)$product_info['reviews']); |
|
496 | 496 | |
497 | 497 | $data['attribute_groups'] = $this->model_catalog_product->getProductAttributes($this->request->get['product_id']); |
498 | 498 | |
@@ -513,13 +513,13 @@ discard block |
||
513 | 513 | $price = false; |
514 | 514 | } |
515 | 515 | |
516 | - if ((float) $result['special']) { |
|
516 | + if ((float)$result['special']) { |
|
517 | 517 | $special = $this->currency->format($result['special'], $this->session->data['currency']); |
518 | 518 | } else { |
519 | 519 | $special = false; |
520 | 520 | } |
521 | 521 | |
522 | - if ((float) $result['special']) { |
|
522 | + if ((float)$result['special']) { |
|
523 | 523 | $yousave_percent = round(((($result['price'] - $result['special']) / $result['price']) * 100), 0); |
524 | 524 | } else { |
525 | 525 | $yousave_percent = false; |
@@ -95,7 +95,7 @@ discard block |
||
95 | 95 | |
96 | 96 | |
97 | 97 | if (isset($this->request->get['manufacturer_id'])) { |
98 | - $manufacturer_id = (int) $this->request->get['manufacturer_id']; |
|
98 | + $manufacturer_id = (int)$this->request->get['manufacturer_id']; |
|
99 | 99 | } else { |
100 | 100 | $manufacturer_id = 0; |
101 | 101 | } |
@@ -121,10 +121,10 @@ discard block |
||
121 | 121 | } |
122 | 122 | |
123 | 123 | if (isset($this->request->get['limit'])) { |
124 | - $limit = ((int) $this->request->get['limit'] > 100 ? 100 : (int) $this->request->get['limit']); |
|
124 | + $limit = ((int)$this->request->get['limit'] > 100 ? 100 : (int)$this->request->get['limit']); |
|
125 | 125 | $this->document->setRobots('noindex,follow'); |
126 | 126 | } else { |
127 | - $limit = (int) $this->config->get('config_limit_store'); |
|
127 | + $limit = (int)$this->config->get('config_limit_store'); |
|
128 | 128 | } |
129 | 129 | |
130 | 130 | $data['breadcrumbs'] = array(); |
@@ -234,7 +234,7 @@ discard block |
||
234 | 234 | $price = false; |
235 | 235 | } |
236 | 236 | |
237 | - if ((float) $result['special']) { |
|
237 | + if ((float)$result['special']) { |
|
238 | 238 | $special = $this->currency->format($result['special'], $this->session->data['currency']); |
239 | 239 | } else { |
240 | 240 | $special = false; |
@@ -353,7 +353,7 @@ discard block |
||
353 | 353 | $pagination->total = $product_total; |
354 | 354 | $pagination->page = $page; |
355 | 355 | $pagination->limit = $limit; |
356 | - $pagination->url = $this->url->link('product/manufacturer/info', 'manufacturer_id=' . $this->request->get['manufacturer_id'] . $url . '&page={page}'); |
|
356 | + $pagination->url = $this->url->link('product/manufacturer/info', 'manufacturer_id=' . $this->request->get['manufacturer_id'] . $url . '&page={page}'); |
|
357 | 357 | |
358 | 358 | $data['pagination'] = $pagination->render(); |
359 | 359 |
@@ -91,9 +91,9 @@ discard block |
||
91 | 91 | } |
92 | 92 | |
93 | 93 | if (isset($this->request->get['search'])) { |
94 | - $this->document->setTitle($this->language->get('heading_title') . ' - ' . $this->request->get['search']); |
|
94 | + $this->document->setTitle($this->language->get('heading_title') . ' - ' . $this->request->get['search']); |
|
95 | 95 | } elseif (isset($this->request->get['tag'])) { |
96 | - $this->document->setTitle($this->language->get('heading_title') . ' - ' . $this->language->get('heading_tag') . $this->request->get['tag']); |
|
96 | + $this->document->setTitle($this->language->get('heading_title') . ' - ' . $this->language->get('heading_tag') . $this->request->get['tag']); |
|
97 | 97 | } else { |
98 | 98 | $this->document->setTitle($this->language->get('heading_title')); |
99 | 99 | } |
@@ -151,7 +151,7 @@ discard block |
||
151 | 151 | ); |
152 | 152 | |
153 | 153 | if (isset($this->request->get['search'])) { |
154 | - $data['heading_title'] = $this->language->get('heading_title') . ' - ' . $this->request->get['search']; |
|
154 | + $data['heading_title'] = $this->language->get('heading_title') . ' - ' . $this->request->get['search']; |
|
155 | 155 | } else { |
156 | 156 | $data['heading_title'] = $this->language->get('heading_title'); |
157 | 157 | } |
@@ -419,7 +419,7 @@ discard block |
||
419 | 419 | |
420 | 420 | private function getPathByProduct($product_id) |
421 | 421 | { |
422 | - $product_id = (int) $product_id; |
|
422 | + $product_id = (int)$product_id; |
|
423 | 423 | |
424 | 424 | if ($product_id < 1) { |
425 | 425 | return false; |
@@ -444,7 +444,7 @@ discard block |
||
444 | 444 | LIMIT 1 |
445 | 445 | "); |
446 | 446 | |
447 | - $path[$product_id] = $this->getPathByCategory($query->num_rows ? (int) $query->row['category_id'] : 0); |
|
447 | + $path[$product_id] = $this->getPathByCategory($query->num_rows ? (int)$query->row['category_id'] : 0); |
|
448 | 448 | |
449 | 449 | $this->cache->set( |
450 | 450 | 'product.seopath', |
@@ -457,7 +457,7 @@ discard block |
||
457 | 457 | |
458 | 458 | private function getPathByCategory($category_id) |
459 | 459 | { |
460 | - $category_id = (int) $category_id; |
|
460 | + $category_id = (int)$category_id; |
|
461 | 461 | |
462 | 462 | if ($category_id < 1) { |
463 | 463 | return false; |
@@ -506,7 +506,7 @@ discard block |
||
506 | 506 | //blog |
507 | 507 | private function getPathByBlogCategory($blog_category_id) |
508 | 508 | { |
509 | - $blog_category_id = (int) $blog_category_id; |
|
509 | + $blog_category_id = (int)$blog_category_id; |
|
510 | 510 | |
511 | 511 | if ($blog_category_id < 1) { |
512 | 512 | return false; |
@@ -555,7 +555,7 @@ discard block |
||
555 | 555 | |
556 | 556 | private function getPathByArticle($article_id) |
557 | 557 | { |
558 | - $article_id = (int) $article_id; |
|
558 | + $article_id = (int)$article_id; |
|
559 | 559 | |
560 | 560 | if ($article_id < 1) { |
561 | 561 | return false; |
@@ -575,7 +575,7 @@ discard block |
||
575 | 575 | if (!isset($path[$article_id])) { |
576 | 576 | $query = $this->db->query("SELECT blog_category_id FROM article_to_blog_category WHERE article_id = '" . $article_id . "' ORDER BY main_blog_category DESC LIMIT 1"); |
577 | 577 | |
578 | - $path[$article_id] = $this->getPathByBlogCategory($query->num_rows ? (int) $query->row['blog_category_id'] : 0); |
|
578 | + $path[$article_id] = $this->getPathByBlogCategory($query->num_rows ? (int)$query->row['blog_category_id'] : 0); |
|
579 | 579 | |
580 | 580 | // $this->cache->set( |
581 | 581 | // 'article.seopath', |
@@ -103,7 +103,7 @@ discard block |
||
103 | 103 | SET order_id = '" . (int)$order_id . "', |
104 | 104 | code = 'total', |
105 | 105 | title = 'Total', |
106 | - `value` = '" . (float)$data['cart_total']."', |
|
106 | + `value` = '" . (float)$data['cart_total'] . "', |
|
107 | 107 | sort_order = '' |
108 | 108 | "); |
109 | 109 | $this->db->query(" |
@@ -111,7 +111,7 @@ discard block |
||
111 | 111 | SET order_id = '" . (int)$order_id . "', |
112 | 112 | code = 'sub_total', |
113 | 113 | title = 'Total', |
114 | - `value` = '" . (float)$data['cart_total']."', |
|
114 | + `value` = '" . (float)$data['cart_total'] . "', |
|
115 | 115 | sort_order = '' |
116 | 116 | "); |
117 | 117 | } |
@@ -152,18 +152,18 @@ discard block |
||
152 | 152 | $this->db->query(" |
153 | 153 | INSERT INTO order_total |
154 | 154 | SET order_id = '" . (int)$order_id . "', |
155 | - code = '".$total['code']."', |
|
156 | - title = '".$total['title']."', |
|
157 | - `value` = '" . (float)$total['value']."', |
|
158 | - sort_order = '".$i."' |
|
155 | + code = '".$total['code'] . "', |
|
156 | + title = '".$total['title'] . "', |
|
157 | + `value` = '" . (float)$total['value'] . "', |
|
158 | + sort_order = '".$i . "' |
|
159 | 159 | "); |
160 | 160 | $i += 10; |
161 | - $total_sum = $total['value']; |
|
161 | + $total_sum = $total['value']; |
|
162 | 162 | } |
163 | 163 | // Last row in totals should be final sum... |
164 | 164 | $this->db->query(" |
165 | 165 | UPDATE order |
166 | - SET total='".$total_sum."' |
|
166 | + SET total='".$total_sum . "' |
|
167 | 167 | WHERE order_id = '" . (int)$order_id . "' |
168 | 168 | "); |
169 | 169 |