Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Problem with ading to Cart..


davec1031

Recommended Posts

I get this error after adding something to the cart when doing a test purchase:

 

Warning: Division by zero in /homepages/17/d144609194/htdocs/valkyriesreign/includes/application_top.php on line 477

 

Warning: Cannot modify header information - headers already sent by

(output started at /homepages/17/d144609194/htdocs/valkyriesreign/includes/application_top.php:477)

in /homepages/17/d144609194/htdocs/valkyriesreign/includes/functions/general.php on line 33

 

 

 

If anyone knows how i can fix this, please let me know.. it's the only thing keeping me from starting the site up..

 

Thanks in advance

Link to comment
Share on other sites

For some reason, i couldn't edit it again.. but here is the info

 

From Aplication_top.php:

Text with arrow is the line 477

 

	  // customer wants to update the product quantity in their shopping cart
  case 'update_product' : for ($i=0; $i<sizeof($HTTP_POST_VARS['products_id']);$i++) {
							if (in_array($HTTP_POST_VARS['products_id'][$i], (is_array($HTTP_POST_VARS['cart_delete']) ? $HTTP_POST_VARS['cart_delete'] : array()))) {
							  $cart->remove($HTTP_POST_VARS['products_id'][$i]);	  <------- Line 477
							} else {
							  if (PHP_VERSION < 4) {
								// if PHP3, make correction for lack of multidimensional array.
								reset($HTTP_POST_VARS);
								while (list($key, $value) = each($HTTP_POST_VARS)) {
								  if (is_array($value)) {
									while (list($key2, $value2) = each($value)) {
									  if (ereg ("(.*)\]\[(.*)", $key2, $var)) {
										$id2[$var[1]][$var[2]] = $value2;
									  }
									}
								  }
								}

Link to comment
Share on other sites

Ok i was testing the cart, trying to see if it worked ok, just adding some items to the cart, and as soon as i went to hit add to cart on the first item, it just went to that message..

 

Warning: Division by zero in /homepages/17/d144609194/htdocs/valkyriesreign/includes/application_top.php on line 477

Warning: Cannot modify header information - headers already sent by (output started at /homepages/17/d144609194/htdocs/valkyriesreign/includes/application_top.php:477) in /homepages/17/d144609194/htdocs/valkyriesreign/includes/functions/general.php on line 33

 

So if thier is any file someone needs to see i will post it here..

 

any help would be awsome, the site is nearly finished, and needs stock!! ehehe I want it to be working when it goes live!

if you want check out the site, and see if it is doing it for you.

 

http://www.valkyriesreign.com

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...