arthurganem Posted July 24, 2012 Share Posted July 24, 2012 When i turn on force compile on prestashop, the product page (/product.php?id_product=191) doesnt show anything except for background and categories, and this happens only when i turn on force compile on. is this normal? Link to comment Share on other sites More sharing options...
Mike Kranzler Posted July 24, 2012 Share Posted July 24, 2012 Hi arthur, This is not normal behavior in PrestaShop. In your config/config.inc.php file, please set "display_errors" to "on," then try this again and let us know if you receive any error messages. I hope this helps. -Mike Link to comment Share on other sites More sharing options...
tomerg3 Posted July 25, 2012 Share Posted July 25, 2012 It means there is an error in one of the .tpl files, and the product page cannot compile properly. As mike suggested, turn on error reporting and you will see the root of the problem. Link to comment Share on other sites More sharing options...
arthurganem Posted July 25, 2012 Author Share Posted July 25, 2012 (edited) This is the error i got Fatal error: Uncaught exception 'SmartyCompilerException' with message 'Syntax Error in template "/home/youneyme/public_html/themes/presta077v147/modules/productscategory/productscategory.tpl" on line 33 "{$categoryProducts = $categoryProducts + 2;}" - Unexpected ";"' in /home/youneyme/public_html/tools/smarty/sysplugins/smarty_internal_templatecompilerbase.php:431 Stack trace: #0 /home/youneyme/public_html/tools/smarty/sysplugins/smarty_internal_templateparser.php(2855): Smarty_Internal_TemplateCompilerBase->trigger_template_error() #1 /home/youneyme/public_html/tools/smarty/sysplugins/smarty_internal_templateparser.php(2920): Smarty_Internal_Templateparser->yy_syntax_error(24, ';') #2 /home/youneyme/public_html/tools/smarty/sysplugins/smarty_internal_smartytemplatecompiler.php(51): Smarty_Internal_Templateparser->doParse(24, ';') #3 /home/youneyme/public_html/tools/smarty/sysplugins/smarty_internal_templatecompilerbase.php(82): Smarty_Internal_SmartyTemplateCompiler->doCompile('{*?* 2007-2011 ...') #4 /home/youneyme/p in /home/youneyme/public_html/tools/smarty/sysplugins/smarty_internal_templatecompilerbase.php on line 431 i never added that ';' , but i decided to remove it anyway and i get a different error Fatal error: Unsupported operand types in /home/youneyme/public_html/tools/smarty/compile/f6d73cee6b908028cc1aa02289fa5c51afe4a0fe.file.productscategory.tpl.php on line 33 if this helps i was previously messing with productscategory.php and the only thing i did was change the numbers 30 and 15 in the following code, (i obviously changed them back, yet same problem is still there) anyway thats the code i was changing (productscategory.php) if ($sizeOfCategoryProducts > 30) { $categoryProducts = array_slice($categoryProducts, $middlePosition - 15, 30, true); $middlePosition = 15; } EDIT: And now i get an error when force compile is disabled Edited July 25, 2012 by arthurganem (see edit history) Link to comment Share on other sites More sharing options...
tomerg3 Posted July 25, 2012 Share Posted July 25, 2012 First of all, if you want to get your site back up, disable the module. You can edit home/youneyme/public_html/tools/smarty/compile/f6d73cee6b908028cc1aa02289fa5c51afe4a0fe.file.productscategory.tpl.php and see what's in line #33 Link to comment Share on other sites More sharing options...
arthurganem Posted July 25, 2012 Author Share Posted July 25, 2012 (edited) Ok this is how i fixed it. i had to uninstall the module, then delete productscategory.tpl inside the themes/modules/productscategory/ clear cache then install the module and put back productscategory.tpl (the one that comes with your theme) thanks for your help. Edited July 25, 2012 by arthurganem (see edit history) Link to comment Share on other sites More sharing options...
Mike Kranzler Posted July 25, 2012 Share Posted July 25, 2012 Great, I'm glad you were able to resolve this, and thanks to tomerg3 for providing assistance! I'll go ahead and mark this thread as solved for you. Happy selling! -Mike Link to comment Share on other sites More sharing options...
Recommended Posts