You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 's%20Hair%20Thinning%20-%20Lavividhair' LIMIT 1' at line 3select a.id_category,a.link_rewrite from ps_category_lang a
where a.id_shop = 1
and CONCAT( '/',a.id_category,'-',a.link_rewrite) = '/blog/European%20Hair%20System%20to%20Treat%20Men's%20Hair%20Thinning%20-%20Lavividhair' LIMIT 1
at line 866 in file classes/db/Db.php
861. if ($webservice_call && $errno) {
862. $dbg = debug_backtrace();
863. WebserviceRequest::getInstance()->setError(500, '[SQL Error] '.$this->getMsgError().'. From '.(isset($dbg[3]['class']) ? $dbg[3]['class'] : '').'->'.$dbg[3]['function'].'() Query was : '.$sql, 97);
864. } elseif (_PS_DEBUG_SQL_ && $errno && !defined('PS_INSTALLATION_IN_PROGRESS')) {
865. if ($sql) {
866. throw new PrestaShopDatabaseException($this->getMsgError().'<br /><br /><pre>'.$sql.'</pre>');
867. }
868.
869. throw new PrestaShopDatabaseException($this->getMsgError());
870. }
871. }
572. $this->result = $this->_query($sql);
573. }
574. }
575.
576. if (_PS_DEBUG_SQL_) {
577. $this->displayError($sql);
578. }
579.
580. return $this->result;
581. }
582.
Argument [0] select a.id_category,a.link_rewrite from ps_category_lang a where a.id_shop = 1 and CONCAT( '/',a.id_category,'-',a.link_rewrite) = '/blog/European%20Hair%20System%20to%20Treat%20Men's%20Hair%20Thinning%20-%20Lavividhair' LIMIT 1
782. $this->last_cached = true;
783. return $result;
784. }
785. }
786.
787. $this->result = $this->query($sql);
788. if (!$this->result) {
789. $result = false;
790. } else {
791. $result = $this->nextRow($this->result);
792. }
Argument [0] select a.id_category,a.link_rewrite from ps_category_lang a where a.id_shop = 1 and CONCAT( '/',a.id_category,'-',a.link_rewrite) = '/blog/European%20Hair%20System%20to%20Treat%20Men's%20Hair%20Thinning%20-%20Lavividhair' LIMIT 1
809. {
810. if ($sql instanceof DbQuery) {
811. $sql = $sql->build();
812. }
813.
814. if (!$result = $this->getRow($sql, $use_cache)) {
815. return false;
816. }
817.
818. return array_shift($result);
819. }
Argument [0] select a.id_category,a.link_rewrite from ps_category_lang a where a.id_shop = 1 and CONCAT( '/',a.id_category,'-',a.link_rewrite) = '/blog/European%20Hair%20System%20to%20Treat%20Men's%20Hair%20Thinning%20-%20Lavividhair' Argument [1] 1
272. $pagetype = 'default';
273.
274. $checkCategory = "select a.id_category,a.link_rewrite from ps_category_lang a
275. where a.id_shop = 1
276. and CONCAT( '/',a.id_category,'-',a.link_rewrite) = '". $page."'";
277. $res = Db::getInstance()->getValue($checkCategory);
278. if($res){
279.
280. $pagetype = 'category';
281.
282. }
Argument [0] select a.id_category,a.link_rewrite from ps_category_lang a where a.id_shop = 1 and CONCAT( '/',a.id_category,'-',a.link_rewrite) = '/blog/European%20Hair%20System%20to%20Treat%20Men's%20Hair%20Thinning%20-%20Lavividhair'
546.
547. if (($id_module && !is_numeric($id_module)) || !Validate::isHookName($hook_name)) {
548. throw new PrestaShopException('Invalid id_module or hook_name');
549. }
550.
551. if (!$module_list = Hook::getHookModuleExecList($hook_name)) {
552. return '';
553. }
554. if (!$id_hook = Hook::getIdByName($hook_name)) {
555. return false;
556. }
Argument [0] actionFrontControllerSetMedia
945.
946. if (Configuration::get('PS_COMPARATOR_MAX_ITEM') > 0) {
947. $this->addJS(_THEME_JS_DIR_.'products-comparison.js');
948. }
949.
950. Hook::exec('actionFrontControllerSetMedia', array());
951.
952. return true;
953. }
954. public function initHeader()
955. {
Argument [0] actionFrontControllerSetMedia Argument [1] Array ( )
141. }
142. }
143.
144. public function setMedia()
145. {
146. parent::setMedia();
147.
148. if ($this->assignCase == 1) {
149. $this->addJS(_THEME_JS_DIR_.'cms.js');
150. }
151.
114. public function run()
115. {
116. $this->init();
117. if ($this->checkAccess()) {
118. if (!$this->content_only && ($this->display_header || (isset($this->className) && $this->className))) {
119. $this->setMedia();
120. }
121.
122. $this->postProcess();
123.
124. if (!empty($this->redirect_after)) {
271. default :
272. throw new PrestaShopException('Bad front controller chosen');
273. }
274. try {
275. $controller = Controller::getController($controller_class);
276. $controller->run();
277.
278. } catch (PrestaShopException $e) {
279. $e->displayMessage();
280. }
281. }
87. if (Context::getContext()->cookie->id_cart) {
88. $cart = new Cart(Context::getContext()->cookie->id_cart);
89. $cart->checkCart();
90. }
91.
92. Dispatcher::getInstance()->dispatch();
93.