Jump to content

Product pages throwing "Page not available"


Recommended Posts

Whenever I visit a any of our products, across all our stores, I'm getting a 404 error:

 

"Page not available"

 

I'm using Prestashop 1.5.4.1 and have tried for hours now to get things back and running.

 

I tried clearing the cache by turning Caching off and Force Compilation on in the Performance page.

 

I also deleted the .htaccess file, turned Friendly URLs off, and back on to have PrestaShop regenerate the file.

 

NOTHING I'm trying seems to work!!!

 

The only hint of an error I'm getting, when I visit for example

 

http://newstore.ourcompany.com/7J0A1B83X2D7/en/home/94-product-seo-name.html

 

(...and the above is a link I got by clicking "Preview" on the product admin page...)

 

is inside a PHP error log file stating:

 

File does not exist: /var/www/newstore.ourcompany.com/current/en

 

where ./current is the public folder containing PrestaShop, and managed by Capistrano. Dunno why it's trying to find a physical /en folder?

 

I also checked my virtual host configuration and tried to determine if something is wrong there, but everything seems in order?

 

Any help would be highly appreciated!

Link to comment
Share on other sites

Hi guys, to answer your questions. Home page for shop (multistore) are working okay. However, when clicking through to a product, I get the 404.

 

Here's an example store, ignore the broken images, I'm still busy finishing moving our assets to Amazon S3 and CSS needs to be finished as well.

 

http://newstore.pers...m/7J0A1B83X2D7/

 

When I visit for example:

 

http://newstore.pers...all-poster.html

 

I also tried the product Preview link from backend, none works. Tried multiple stores, but all of them complain.

 

the thing blows up in my face miserably.

 

Backend is working 100%.

 

I'm going to try disabling all unnecessary plugins, disable all our overrides and see if the problem lies there somewhere.

 

Also thinking about grabbing a new Prestashop installation, and bringing our modules accross, and plugins.

 

We've been busy trying to upgrade our v1.5.0.9 to v1.5.4.1 for weeks now, and finally got to the stage where everything seems to work ok, on my local dev machine at least.

Edited by [email protected] (see edit history)
Link to comment
Share on other sites

Turning it off, and hitting Preview link from the backend gives a bit of info:

 

Fatal error: Uncaught exception 'SmartyException' with message 'Unable to load template file '/.../themes/personera//templates//.tpl' in '/.../themes/personera/product.tpl'' in /.../tools/smarty/sysplugins/smarty_internal_templatebase.php:127 Stack trace: #0 /.../tools/smarty/sysplugins/smarty_internal_template.php(286): Smarty_Internal_TemplateBase->fetch(NULL, NULL, NULL, NULL, false, false, true) #1 /.../cache/smarty/compile/b03dbc499d5325bdfb18ddc055194e31de46abc4.file.product.tpl.php(31): Smarty_Internal_Template->getSubTemplate('/var/www/newsto...', NULL, NULL, NULL, NULL, Array, 0) #2 /.../tools/smarty/sysplugins/smarty_internal_templatebase.php(180): content_519dc2824b9328_66230757(Object(Smarty_Internal_Template) in /.../tools/smarty/sysplugins/smarty_internal_templatebase.php on line 127

 

What baffles me, is it doesn't happen on my localhost development setup?

Edited by [email protected] (see edit history)
Link to comment
Share on other sites

Hi guys, sorry for the issue there yaniv14, I'm busy redoing the server setup on a different EC2 machine, os that link is offline for now. Nonetheless, here's my virtual host setup:

 

NameVirtualHost *:80
<VirtualHost *:80>
ServerName localhost
DocumentRoot "/..."
<Directory "/...">
 Options Indexes FollowSymLinks MultiViews
 AllowOverride All
 Order allow,deny
 Allow from all
</Directory>
</VirtualHost>
<VirtualHost *:80>
   ServerName newstore.personera.dev
   DocumentRoot "/.../newstore.personera.dev"
   ErrorLog "/.../newstore.personera.dev/log/errors.log"
   CustomLog "/.../newstore.personera.dev/log/access.log" common
   LogLevel debug
   <Directory "/.../newstore.personera.dev">
    Options Indexes FollowSymLinks MultiViews
    AllowOverride All
    Order allow,deny
    Allow from all
   </Directory>
   <IfModule mod_headers.c>
    Header set Access-Control-Allow-Origin "*"
   </IfModule>
</VirtualHost>
<IfModule mod_ssl.c>
<VirtualHost *:443>
   ServerName newstore.personera.dev
   DocumentRoot "/.../newstore.personera.dev"
   ErrorLog "/.../newstore.personera.dev/log/ssl-errors.log"
   CustomLog "/.../newstore.personera.dev/log/ssl-access.log" combined
   LogLevel debug
   <Directory "/.../newstore.personera.dev">
    Options Indexes FollowSymLinks MultiViews
    AllowOverride All
    Order allow,deny
    Allow from all
   </Directory>
   <IfModule mod_headers.c>
    Header set Access-Control-Allow-Origin "*"
   </IfModule>
   SSLEngine on
   SSLCertificateFile /.../server.crt
   SSLCertificateKeyFile /.../server.key
</VirtualHost>
</IfModule>

Link to comment
Share on other sites

I don't understand your virtual host setup,

ServerName newstore.personera.dev -> what is that?

DocumentRoot "/.../newstore.personera.dev"

why is the DocumentRoot inside double quote? is it working like that?

did you activated the host? (a2ensite)

Link to comment
Share on other sites

I don't understand your virtual host setup,

ServerName newstore.personera.dev -> what is that?

DocumentRoot"/.../newstore.personera.dev"

why is the DocumentRoot inside double quote? is it working like that?

did you activated the host? (a2ensite)

 

The live site reads newstore.personera.com, apologies but it seems I copied my development machine virtual host config, which is essentially exactly the same as the test site, except for the file paths and server names. The virtual host has been activated, otherwise I wouldn't see the home page as I previously mentioned, however the site is in limbo at this point in time.

 

The double quotes are a bad habit I have, and is needed when you have spaces in your paths (a very bad practice which I avoid at ALL costs). The double quotes don't invalidate the Virtual Host setup in any way, but I guess it's a bit cleaner without them.

 

I'm moving the site to a more appropriate testing server where I can go nuts with the setup. So far I've installed a fresh copy of PrestaShop 1.5.4.1 and installing our custom modules one by one to determine where the problem could potentially be.

 

I've also found a LOT of overrides written by my predecessors where I work now, so moving those into corresponding modules where they belong. Prestashop needs to modify the overrides upon module (un)installation.

Link to comment
Share on other sites

×
×
  • Create New...