PDA

View Full Version : 500 Internal Server Error



getdata
June 25th, 2003, 10:03 PM
Out of all the categories to post this message, this seemed like the most logical one. Any and all help will be duly appreciated.

Background: I installed the Squirrelcart shopping cart system in my latest site. After running through typical install and setup issues, the cart performance evened out during testing. Test orders were being entered and processed. Order confirmation emails were being sent to the my order admin via email and to the customer address for confirmation. Credit cards were being run without issue and inventory decremented.

Present day: Fast forword 2 weeks and I am beginning to receive 500 Internal Server Errors at the order submittal page (the very last page of the shopping cart order entry process). I have made zero changes to the htaccess files and i have not made any adjustments to the CHMOD settings on any of the cart files. For the life of me I don't know why I am getting this error.

I pinged my host tech support, but was kindly reminded that they don't trouble shoot scripts etc. Has anyone else had anything like this or have an idea to fix?

Here is the copy of the error message, it looks pretty standard.



https://www03.powweb.com:10972/bri/order/online_order.php?payment_info=1

500 Internal Server Error

--------------------------------------------------------------------------------

There has been an error in processing your request. Please contact support@powweb.com with a brief description of your problem and what you were doing at the time.

--------------------------------------------------------------------------------



PowWeb Hosting WebMasters

--------------------------------------------------------------------------------


Webmasters, if you are having problems getting CGI, SSI or PHP scripts to work or need additional information such as paths to popular programs, please check the following before contacting PowWeb Technical Support.


Please check your error_log in your logs directory. If you do not have an error_log, please make sure logging is enabled for your website.
Please consult our CGI/SSI and PHP Category in Our Frequently Asked Questions.
Please make sure your script and directory pemissions are properly configuered as stated in our FAQ's.
If you do not want this Error Page, you can use the ErrorDocument redirect directive in your .htaccess file.

Sincerely,
PowWeb Development Staff


Like I said above, any help or assistance would be appreciated. Thanks in advance.

Rich
June 26th, 2003, 12:18 PM
Here is the copy of the error message, it looks pretty standard.You're right, it is pretty standard, and unfortunately could mean anything.
Please check your error_log in your logs directory. If you do not have an error_log, please make sure logging is enabled for your website.Can you get us the exact error message from your logs?

gtroll
June 26th, 2003, 03:27 PM
Here is a custom error file
just change the e-mail addy to yours
and ad this line to your .htaccess
ErrorDocument 500 /500.php
see if that helps debug your problem

getdata
June 26th, 2003, 04:55 PM
Gtroll, thanks. I will check my error logs when I get back into the office tonight. If there isn't any usable data I will use your custom file. I appreciate the follow-up.

I don't know if it makes any difference, but even with the error, the sales are recorded and the email confirms are sent. So it is doing the work (or at least the visible work), but not directing to the Thank You page.

gtroll
June 26th, 2003, 05:16 PM
Gtroll, thanks.
no problem, glad to help
>snip

So it is doing the work (or at least the visible work), but not directing to the Thank You page.
hmmmm....

getdata
June 26th, 2003, 05:31 PM
Copied from PM from Gtroll who is working overtime :)



You are using a server name that starts with www3. this code from squirrelcart/cart.php doesn't account for that possibility

Code:--------------------------------------------------------------------------------line 106 squirrelcart/cart.php
// determine if SESSID needs to be passed to secure page...
// strip out protocol in URL, ...
$www_compare = $SESSION['site_www_root'];
$www_compare = str_replace("http://","",$www_compare);
$www_compare = str_replace("www.","",$www_compare);
$www_compare = str_replace("/","",$www_compare);
$www_compare = strtolower($www_compare);
$ssl_compare = $SESSION['site_secure_root'];
$ssl_compare = str_replace("https://","",$ssl_compare);
$ssl_compare = str_replace("http://","",$ssl_compare);
$ssl_compare = str_replace("www.","",$ssl_compare);
$ssl_compare = str_replace("/","",$ssl_compare);
$ssl_compare = strtolower($ssl_compare);
if($www_compare != $ssl_compare) $SESSION['send_sid'] = 1;
--------------------------------------------------------------------------------
You think this might be the source of your prob?


man...I don't know. That question is approaching (or past) by knowledge or experience level.

I will check my error logs or use your code and post the results. It will be a few hours until I can do that though.

gtroll
June 26th, 2003, 05:40 PM
Copied from PM from Gtroll who is working overtime
I'm learning while I'm helping so no problem TTYL

getdata
June 27th, 2003, 01:32 PM
OK. I think it is working now. In the store setup where you can define where you want the email order confirm to be sent, I had defined two addresses that I thought had been split by a comma. Looks like I fat fingered in a period instead.

Ran a few test orders through and it seems to work correctly now.

Gotta fix my error logs -- they seem to have quit recording back on 6/22 but that is another story all together.

Much thanks to Gtroll and Rich for some good advice.

Thanks,
GETDATA