Guest Posted January 12, 2004 Share Posted January 12, 2004 I'm having problems adding this in to a clean install. It keeps returning a parse error (amongst other things but first things first) and I saw on another thread where someone thought a semicolon was missing but I'm not finding it. I'm including the code in context from the application_top file and have tried adding it in bits and pieces to get a better idea of where the error is with no luck (which makes me wonder if there is more than one?), any suggestions? $HTTP_GET_VARS['pid'])); } else { $cart->add_cart($HTTP_GET_VARS['pid'], $cart->get_quantity($HTTP_GET_VARS['pid'])+1); } } tep_redirect(tep_href_link($goto, tep_get_all_get_params($parameters))); break; } } //Wishlist define('FILENAME_WISHLIST', 'wishlist.php'); define('FILENAME_WISHLIST_HELP', 'wishlist_help.php'); //Wishlist define('TABLE_WISHLIST', 'customers_wishlist'); //beginning of wishlist case 'cust_order' : if (tep_session_is_registered('customer_id') && isset($HTTP_GET_VARS['pid'])) { if (tep_has_product_attributes($HTTP_GET_VARS['pid'])) { tep_redirect(tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $HTTP_GET_VARS['pid'])); } else { tep_db_query("delete from " . TABLE_WISHLIST . " where products_id = '" . $HTTP_GET_VARS['pid'] . "' and customers_id = '" . $customer_id . "'"); $cart->add_cart($HTTP_GET_VARS['pid'], $cart->get_quantity($HTTP_GET_VARS['pid'])+1); } } tep_redirect(tep_href_link($goto, tep_get_all_get_params($parameters))); // Add product to the wishlist case 'add_wishlist' : if (ereg('^[0-9]+$', $HTTP_POST_VARS['products_id'])) { if ($HTTP_POST_VARS['products_id']) { tep_db_query("delete from " . TABLE_WISHLIST . " where products_id = '" . $HTTP_GET_VARS['products_id'] . "' and customers_id = '" . $customer_id . "'"); tep_db_query("insert into " . TABLE_WISHLIST . " (customers_id, products_id, products_model, products_name, products_price) values ('" . $customer_id . "', '" . $products_id . "', '" . $products_model . "', '" . $products_name . "', '" . $products_price . "' )"); } } tep_redirect(tep_href_link(FILENAME_WISHLIST)); break; // Add wishlist item to the cart case 'wishlist_add_cart': reset ($lvnr); reset ($lvanz); while (list($key,$elem) =each ($lvnr)) { (list($key1,$elem1) =each ($lvanz)); tep_db_query("update " . TABLE_WISHLIST . " SET products_quantity=$elem1 WHERE customers_id=$customer_id AND products_id=$elem"); tep_db_query("delete from " . TABLE_WISHLIST . " WHERE customers_id=$customer_id AND products_quantity='999'"); $produkte_mit_anzahl=tep_db_query("select * from " . TABLE_WISHLIST . " WHERE customers_id=$customer_id AND products_id=$elem AND products_quantity<>'0'"); while ($HTTP_POST_VARS=mysql_fetch_array($produkte_mit_anzahl)) { $cart->add_cart($HTTP_POST_VARS['products_id'], $HTTP_POST_VARS['products_quantity']); } } reset ($lvanz); tep_redirect(tep_href_link(FILENAME_WISHLIST)); break; // remove item from the wishlist case 'remove_wishlist' : tep_db_query("delete from " . TABLE_WISHLIST . " where products_id = '" . $HTTP_GET_VARS['pid'] . "' and customers_id = '" . $customer_id . "'"); tep_redirect(tep_href_link(FILENAME_WISHLIST)); break; // performed by the 'buy now' button in product listings and review page case 'buy_now' : if (tep_session_is_registered('customer_id')) { tep_db_query("delete from " . TABLE_WISHLIST . " WHERE customers_id=$customer_id AND products_id=$products_id"); } if (tep_has_product_attributes($HTTP_GET_VARS['products_id'])) { tep_redirect(tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $HTTP_GET_VARS['products_id'], 'NONSSL')); } else { $cart->add_cart($HTTP_GET_VARS['products_id'], $cart->get_quantity($HTTP_GET_VARS['products_id'])+1); tep_redirect(tep_href_link(FILENAME_WISHLIST)); } break; } } // include the who's online functions require(DIR_WS_FUNCTIONS . 'whos_online.php'); tep_update_whos_online(); Link to comment Share on other sites More sharing options...
1quicksi Posted January 12, 2004 Share Posted January 12, 2004 Try posting in the support thread for WishList ;) http://www.oscommerce.com/forums/index.php?showtopic=67290 knowledge base | Contributions | Search Link to comment Share on other sites More sharing options...
Guest Posted January 12, 2004 Share Posted January 12, 2004 Thanks- she's already pm'd me that thread so I was letting this drop off :) Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.