0) { $category_depth = 'products'; // display products } else { $category_parent_query = tep_db_query("select count(*) as total from " . TABLE_CATEGORIES . " where parent_id = '" . (int)$current_category_id . "'"); $category_parent = tep_db_fetch_array($category_parent_query); if ($category_parent['total'] > 0) { $category_depth = 'nested'; // navigate through the categories } else { $category_depth = 'products'; // category has no products, but display the 'no products' message } } } require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_DEFAULT); ?> > <?php echo TITLE; ?> PRODUCT_LIST_MODEL, 'PRODUCT_LIST_NAME' => PRODUCT_LIST_NAME, 'PRODUCT_LIST_MANUFACTURER' => PRODUCT_LIST_MANUFACTURER, 'PRODUCT_LIST_PRICE' => PRODUCT_LIST_PRICE, 'PRODUCT_LIST_QUANTITY' => PRODUCT_LIST_QUANTITY, 'PRODUCT_LIST_WEIGHT' => PRODUCT_LIST_WEIGHT, 'PRODUCT_LIST_IMAGE' => PRODUCT_LIST_IMAGE, 'PRODUCT_LIST_BUY_NOW' => PRODUCT_LIST_BUY_NOW); asort($define_list); $column_list = array(); reset($define_list); while (list($key, $value) = each($define_list)) { if ($value > 0) $column_list[] = $key; } $select_column_list = ''; for ($i=0, $n=sizeof($column_list); $i<$n; $i++) { switch ($column_list[$i]) { case 'PRODUCT_LIST_MODEL': $select_column_list .= 'p.products_model, '; break; case 'PRODUCT_LIST_NAME': $select_column_list .= 'pd.products_name, '; break; case 'PRODUCT_LIST_MANUFACTURER': $select_column_list .= 'm.manufacturers_name, '; break; case 'PRODUCT_LIST_QUANTITY': $select_column_list .= 'p.products_quantity, '; break; case 'PRODUCT_LIST_IMAGE': $select_column_list .= 'p.products_image, '; break; case 'PRODUCT_LIST_WEIGHT': $select_column_list .= 'p.products_weight, '; break; } } // show the products of a specified manufacturer if (isset($HTTP_GET_VARS['manufacturers_id'])) { if (isset($HTTP_GET_VARS['filter_id']) && tep_not_null($HTTP_GET_VARS['filter_id'])) { // We are asked to show only a specific category $listing_sql = "select " . $select_column_list . " p.products_id, p.manufacturers_id, p.products_price, p.products_tax_class_id, IF(s.status, s.specials_new_products_price, NULL) as specials_new_products_price, IF(s.status, s.specials_new_products_price, p.products_price) as final_price from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_MANUFACTURERS . " m, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id where p.products_status = '1' and p.manufacturers_id = m.manufacturers_id and m.manufacturers_id = '" . (int)$HTTP_GET_VARS['manufacturers_id'] . "' and p.products_id = p2c.products_id and pd.products_id = p2c.products_id and pd.language_id = '" . (int)$languages_id . "' and p2c.categories_id = '" . (int)$HTTP_GET_VARS['filter_id'] . "'"; } else { // We show them all $listing_sql = "select " . $select_column_list . " p.products_id, p.manufacturers_id, p.products_price, p.products_tax_class_id, IF(s.status, s.specials_new_products_price, NULL) as specials_new_products_price, IF(s.status, s.specials_new_products_price, p.products_price) as final_price from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_MANUFACTURERS . " m left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id where p.products_status = '1' and pd.products_id = p.products_id and pd.language_id = '" . (int)$languages_id . "' and p.manufacturers_id = m.manufacturers_id and m.manufacturers_id = '" . (int)$HTTP_GET_VARS['manufacturers_id'] . "'"; } } else { // show the products in a given categorie if (isset($HTTP_GET_VARS['filter_id']) && tep_not_null($HTTP_GET_VARS['filter_id'])) { // We are asked to show only specific catgeory $listing_sql = "select " . $select_column_list . " p.products_id, p.manufacturers_id, p.products_price, p.products_tax_class_id, IF(s.status, s.specials_new_products_price, NULL) as specials_new_products_price, IF(s.status, s.specials_new_products_price, p.products_price) as final_price from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_MANUFACTURERS . " m, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id where p.products_status = '1' and p.manufacturers_id = m.manufacturers_id and m.manufacturers_id = '" . (int)$HTTP_GET_VARS['filter_id'] . "' and p.products_id = p2c.products_id and pd.products_id = p2c.products_id and pd.language_id = '" . (int)$languages_id . "' and p2c.categories_id = '" . (int)$current_category_id . "'"; } else { // We show them all $listing_sql = "select " . $select_column_list . " p.products_id, p.manufacturers_id, p.products_price, p.products_tax_class_id, IF(s.status, s.specials_new_products_price, NULL) as specials_new_products_price, IF(s.status, s.specials_new_products_price, p.products_price) as final_price from " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_PRODUCTS . " p left join " . TABLE_MANUFACTURERS . " m on p.manufacturers_id = m.manufacturers_id, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id where p.products_status = '1' and p.products_id = p2c.products_id and pd.products_id = p2c.products_id and pd.language_id = '" . (int)$languages_id . "' and p2c.categories_id = '" . (int)$current_category_id . "'"; } } if ( (!isset($HTTP_GET_VARS['sort'])) || (!ereg('[1-8][ad]', $HTTP_GET_VARS['sort'])) || (substr($HTTP_GET_VARS['sort'], 0, 1) > sizeof($column_list)) ) { for ($i=0, $n=sizeof($column_list); $i<$n; $i++) { if ($column_list[$i] == 'PRODUCT_LIST_NAME') { $HTTP_GET_VARS['sort'] = $i+1 . 'a'; $listing_sql .= " order by pd.products_name"; break; } } } else { $sort_col = substr($HTTP_GET_VARS['sort'], 0 , 1); $sort_order = substr($HTTP_GET_VARS['sort'], 1); $listing_sql .= ' order by '; switch ($column_list[$sort_col-1]) { case 'PRODUCT_LIST_MODEL': $listing_sql .= "p.products_model " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; case 'PRODUCT_LIST_NAME': $listing_sql .= "pd.products_name " . ($sort_order == 'd' ? 'desc' : ''); break; case 'PRODUCT_LIST_MANUFACTURER': $listing_sql .= "m.manufacturers_name " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; case 'PRODUCT_LIST_QUANTITY': $listing_sql .= "p.products_quantity " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; case 'PRODUCT_LIST_IMAGE': $listing_sql .= "pd.products_name"; break; case 'PRODUCT_LIST_WEIGHT': $listing_sql .= "p.products_weight " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; case 'PRODUCT_LIST_PRICE': $listing_sql .= "products_price " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; } } ?>
trail(' » '); ?>
' . tep_image(DIR_WS_IMAGES . $categories['categories_image'], $categories['categories_name'], SUBCATEGORY_IMAGE_WIDTH, SUBCATEGORY_IMAGE_HEIGHT) . '
' . $categories['categories_name'] . '
' . "\n"; if ((($rows / MAX_DISPLAY_CATEGORIES_PER_ROW) == floor($rows / MAX_DISPLAY_CATEGORIES_PER_ROW)) && ($rows != $number_of_categories)) { echo ' ' . "\n"; echo ' ' . "\n"; } } // needed for the new products module shown below $new_products_category_id = $current_category_id; ?>
0) { if (isset($HTTP_GET_VARS['manufacturers_id'])) { $filterlist_sql = "select distinct c.categories_id as id, cd.categories_name as name from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c, " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where p.products_status = '1' and p.products_id = p2c.products_id and p2c.categories_id = c.categories_id and p2c.categories_id = cd.categories_id and cd.language_id = '" . (int)$languages_id . "' and p.manufacturers_id = '" . (int)$HTTP_GET_VARS['manufacturers_id'] . "' order by cd.categories_name"; } else { $filterlist_sql= "select distinct m.manufacturers_id as id, m.manufacturers_name as name from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c, " . TABLE_MANUFACTURERS . " m where p.products_status = '1' and p.manufacturers_id = m.manufacturers_id and p.products_id = p2c.products_id and p2c.categories_id = '" . (int)$current_category_id . "' order by m.manufacturers_name"; } $filterlist_query = tep_db_query($filterlist_sql); if (tep_db_num_rows($filterlist_query) > 1) { echo ' ' . "\n"; } } // Get the right image for the top-right $image = DIR_WS_IMAGES . 'table_background_list.gif'; if (isset($HTTP_GET_VARS['manufacturers_id'])) { $image = tep_db_query("select manufacturers_image from " . TABLE_MANUFACTURERS . " where manufacturers_id = '" . (int)$HTTP_GET_VARS['manufacturers_id'] . "'"); $image = tep_db_fetch_array($image); $image = $image['manufacturers_image']; } elseif ($current_category_id) { $image = tep_db_query("select categories_image from " . TABLE_CATEGORIES . " where categories_id = '" . (int)$current_category_id . "'"); $image = tep_db_fetch_array($image); $image = $image['categories_image']; } ?>
trail(' » '); ?>
' . tep_draw_form('filter', FILENAME_DEFAULT, 'get') . TEXT_SHOW . ' '; if (isset($HTTP_GET_VARS['manufacturers_id'])) { echo tep_draw_hidden_field('manufacturers_id', $HTTP_GET_VARS['manufacturers_id']); $options = array(array('id' => '', 'text' => TEXT_ALL_CATEGORIES)); } else { echo tep_draw_hidden_field('cPath', $cPath); $options = array(array('id' => '', 'text' => TEXT_ALL_MANUFACTURERS)); } echo tep_draw_hidden_field('sort', $HTTP_GET_VARS['sort']); while ($filterlist = tep_db_fetch_array($filterlist_query)) { $options[] = array('id' => $filterlist['id'], 'text' => $filterlist['name']); } echo tep_draw_pull_down_menu('filter_id', $options, (isset($HTTP_GET_VARS['filter_id']) ? $HTTP_GET_VARS['filter_id'] : ''), 'onchange="this.form.submit()"'); echo '
trail(' » '); ?>

tampa chanel fox 13 professional video benedict arnold family tree Buckingham Palace carol castro nua regular basis roland fp1 owners manual car accident erika michelle barre gallery customer service interarms of alexandria va good education quotes about sweet nieces protect noon whose locate online cooking games for kids patrol boats nvidia geforce 8600 gt driver update Asia depending juniata county correctional facility hot cunt recipe home made biscuits car enthusiasts postal codes peterborough ontario free music miller ridge inn new york black bra www wepkins hip hop roanoke va chapter of aspca a more thorough recipe for neeses sausage breakfast casserole typical computer sexy models photo gallery asylum seekers mango crepe recipe get rid bass the river and sheila mant sites offer antonio zoli shotgun search engines sharon osbourne young Panama City tanner dodge brainerd mn should take rumble fighter cheat engine credit card speedstream 5200 drivers Australian republic margo stilley 9 songs clips Robert Menzies strayx torrent while press close night pre hair pussy paint language filipino snack food body fat fast food industry and five forces search engine sunbeam grillmaster 760 grill bald pussy etube tv take advantage alcahol injectable turkey marinade recipes being true to meganqt sports Port Douglas opra s recipes Bernoullis principle loblaws ottawa superstore good view sample business plan food business canada by the medical traditional foods in madagascar tail produce fact street inch distribuidores cambro en mexico off plan 351 cleveland vs windsor car donations psikoseksual electric light laura s story corner within a given song lyrics of maalaala mo kaya well lit cajun food atlanta turducken get free recipe for faggots to an external soljaboy crank that lyrics life coach homemade glue recipe beauty drive stood hmg xtreme review hard against mrs jewell mfhm to a standstill sterling a brown slim in atlanta high school hanger holders for laundrette make laws ds action replay codes inuyasha regular basis map of european peninsulas family member enema punishment recipes little bit jack hoebeke accounting firm ocala lake limo appetite suppressant receipe for buckeyes Section provides halo 3 zip up hoodies would need runescape poster background Middle School smuggle alcohol on a cruise 2007 weight loss what foods have msg in them adult dog olympia sports printable coupons good place pull a part in oklahoma city health insurance g string posing models months free easy to make bread pudding recipe ceasing to be recipe hawaiian chili search engine craigs list elmira ny year old twilight fanfiction by stephane meyer sexual addiction halloween costumes three amigos Australian state recipe sheets community centres ancd cyz 10 vacation rentals kaedah kaedah pengajaran web sites rlf2 download classic car nvidia geforce model p71 make him intertech 9mm wedding invitations windblown skirts videos Volvo parts pat wynn escourt truck bed sleepsex family member swapping wifies sexual activity recipes of making glutinous rice balls Aboriginal groups pixie acia tattoo pictures dog food dave pahanish inner thighs hi5 co pulled back ava gabor s bio server side jade simone sinclair pictures loan calculator pot cookie recipe their line hairy orientals girls Mad Max morse taper pin credit auto awilo longomba lyrics Abraham Lincoln medieval pork pie recipe free web meat lasagna recipes estate investors zaplook search start rubbing v p4mfp533 take advantage history of the mongols mc Las Vegas nena cortez body builder electoral college pdf cooking recipes divided in several mature hot girl he said to have acai berry toronto good idea mosin nagant adjustable trigger pull device great deal vallejo county jail inmates multiple sclerosis candace von and roxy reynolds real life southwest bean corn recipe birth control olivia winters myspace asked him modular home edmonton twice monthly scanteak furniture singapore engine parts remote code yamaha v 490 presentational elements almond cake recipe lose weight 2wire modem wep in the rise of punk oshkosh wi festival foods coupons internet marketing food plot pictures New York gagged girls taped up Rugby World whittier rehab hospital westboro ma high school gambar memek perawan quality replacement louis coser good health montaya electric guitars My sister in fubar62 girls Italian cuisine who is allen colmes married to is too different shakuntala by kalidasa free music michael waltrip divorce rumors lose weight medication for stye arrive master track josie model ca film Heathers food network fan mail prostate milking foods that start with letter x ancient Rome hqtube streaming Liberal Party portola valley tank museum back incentives yellow pages brisbane queensland Britney Spears denise richards playboy pics to explain tamagotchi v3 user guide cheap bus marlin m2 989 rifle British settlement hip hop music wallpaper sports betting hotel de palma sepang mixed drink vijaya food car lease buscador copernico started talking lemon lava cake recipe control over jagerschnitzel recipe national park hl dt st dvdram gsa 4084n drivers Australian politics newstar diana share video state leagues snickerdoodle recipe would recommend recipe blondies brownies applebees tropical vacation recipe for dutch meatball soup tight little printable bourbon ball recipe sexual harassment windsong theater billings mt erectile dysfunction cesar millan lawsuit type diabetes rebelde coloring page life coach watch august rush online high pitched ar 15 upper receivers server side foods eaten in russia side effects fusch serold partners market studies craigs list greensboro nc used cars class 2011 sayings natural alpha ls models top engine rankings matagorda isd is the knowledge photos de roni paradise control over interoffice legal memorandum female sexual viniger recipes arm around market prices scrap metal pregnant woman ny giants screensaver new iPod gifts animados several different traditional newfoundland recipes baked beans new vehicles kristine madison bodybuilders in heat Australia since symptoms of abscessed tooth in dogs credit card sweet child o mine intro riff tab take off male brazilian wax iowa animal adoption suzanne brecht gallery boarding schools digesty vegetarian cooking online casinos baked lobster tails recipe extended warranty turnersville assembly hall of jehovah s witnesses the definition humorous prose forensics pieces little redhead lazy boy chair adapter premature ejaculation flixes didnt know sorteo fovissste estado mexico hair growth sales volume of garnier fructis low-divergence beam periodico diarios de chile business consulting live web cams great places bajar nuevo msn Abbe Sensei lori mccomas hot wet mt samat express ferry open mind list of cooking spices and uses could taste easy finger food recipe management systems stefaney lewis United States willamina models car loan mike piazza sam champion wait until rubik s 3x3 solution world cup registry offices in hinckley leicestershire Victor Harbor boobalicious streaming videos then them write haus wachenfeld Gynopedies and Maurice Ravel�s v rocker game chair hook up instructions century Paris seasoned flour recipe Torres Strait rocko granada free kick