Access denied for user 'gurudav'@'62.109.140.%' to database 'prestashop18'CREATE TEMPORARY TABLE `ps_product_reductions` (id_product INT UNSIGNED NOT NULL DEFAULT 0, id_product_attribute INT UNSIGNED NOT NULL DEFAULT 0) ENGINE=MEMORY
at line 765 in file classes/db/Db.php
760. WebserviceRequest::getInstance()->setError(500, '[SQL Error] '.$this->getMsgError().'. From '.(isset($dbg[3]['class']) ? $dbg[3]['class'] : '').'->'.$dbg[3]['function'].'() Query was : '.$sql, 97);
761. }
762. elseif (_PS_DEBUG_SQL_ && $errno && !defined('PS_INSTALLATION_IN_PROGRESS'))
763. {
764. if ($sql)
765. throw new PrestaShopDatabaseException($this->getMsgError().'<br /><br /><pre>'.$sql.'</pre>');
766.
767. throw new PrestaShopDatabaseException($this->getMsgError());
768. }
769. }
770.
413. if ($this->connect())
414. $this->result = $this->_query($sql);
415. }
416.
417. if (_PS_DEBUG_SQL_)
418. $this->displayError($sql);
419.
420. return $this->result;
421. }
422.
423. /**
Argument [0] CREATE TEMPORARY TABLE `ps_product_reductions` (id_product INT UNSIGNED NOT NULL DEFAULT 0, id_product_attribute INT UNSIGNED NOT NULL DEFAULT 0) ENGINE=MEMORY
573. public function execute($sql, $use_cache = true)
574. {
575. if ($sql instanceof DbQuery)
576. $sql = $sql->build();
577.
578. $this->result = $this->query($sql);
579. if ($use_cache && $this->is_cache_enabled)
580. Cache::getInstance()->deleteQuery($sql);
581.
582. return (bool)$this->result;
583. }
Argument [0] CREATE TEMPORARY TABLE `ps_product_reductions` (id_product INT UNSIGNED NOT NULL DEFAULT 0, id_product_attribute INT UNSIGNED NOT NULL DEFAULT 0) ENGINE=MEMORY
2274. $ids_products = '';
2275. foreach ($product_reductions as $product_reduction)
2276. $ids_products .= '('.(int)$product_reduction['id_product'].','.($product_reduction['id_product_attribute'] ? (int)$product_reduction['id_product_attribute'] :'0').'),';
2277.
2278. $ids_products = rtrim($ids_products, ',');
2279. Db::getInstance(_PS_USE_SQL_SLAVE_)->execute('CREATE TEMPORARY TABLE `'._DB_PREFIX_.'product_reductions` (id_product INT UNSIGNED NOT NULL DEFAULT 0, id_product_attribute INT UNSIGNED NOT NULL DEFAULT 0) ENGINE=MEMORY', false);
2280. if ($ids_products)
2281. Db::getInstance(_PS_USE_SQL_SLAVE_)->execute('INSERT INTO `'._DB_PREFIX_.'product_reductions` VALUES '.$ids_products, false);
2282.
2283. $groups = FrontController::getCurrentCustomerGroups();
2284. $sql_groups = ' AND EXISTS(SELECT 1 FROM `'._DB_PREFIX_.'category_product` cp
Argument [0] CREATE TEMPORARY TABLE `ps_product_reductions` (id_product INT UNSIGNED NOT NULL DEFAULT 0, id_product_attribute INT UNSIGNED NOT NULL DEFAULT 0) ENGINE=MEMORY Argument [1]
99. // We need to create multiple caches because the products are sorted randomly
100. $random = date('Ymd').'|'.round(rand(1, max(Configuration::get('BLOCKSPECIALS_NB_CACHES'), 1)));
101.
102. if (!Configuration::get('BLOCKSPECIALS_NB_CACHES') || !$this->isCached('blockspecials.tpl', $this->getCacheId('blockspecials|'.$random)))
103. {
104. if (!($special = Product::getRandomSpecial((int)$params['cookie']->id_lang)) && !Configuration::get('PS_BLOCK_SPECIALS_DISPLAY'))
105. return;
106.
107. $this->smarty->assign(array(
108. 'special' => $special,
109. 'priceWithoutReduction_tax_excl' => Tools::ps_round($special['price_without_reduction'], 2),
Argument [0] 1
114. return $this->display(__FILE__, 'blockspecials.tpl', (Configuration::get('BLOCKSPECIALS_NB_CACHES') ? $this->getCacheId('blockspecials|'.$random) : null));
115. }
116.
117. public function hookLeftColumn($params)
118. {
119. return $this->hookRightColumn($params);
120. }
121.
122. public function hookHeader($params)
123. {
124. if (Configuration::get('PS_CATALOG_MODE'))
Argument [0]
564. Module::$_log_modules_perfs_session = mt_rand();
565. }
566.
567. // Immediately return the result if we do not log performances
568. if (!Module::$_log_modules_perfs)
569. return $module->{$method}($params);
570.
571. // Store time and memory before and after hook call and save the result in the database
572. $time_start = microtime(true);
573. $memory_start = memory_get_usage(true);
574.
Argument [0]
521.
522. // Call hook method
523. if ($hook_callable)
524. $display = Hook::coreCallHook($moduleInstance, 'hook'.$hook_name, $hook_args);
525. elseif ($hook_retro_callable)
526. $display = Hook::coreCallHook($moduleInstance, 'hook'.$retro_hook_name, $hook_args);
527.
528. // Live edit
529. if (!$array_return && $array['live_edit'] && Tools::isSubmit('live_edit') && Tools::getValue('ad')
530. && Tools::getValue('liveToken') == Tools::getAdminToken('AdminModulesPositions'
531. .(int)Tab::getIdFromClassName('AdminModulesPositions').(int)Tools::getValue('id_employee')))
Argument [0] Argument [1] hookleftcolumn Argument [2]
576. // These hooks aren't used for the mobile theme.
577. // Needed hooks are called in the tpl files.
578. $this->context->smarty->assign(array(
579. 'HOOK_HEADER' => Hook::exec('displayHeader'),
580. 'HOOK_TOP' => Hook::exec('displayTop'),
581. 'HOOK_LEFT_COLUMN' => ($this->display_column_left ? Hook::exec('displayLeftColumn') : ''),
582. 'HOOK_RIGHT_COLUMN' => ($this->display_column_right ? Hook::exec('displayRightColumn', array('cart' => $this->context->cart)) : ''),
583. ));
584. }
585. else
586. $this->context->smarty->assign('HOOK_MOBILE_HEADER', Hook::exec('displayMobileHeader'));
Argument [0] displayLeftColumn
38. * Assign template vars related to page content
39. * @see FrontController::initContent()
40. */
41. public function initContent()
42. {
43. parent::initContent();
44.
45. $this->productSort();
46.
47. // Override default configuration values: cause the new products page must display latest products first.
48. if (!Tools::getIsset('orderway') || !Tools::getIsset('orderby'))
175.
176. if (!$this->content_only && ($this->display_header || (isset($this->className) && $this->className)))
177. $this->initHeader();
178.
179. if ($this->viewAccess())
180. $this->initContent();
181. else
182. $this->errors[] = Tools::displayError('Access denied.');
183.
184. if (!$this->content_only && ($this->display_footer || (isset($this->className) && $this->className)))
185. $this->initFooter();
368. // Execute hook dispatcher
369. if (isset($params_hook_action_dispatcher))
370. Hook::exec('actionDispatcher', $params_hook_action_dispatcher);
371.
372. // Running controller
373. $controller->run();
374. }
375. catch (PrestaShopException $e)
376. {
377. $e->displayMessage();
378. }
23. * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
24. * International Registered Trademark & Property of PrestaShop SA
25. */
26.
27. require(dirname(__FILE__).'/config/config.inc.php');
28. Dispatcher::getInstance()->dispatch();