donato Posted July 8, 2003 Share Posted July 8, 2003 hello, my store is centered 770 px in width clicking on a image in the 'whats new' section or clicking on the 'conditions of use' displays the store layout correctly...HOWEVER, when clicking on a category the page gets stretched out to 100%!! i checked all necessary files, all body values are set to 770 i searched the forum and have found no similar cases... reffered to the wiki site and both the default and header php are defined correctly (with value of 770) rest of site is fine, when selecting any category, its mucked up!! please help! donato Link to comment Share on other sites More sharing options...
Guest Posted July 8, 2003 Share Posted July 8, 2003 Have you checked includes/modules/product_listing.php yet? Good luck, Matt Link to comment Share on other sites More sharing options...
Guest Posted July 8, 2003 Share Posted July 8, 2003 Chances are you have an unclosed td or tr tag somewhere probably in the categories page Link to comment Share on other sites More sharing options...
donato Posted July 9, 2003 Author Share Posted July 9, 2003 hey guys thanx for the replies checked both suggestions out... product_listing already had the body tag set to 770 searched all the categories php and found nothing out of the ordinary... u guys have other suggestions? please help !! site url is the following: www.goodlifefitness.com/catalog please help!! thx donato Link to comment Share on other sites More sharing options...
donato Posted July 10, 2003 Author Share Posted July 10, 2003 apologize in advance for the bump, posts just get burried to quick here...could someone PLEASE PLEASE PLEASE help me in sorting this out? :roll: pulling out hair here....;) thx d Link to comment Share on other sites More sharing options...
Chad Posted July 10, 2003 Share Posted July 10, 2003 you have too many of these -> width="770" I removed 2 of them.. 1 before and 1 after your product listing and it works fine now :) Link to comment Share on other sites More sharing options...
donato Posted July 10, 2003 Author Share Posted July 10, 2003 sorry Chad, thanx for the reply... i'm not sure what u mean... i opened my product_listing.php file located in /catalog/modules your right did have too many 770 instead of 100%... i made a few changes but kept one line to 770 here is the code...BUT THE PROBLEM STILL PERSISTS...(sorry had to put that in caps so no one will over look... THANKS AGAIN IN ADVACE!!! <?php /* $Id: product_listing.php,v 1.41 2003/02/12 23:55:58 hpdl Exp $ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright (c) 2003 osCommerce Released under the GNU General Public License */ ?> <table border="0" width="770" cellspacing="0" cellpadding="2" align="center"> <?php $listing_numrows_sql = $listing_sql; $listing_split = new splitPageResults($HTTP_GET_VARS['page'], MAX_DISPLAY_SEARCH_RESULTS, $listing_sql, $listing_numrows); // fix counted products $listing_numrows = tep_db_query($listing_numrows_sql); $listing_numrows = tep_db_num_rows($listing_numrows); if ( ($listing_numrows > 0) && ( (PREV_NEXT_BAR_LOCATION == '1') || (PREV_NEXT_BAR_LOCATION == '3') ) ) { ?> <tr> <td><table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td class="smallText"> <?php echo $listing_split->display_count($listing_numrows, MAX_DISPLAY_SEARCH_RESULTS, $HTTP_GET_VARS['page'], TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?> </td> <td align="right" class="smallText"> <?php echo TEXT_RESULT_PAGE; ?> <?php echo $listing_split->display_links($listing_numrows, MAX_DISPLAY_SEARCH_RESULTS, MAX_DISPLAY_PAGE_LINKS, $HTTP_GET_VARS['page'], tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?> </td> </tr> </table></td> </tr> <tr> <td><?php echo tep_draw_separator(); ?></td> </tr> <?php } ?> <tr> <td> <?php $list_box_contents = array(); $list_box_contents[] = array('params' => 'class="productListing-heading"'); $cur_row = sizeof($list_box_contents) - 1; for ($col=0, $n=sizeof($column_list); $col<$n; $col++) { switch ($column_list[$col]) { case 'PRODUCT_LIST_MODEL': $lc_text = TABLE_HEADING_MODEL; $lc_align = ''; break; case 'PRODUCT_LIST_NAME': $lc_text = TABLE_HEADING_PRODUCTS; $lc_align = ''; break; case 'PRODUCT_LIST_MANUFACTURER': $lc_text = TABLE_HEADING_MANUFACTURER; $lc_align = ''; break; case 'PRODUCT_LIST_PRICE': $lc_text = TABLE_HEADING_PRICE; $lc_align = 'right'; break; case 'PRODUCT_LIST_QUANTITY': $lc_text = TABLE_HEADING_QUANTITY; $lc_align = 'right'; break; case 'PRODUCT_LIST_WEIGHT': $lc_text = TABLE_HEADING_WEIGHT; $lc_align = 'right'; break; case 'PRODUCT_LIST_IMAGE': $lc_text = TABLE_HEADING_IMAGE; $lc_align = 'center'; break; case 'PRODUCT_LIST_BUY_NOW': $lc_text = TABLE_HEADING_BUY_NOW; $lc_align = 'center'; break; } if ( ($column_list[$col] != 'PRODUCT_LIST_BUY_NOW') && ($column_list[$col] != 'PRODUCT_LIST_IMAGE') ) { $lc_text = tep_create_sort_heading($HTTP_GET_VARS['sort'], $col+1, $lc_text); } $list_box_contents[$cur_row][] = array('align' => $lc_align, 'params' => 'class="productListing-heading"', 'text' => ' ' . $lc_text . ' '); } if ($listing_numrows > 0) { $number_of_products = '0'; $listing_query = tep_db_query($listing_sql); while ($listing = tep_db_fetch_array($listing_query)) { $number_of_products++; if (($number_of_products/2) == floor($number_of_products/2)) { $list_box_contents[] = array('params' => 'class="productListing-even"'); } else { $list_box_contents[] = array('params' => 'class="productListing-odd"'); } $cur_row = sizeof($list_box_contents) - 1; for ($col=0, $n=sizeof($column_list); $col<$n; $col++) { $lc_align = ''; switch ($column_list[$col]) { case 'PRODUCT_LIST_MODEL': $lc_align = ''; $lc_text = ' ' . $listing['products_model'] . ' '; break; case 'PRODUCT_LIST_NAME': $lc_align = ''; if (isset($HTTP_GET_VARS['manufacturers_id'])) { $lc_text = '<a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'manufacturers_id=' . $HTTP_GET_VARS['manufacturers_id'] . '&products_id=' . $listing['products_id']) . '">' . $listing['products_name'] . '</a>'; } else { $lc_text = ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath=' . $cPath . '&' : '') . 'products_id=' . $listing['products_id']) . '">' . $listing['products_name'] . '</a> '; } break; case 'PRODUCT_LIST_MANUFACTURER': $lc_align = ''; $lc_text = ' <a href="' . tep_href_link(FILENAME_DEFAULT, 'manufacturers_id=' . $listing['manufacturers_id']) . '">' . $listing['manufacturers_name'] . '</a> '; break; case 'PRODUCT_LIST_PRICE': $lc_align = 'right'; if (tep_not_null($listing['specials_new_products_price'])) { $lc_text = ' <s>' . $currencies->display_price($listing['products_price'], tep_get_tax_rate($listing['products_tax_class_id'])) . '</s> <span class="productSpecialPrice">' . $currencies->display_price($listing['specials_new_products_price'], tep_get_tax_rate($listing['products_tax_class_id'])) . '</span> '; } else { $lc_text = ' ' . $currencies->display_price($listing['products_price'], tep_get_tax_rate($listing['products_tax_class_id'])) . ' '; } break; case 'PRODUCT_LIST_QUANTITY': $lc_align = 'right'; $lc_text = ' ' . $listing['products_quantity'] . ' '; break; case 'PRODUCT_LIST_WEIGHT': $lc_align = 'right'; $lc_text = ' ' . $listing['products_weight'] . ' '; break; case 'PRODUCT_LIST_IMAGE': $lc_align = 'center'; if (isset($HTTP_GET_VARS['manufacturers_id'])) { $lc_text = '<a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'manufacturers_id=' . $HTTP_GET_VARS['manufacturers_id'] . '&products_id=' . $listing['products_id']) . '">' . tep_image(DIR_WS_IMAGES . $listing['products_image'], $listing['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a>'; } else { $lc_text = ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath=' . $cPath . '&' : '') . 'products_id=' . $listing['products_id']) . '">' . tep_image(DIR_WS_IMAGES . $listing['products_image'], $listing['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a> '; } break; case 'PRODUCT_LIST_BUY_NOW': $lc_align = 'center'; $lc_text = '<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $listing['products_id']) . '">' . tep_image_button('button_buy_now.gif', TEXT_BUY . $listing['products_name'] . TEXT_NOW) . '</a> '; break; } $list_box_contents[$cur_row][] = array('align' => $lc_align, 'params' => 'class="productListing-data"', 'text' => $lc_text); } } new tableBox($list_box_contents, true); echo ' </td>' . "n" . ' </tr>' . "n"; } else { ?> <tr class="productListing-odd"> <td class="smallText"> <?php echo (isset($HTTP_GET_VARS['manufacturers_id']) ? TEXT_NO_PRODUCTS2 : TEXT_NO_PRODUCTS); ?> </td> </tr> <?php } ?> <tr> <td><?php echo tep_draw_separator(); ?></td> </tr> <?php if ( ($listing_numrows > 0) && ((PREV_NEXT_BAR_LOCATION == '2') || (PREV_NEXT_BAR_LOCATION == '3')) ) { ?> <tr> <td><table border="0" width="100%" cellspacing="0" cellpadding="2" align="center"> <tr> <td class="smallText"> <?php echo $listing_split->display_count($listing_numrows, MAX_DISPLAY_SEARCH_RESULTS, $HTTP_GET_VARS['page'], TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?> </td> <td align="right" class="smallText"> <?php echo TEXT_RESULT_PAGE; ?> <?php echo $listing_split->display_links($listing_numrows, MAX_DISPLAY_SEARCH_RESULTS, MAX_DISPLAY_PAGE_LINKS, $HTTP_GET_VARS['page'], tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?> </td> </tr> </table></td> </tr> <?php } ?> </table> Link to comment Share on other sites More sharing options...
donato Posted July 10, 2003 Author Share Posted July 10, 2003 sorry chad what do you mean exactly by this: I removed 2 of them.. 1 before and 1 after your product listing and it works fine now what did u remove? and what do u mean one before and one after? Link to comment Share on other sites More sharing options...
donato Posted July 10, 2003 Author Share Posted July 10, 2003 HOLY SH*T ... problem now fixed...for the hell of it went in and changed this bit of code: Released under the GNU General Public License */ ?> <table border="0" width="770" cellspacing="0" cellpadding="2" align="center"> <?php to this: Released under the GNU General Public License */ ?> <table border="0" width="100%" cellspacing="0" cellpadding="2"> <?php and now it works!! thanks to all for the insight and direction!!! :oops: :lol: Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.