Jump to content

_a=gateway NO gateways show


Recommended Posts



I have just migrated from one host to another - all went fine and all apparently worked, that is until the first customer after the migration tried to order


When clciking the payment button he would normally be moved to the gateway choice page - instead of this he gets a server 500 error

ALL files have been transferred correct and the database is intact and works just fine


Only issue is the payment gateways that does not show up when trying to pay......?


Anybody outthere having an idea that can help me?


Issue:  "index.php?_a=gateway - produces server 500 error"



Link to comment
Share on other sites

I get this output:


[19-Jun-2020 19:59:59 UTC] PHP Warning:  preg_match() [<a href='http://docs.php.net/manual/en/function.preg-match.php'>function.preg-match.php</a>]: The /e modifier is no longer supported, use preg_replace_callback instead in /usr/www/users/xxxxx/classes/seo.class.php on line 613


Line 613 says:

if (preg_match('#^(.*/)?[\w]+.[a-z]+\?_a\=([\w]+)(?:\&(amp;)?([\w\[\]]+)\=([\w\-\_]+)([^"\']*))$#ieS', $path, $match)) {

Edited by Muscator
Link to comment
Share on other sites

So, I see that you are using a version of CubeCart several versions old. Running an older CubeCart is not a big deal, unless your new environment is running PHP 7. There may be other warnings and notices.

This Warning will not crash PHP (if a crash, the web server will report a 500 error because of it).

This SEO function is used by many other routines in CubeCart. It is strange that it only appeared once.

Was there anything in admin, Error Log, System Error Log tab?

Edited by bsmither
Link to comment
Share on other sites

It has several lines that says the same - actually the error log has been running for 2 years, since the original install, with absolutely no problems - it also ran on the old server until 2 days ago with no problems


Right now I just tried to go back to PHP 5.6 from the present 7.3, just to see if it had any effect - still same error 500 blank page

Hmnn - after going back to PHP5.6 the new following error occurred:


[19-Jun-2020 22:45:53 Europe/Copenhagen] PHP Warning:  Shipping not setup or allow no shipping not enabled in /usr/www/users/xxxx/classes/cubecart.class.php on line 1675
[19-Jun-2020 22:45:56 Europe/Copenhagen] PHP Warning:  Shipping not setup or allow no shipping not enabled in /usr/www/users/xxxx/classes/cubecart.class.php on line 1675
[19-Jun-2020 22:46:36 Europe/Copenhagen] PHP Fatal error:  require_once() [<a href='http://docs.php.net/manual/en/function.require.php'>function.require.php</a>]: Failed opening required '/home/testshop/public_html/includes/lib/smarty/plugins/modifier.replace.php' (include_path='.:/usr/local/lib/php/') in /usr/www/users/xxx/cache/skin/013463d28fb18a8fc0c766ac6b3777fc1a45f311_0.string.php on line 18


Hmmn - I can also see that it tries to fetch something from the old host - the part that says /home/testshop... Where do that come from and how can I modify it to show the present path?

Link to comment
Share on other sites

In your hosting control panel, there may be a feature where you can look at error logs.

We need to find a log that has captured why the server issued a 500 error. It could be caused by PHP crashing, or (happens often enough) if there is a directive in the .htaccess file (in CubeCart's main folder) that the web server cannot parse, or an environmental security rule that triggered a fault.

If there are no logs available to you that would explain a .htaccess directive fault, or security rule trigger, you may need to have your hosting provider tech support scan their logs.

Link to comment
Share on other sites

here´s the .htaccess:


##### START CubeCart .htaccess #####

### File Security ###
<FilesMatch "\.(htaccess)$">
  Order Allow,Deny
  Deny from all

### Apache directory listing rules ###
DirectoryIndex index.php index.htm index.html
IndexIgnore *

<ifModule mod_headers.c>
  Header always append X-Frame-Options SAMEORIGIN

### Rewrite rules for SEO functionality ###
<IfModule mod_rewrite.c>
  RewriteEngine On
  RewriteBase /
  RewriteCond %{QUERY_STRING} (.*)$
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteRule cat_([0-9]+)(\.[a-z]{3,4})?(.*)$ index.php?_a=category&cat_id=$1&%1 [NC]

  RewriteCond %{QUERY_STRING} (.*)$
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteRule prod_([0-9]+)(\.[a-z]{3,4})?$ index.php?_a=product&product_id=$1&%1 [NC]

  RewriteCond %{QUERY_STRING} (.*)$
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteRule info_([0-9]+)(\.[a-z]{3,4})?$ index.php?_a=document&doc_id=$1&%1 [NC]

  RewriteCond %{QUERY_STRING} (.*)$
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteRule tell_([0-9]+)(\.[a-z]{3,4})?$ index.php?_a=product&product_id=$1&%1 [NC]

  RewriteCond %{QUERY_STRING} (.*)$
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteRule _saleItems(\.[a-z]+)?(\?.*)?$ index.php?_a=saleitems&%1 [NC,L]

  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteCond %{REQUEST_URI} !=/favicon.ico
  RewriteRule ^(.*)\.html?$ index.php?seo_path=$1 [L,QSA]

### Default store 404 page ###
ErrorDocument 404 /index.php

## Override default 404 error document for missing page resources ##
<FilesMatch "\.(gif|jpe?g|png|ico|css|js|svg)$">
  ErrorDocument 404 "<html></html>
##### END CubeCart .htaccess #####

Link to comment
Share on other sites

I just reloaded your prior post with new content added.

PHP Fatal error:  require_once():
Failed opening required '/home/testshop/public_html/includes/lib/smarty/plugins/modifier.replace.php'
in /usr/www/users/xxx/cache/skin/013463d28fb18a8fc0c766ac6b3777fc1a45f311_0.string.php on line 18

This suggests that when the move to a new host was made, all the stuff in the /cache/ folder came along with it. That will probably cause problems.

Please have CubeCart clear its internal cache (in admin, top-right corner is a button to do so).

  • Thanks 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Create New...