Etienne PL Posted September 8, 2019 Share Posted September 8, 2019 (edited) Hello, I encounter a problem when I enable the friendly URL on prestashop: I get an error 500 when I try to access to the backoffice. Enabling the debug mode allows me to access the backoffice login page, to log in and to perform any task there. Though I don't block non-Prestashop modules when enabling the debug mode. I checked my config and compared it to the standard one here and I don't see any significant difference. The only one being that I have MySQL instead of MariaDB. Installation type (new/update): PrestaShop version: 1.7.5.1 Theme (default/customized): PRSADD075 by TemplateMela Code (original/modified): Hosting: OVH PHP version: 7.0.33 (I tried with 7.2 it didn't work better) MySQL version: 5.6.42-log Browser(s) concerned: All Here is myserver config: PHP Version 7.0.33 System Linux webm260.cluster027.gra.hosting.ovh.net 4.14.119-ovh-vps-grsec-zfs-classid #1 SMP Wed May 15 10:40:34 CEST 2019 x86_64 Build Date May 21 2019 21:35:41 Configure Command './configure' '--with-openssl' '--enable-memcached' '--prefix=/usr/local/php7.0' '--enable-fpm' '--enable-opcache' '--enable-redis' '--with-gd' '--enable-intl' '--enable-gd-native-ttf=/usr' '--with-png-dir=/usr' '--enable-wddx' '--with-config-file-path=/usr/local/php7.0/etc' '--enable-sigchild' '--enable-short-tags' '--disable-rpath' '--enable-libgcc' '--with-zlib=/usr' '--enable-bcmath' '--enable-calendar' '--with-curl=/usr' '--with-gdbm=/usr' '--enable-ftp' '--with-gettext=/usr' '--with-imap=/usr' '--with-kerberos' '--with-imap-ssl=/usr' '--with-mcrypt=/usr' '--with-mhash=/usr' '--with-jpeg-dir=/usr' '--enable-exif' '--enable-sysvsem' '--enable-sysvshm' '--enable-sysvmsg' '--enable-zip' '--enable-inline-optimization' '--enable-soap' '--enable-mbstring' '--enable-mbregex' '--with-gnu-ld' '--with-libxml-dir' '--enable-shared=yes' '--enable-static=yes' '--with-xsl=/usr' '--enable-sockets' '--with-xmlrpc' '--with-iconv' '--with-imagick' '--enable-pdo' '--with-pdo-pgsql=external/libpq/usr' '--enable-mongodb' '--with-xpm-dir=/usr' '--with-pcre-regex' '--with-freetype-dir=/usr' '--with-pspell' '--with-pgsql=external/libpq/usr' '--with-bz2' '--with-gmp' 'EXTENSION_DIR=/usr/local/php7.0/lib/php-extensions' '--with-mysqli=mysqlnd' '--with-pdo-mysql=mysqlnd' Server API FPM/FastCGI Virtual Directory Support disabled Configuration File (php.ini) Path /usr/local/php7.0/etc Loaded Configuration File /images/stable/usr/local/php-config/7.0/php-fpm.ini Scan this dir for additional .ini files (none) Additional .ini files parsed (none) PHP API 20151012 PHP Extension 20151012 Zend Extension 320151012 Zend Extension Build API320151012,NTS PHP Extension Build API20151012,NTS Debug Build no Thread Safety disabled Zend Signal Handling disabled Zend Memory Manager enabled Zend Multibyte Support provided by mbstring IPv6 Support enabled DTrace Support disabled Registered PHP Streams https, ftps, compress.zlib, compress.bzip2, php, file, glob, data, http, ftp, phar, zip Registered Stream Socket Transports tcp, udp, unix, udg, ssl, tls, tlsv1.0, tlsv1.1, tlsv1.2 Registered Stream Filters zlib.*, bzip2.*, convert.iconv.*, mcrypt.*, mdecrypt.*, string.rot13, string.toupper, string.tolower, string.strip_tags, convert.*, consumed, dechunk Core PHP Version 7.0.33 Directive Local Value Master Value allow_url_fopen On On allow_url_include Off Off arg_separator.input & & arg_separator.output & & auto_append_file no value no value auto_globals_jit On On auto_prepend_file no value no value browscap no value no value default_charset UTF-8 UTF-8 default_mimetype text/html text/html disable_classes no value no value disable_functions _dyuweyrj4,_dyuweyrj4r,dl _dyuweyrj4,_dyuweyrj4r,dl display_errors Off Off display_startup_errors Off Off doc_root no value no value docref_ext no value no value docref_root no value no value enable_dl On On enable_post_data_reading On On error_append_string no value no value error_log no value no value error_prepend_string no value no value error_reporting 32759 32759 exit_on_timeout Off Off expose_php On On extension_dir ./ ./ file_uploads On On highlight.comment #FF9900 #FF9900 highlight.default #0000CC #0000CC highlight.html #000000 #000000 highlight.keyword #006600 #006600 highlight.string #CC0000 #CC0000 html_errors On On ignore_repeated_errors Off Off ignore_repeated_source Off Off ignore_user_abort Off Off implicit_flush Off Off include_path .:/usr/local/php7.0/lib/php .:/usr/local/php7.0/lib/php input_encoding no value no value internal_encoding no value no value log_errors Off Off log_errors_max_len 1024 1024 mail.add_x_header On On mail.force_extra_parameters no value no value mail.log no value no value max_execution_time 300 300 max_file_uploads 20 20 max_input_nesting_level 64 64 max_input_time -1 -1 max_input_vars 16000 16000 memory_limit 512M 512M open_basedir no value no value output_buffering 4096 4096 output_encoding no value no value output_handler no value no value post_max_size 130M 130M precision 14 14 realpath_cache_size 2M 2M realpath_cache_ttl 300 300 register_argc_argv On On report_memleaks On On report_zend_debug On On request_order no value no value sendmail_from [email protected] [email protected] sendmail_path /usr/sbin/sendmail -t -i /usr/sbin/sendmail -t -i serialize_precision 17 17 short_open_tag On On SMTP localhost localhost smtp_port 25 25 sql.safe_mode Off Off sys_temp_dir no value no value track_errors Off Off unserialize_callback_func no value no value upload_max_filesize 128M 128M upload_tmp_dir no value no value user_dir no value no value user_ini.cache_ttl 300 300 user_ini.filename .user.ini .user.ini variables_order EGPCS EGPCS xmlrpc_error_number 0 0 xmlrpc_errors Off Off zend.assertions 1 1 zend.detect_unicode On On zend.enable_gc On On zend.multibyte Off Off zend.script_encoding no value no value Here is my htaccess: # ~~start~~ Do not remove this comment, Prestashop will keep automatically the code outside this comment when .htaccess will be generated again # .htaccess automaticaly generated by PrestaShop e-commerce open-source solution # http://www.prestashop.com - http://www.prestashop.com/forums <IfModule mod_rewrite.c> <IfModule mod_env.c> SetEnv HTTP_MOD_REWRITE On </IfModule> RewriteEngine on #Domain: www.paboma-konie.com RewriteRule . - [E=REWRITEBASE:/] RewriteRule ^api$ api/ [L] RewriteRule ^api/(.*)$ %{ENV:REWRITEBASE}webservice/dispatcher.php?url=$1 [QSA,L] # Images RewriteCond %{HTTP_HOST} ^www.paboma-konie.com$ RewriteRule ^([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$1$2$3.jpg [L] RewriteCond %{HTTP_HOST} ^www.paboma-konie.com$ RewriteRule ^([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$1$2$3$4.jpg [L] RewriteCond %{HTTP_HOST} ^www.paboma-konie.com$ RewriteRule ^([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$1$2$3$4$5.jpg [L] RewriteCond %{HTTP_HOST} ^www.paboma-konie.com$ RewriteRule ^([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$1$2$3$4$5$6.jpg [L] RewriteCond %{HTTP_HOST} ^www.paboma-konie.com$ RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$1$2$3$4$5$6$7.jpg [L] RewriteCond %{HTTP_HOST} ^www.paboma-konie.com$ RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$6/$1$2$3$4$5$6$7$8.jpg [L] RewriteCond %{HTTP_HOST} ^www.paboma-konie.com$ RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$6/$7/$1$2$3$4$5$6$7$8$9.jpg [L] RewriteCond %{HTTP_HOST} ^www.paboma-konie.com$ RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$6/$7/$8/$1$2$3$4$5$6$7$8$9$10.jpg [L] RewriteCond %{HTTP_HOST} ^www.paboma-konie.com$ RewriteRule ^c/([0-9]+)(\-[\.*_a-zA-Z0-9-]*)(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/c/$1$2$3.jpg [L] RewriteCond %{HTTP_HOST} ^www.paboma-konie.com$ RewriteRule ^c/([a-zA-Z_-]+)(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/c/$1$2.jpg [L] # AlphaImageLoader for IE and fancybox RewriteRule ^images_ie/?([^/]+)\.(jpe?g|png|gif)$ js/jquery/plugins/fancybox/images/$1.$2 [L] # Dispatcher RewriteCond %{REQUEST_FILENAME} -s [OR] RewriteCond %{REQUEST_FILENAME} -l [OR] RewriteCond %{REQUEST_FILENAME} -d RewriteRule ^.*$ - [NC,L] RewriteRule ^.*$ %{ENV:REWRITEBASE}index.php [NC,L] </IfModule> AddType application/vnd.ms-fontobject .eot AddType font/ttf .ttf AddType font/otf .otf AddType application/font-woff .woff AddType font/woff2 .woff2 <IfModule mod_headers.c> <FilesMatch "\.(ttf|ttc|otf|eot|woff|woff2|svg)$"> Header set Access-Control-Allow-Origin "*" </FilesMatch> </IfModule> <IfModule mod_expires.c> ExpiresActive On ExpiresByType image/gif "access plus 1 month" ExpiresByType image/jpeg "access plus 1 month" ExpiresByType image/png "access plus 1 month" ExpiresByType text/css "access plus 1 week" ExpiresByType text/javascript "access plus 1 week" ExpiresByType application/javascript "access plus 1 week" ExpiresByType application/x-javascript "access plus 1 week" ExpiresByType image/x-icon "access plus 1 year" ExpiresByType image/svg+xml "access plus 1 year" ExpiresByType image/vnd.microsoft.icon "access plus 1 year" ExpiresByType application/font-woff "access plus 1 year" ExpiresByType application/x-font-woff "access plus 1 year" ExpiresByType font/woff2 "access plus 1 year" ExpiresByType application/vnd.ms-fontobject "access plus 1 year" ExpiresByType font/opentype "access plus 1 year" ExpiresByType font/ttf "access plus 1 year" ExpiresByType font/otf "access plus 1 year" ExpiresByType application/x-font-ttf "access plus 1 year" ExpiresByType application/x-font-otf "access plus 1 year" </IfModule> <IfModule mod_headers.c> Header unset Etag </IfModule> FileETag none <IfModule mod_deflate.c> <IfModule mod_filter.c> AddOutputFilterByType DEFLATE text/html text/css text/javascript application/javascript application/x-javascript font/ttf application/x-font-ttf font/otf application/x-font-otf font/opentype image/svg+xml </IfModule> </IfModule> #If rewrite mod isn't enabled ErrorDocument 404 /index.php?controller=404 # ~~end~~ Do not remove this comment, Prestashop will keep automatically the code outside this comment when .htaccess will be generated again Do you know how to solve the problem? Etienne Edited September 12, 2019 by Etienne PL Improve description (see edit history) Link to comment Share on other sites More sharing options...
korfezguvenlik Posted September 8, 2019 Share Posted September 8, 2019 (edited) i think all problem from php version pls change your PHP versipn Php 7.2 Cpanel / Multiphp select your domain and php version... Edited September 8, 2019 by korfezguvenlik (see edit history) Link to comment Share on other sites More sharing options...
Etienne PL Posted September 8, 2019 Author Share Posted September 8, 2019 I just changed the version from 7 to 7.2 and I have the same error 500 when connecting to the backoffice. Do you have other suggestions? Link to comment Share on other sites More sharing options...
korfezguvenlik Posted September 8, 2019 Share Posted September 8, 2019 6 hours ago, Ouaich Magueule said: I just changed the version from 7 to 7.2 and I have the same error 500 when connecting to the backoffice. Do you have other suggestions? Link to comment Share on other sites More sharing options...
korfezguvenlik Posted September 8, 2019 Share Posted September 8, 2019 /config/defines.inc.php” define('_PS_MODE_DEV_', false); to define('_PS_MODE_DEV_', true); you see your real error Link to comment Share on other sites More sharing options...
korfezguvenlik Posted September 8, 2019 Share Posted September 8, 2019 (edited) also i think all error 500 relevant hosting... or conflicts with your last installed modules Edited September 8, 2019 by korfezguvenlik (see edit history) Link to comment Share on other sites More sharing options...
Etienne PL Posted September 9, 2019 Author Share Posted September 9, 2019 Hello, I know how to enable the debug mode. My questions are: 1- How to make the friendly URL work when enabling the friendly URL? 2(lower priority)- How could I see the logs when I am not in debug mode? Link to comment Share on other sites More sharing options...
korfezguvenlik Posted September 9, 2019 Share Posted September 9, 2019 (edited) 6 hours ago, Ouaich Magueule said: Hello, I know how to enable the debug mode. My questions are: 1- How to make the friendly URL work when enabling the friendly URL? 2(lower priority)- How could I see the logs when I am not in debug mode? it is itself.. you don't have to do anything only store parameters / Seo & URL / Enabled Friendly URL 2. Cpanel error logs Edited September 9, 2019 by korfezguvenlik (see edit history) Link to comment Share on other sites More sharing options...
Etienne PL Posted September 11, 2019 Author Share Posted September 11, 2019 Thanks for your answer but as explained, the problem is to have a working backoffice when enabling friendly URL. Someone knows the problem and how to solve it? Link to comment Share on other sites More sharing options...
Etienne PL Posted September 11, 2019 Author Share Posted September 11, 2019 Any idea? Link to comment Share on other sites More sharing options...
korfezguvenlik Posted September 11, 2019 Share Posted September 11, 2019 (edited) Just now, Etienne PL said: Herhangi bir fikir? try my .httpacces https://korfezguvenlik.net/kocaeli/ kocaeli kamera sistemleri (download and edit for your domain) also open_basedir = Disable Edited September 11, 2019 by korfezguvenlik (see edit history) Link to comment Share on other sites More sharing options...
Etienne PL Posted September 12, 2019 Author Share Posted September 12, 2019 15 hours ago, korfezguvenlik said: try my .httpacces https://korfezguvenlik.net/kocaeli/ kocaeli kamera sistemleri (download and edit for your domain) also open_basedir = Disable I tryed both changes, it didn't work as well. Link to comment Share on other sites More sharing options...
selectshop.at Posted September 14, 2019 Share Posted September 14, 2019 500 error is an server error. Did you read also the server error logs (not Prestashop logs!!)? They should give you a hint about the problem. If you don't have access to them, contact your provider. Seems that mod_rewrite is not running on your server (misconfiguration or something you are using is not running with mod_rewrite). 1 Link to comment Share on other sites More sharing options...
Recommended Posts