Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Checkout_process.php Never Finish


sialivi

Recommended Posts

Posted

When confirming an order (on checkout_confirmation.php) it starts to load checkout_process.php but it never finishes.

 

The only lines that stand out in my server logs are:

"Terminating 23 threads that failed to exit" and "Maximum execution time exceeded .. in sessions.php"

 

Notes:

* I don't use SSL

* The payment module used was "Bankgiro"

* I saw a post about someone who had the same symptoms and solved it by deactivating sending e-mail, but that made no difference for me

 

Any help would be greatly appreciated.

Posted
Thanks, but I have searched the forums and haven't had much luck so far

if your email is not working it would cause a delay. Did you comment out the tep_mail calls to test it? Put some echo/die statements in checkout_process.php to locate the place where the scripts stucks. That can give you a clue.

Posted

I've narrowed it down to checkout_process.php line 96:

 

tep_db_perform(TABLE_ORDERS, $sql_data_array);

Posted

ok right after that line you should have one that states:

 

$insert_id = tep_db_insert_id();

 

Echo the $insert_id to see what it says. One other note is to check the persistent connections in the includes\configure.php Set it to false.

define('USE_PCONNECT', 'false'); // use persistent connections?

Posted

It doesn't reach that line, it's the line I pasted that it gets stuck on.

 

I'm going to check persistent connections right away, really appreciate your help, thanks

Posted

ok can you post your checkout_process.php at least up to the line where it stucks. Just in case the sql_data array is not setup properly.

 

Another thing you could try is to use the stock checkout_process.php (backup the one you have) and test it.

Posted

I believe this is the stock version, and it used to work on the old server.

 

The only difference between the servers that I know of is that the old one used php4+mysql4 and the new one uses php5+mysql5 (with register globals and long arrays enabled)

Posted

ok use phpmyadmin, go to the orders table see what it shows as the next autoincrement value. Should be a reference like next autoindex or something. See if that value is correct. And check if the orders_id column in that table is set to auto-increment.

 

Shouldn't be a problem for osc I have it running with php5/mysql5 properly (and register globals off).

Posted

your host should include it. What the actual value of the next autoincrement. You need to check that. If it's -1 for example is invalid and can cause problems.

Posted

Trying to find where in database.php it hangs and it's a bit weird.

 

tep_db_perform works fine until it's very last line: return tep_db_query($query, $link);

tep_db_query seems to work fine, since I can put an echo right before it's return statement.

 

So I went back to tep_db_perform and added an echo of what tep_db_query returns, and it hanged

So I assigned what it returned to a variable, $test = tep_db_query($query, $link);, and it hanged

 

I don't know enough about php to figure out why this happens

Posted

dedicated servers usually include it, anyways is very easy to install it

http://www.phpmyadmin.net/home_page/index.php

there is a configuration file that needs to be altered to match your server setting pretty much like oscommerce does. Just set it up then you can see the tables. You could install it beneath the osc admin folder if you're unsure how to set it up with a different sub-domain under your server.

Posted

no idea, but if you had phpmyadmin installed you could check if the sql goes through from the tool and you could had tested the tables if they're ok.

Posted

Thanks for your help, the problem has been fixed. It was a database field that didn't have a default value. Was expecting such an error to show up as a sql error, not just hang.

  • 2 years later...
Posted

Thanks for your help, the problem has been fixed. It was a database field that didn't have a default value. Was expecting such an error to show up as a sql error, not just hang.

 

I wish you would've said which database field, because I am having the same issue.

It works fine with PayPal payments, just not with "PayPal Website Payments Pro U.S."

 

It must have something to do with the server or database as this is a copy of another webshop I have, just a different server.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...