Guest Posted August 4, 2010 Posted August 4, 2010 When I ad a option to a product, on the product discription page everything moves to the right. Take a look Where can I fix this?..............thanks
artful Posted August 4, 2010 Posted August 4, 2010 When I ad a option to a product, on the product discription page everything moves to the right. Take a look Where can I fix this?..............thanks Hello Rob, In looking at the source code of your products, one without options and the other in the link above, there is an error in the table placement of your options around lines 259-281 (you can see it by doing a right click on a product page and then clicking Source Code). Did you add an option add-on or are you just doing it all with an editor ? For example I see that you have specifications detailed for some and this one has just dimensions and then the options. Check your table placement in your product_info.php for the options. Barbara
Guest Posted August 4, 2010 Posted August 4, 2010 Hello Rob, In looking at the source code of your products, one without options and the other in the link above, there is an error in the table placement of your options around lines 259-281 (you can see it by doing a right click on a product page and then clicking Source Code). Did you add an option add-on or are you just doing it all with an editor ? For example I see that you have specifications detailed for some and this one has just dimensions and then the options. Check your table placement in your product_info.php for the options. Barbara Thanks, take a look at my prduct_info.php <?php /* $Id: product_info.php 1739 2007-12-20 00:52:16Z hpdl $ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright (c) 2003 osCommerce Released under the GNU General Public License */ require('includes/application_top.php'); require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_PRODUCT_INFO); $product_check_query = tep_db_query("select count(*) as total from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_status = '1' and p.products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and pd.products_id = p.products_id and pd.language_id = '" . (int)$languages_id . "'"); $product_check = tep_db_fetch_array($product_check_query); ?> <!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN"> <html <?php echo HTML_PARAMS; ?>> <head> <?php if ( file_exists(DIR_WS_INCLUDES . 'header_tags.php') ) { require(DIR_WS_INCLUDES . 'header_tags.php'); } else { ?> <title><?php echo TITLE; ?></title> <?php } ?> <base href="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>"> <script type="text/javascript" src="slimbox/js/jquery-1.3.2.min.js"></script> <script type="text/javascript" src="slimbox/js/slimbox2.js"></script> <link rel="stylesheet" href="slimbox/css/slimbox2.css" type="text/css" media="screen" /> <link rel="stylesheet" type="text/css" href="stylesheet.css"> <script language="javascript"><!-- function popupWindow(url,extra) { window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=yes,copyhistory=no,screenX=150,screenY=150,top=150,left=150,'+extra) } //--></script> <link rel="canonical" href="<?php CanonicalUrl(); ?>" /> </head> <body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0" class="body"> <!-- header //--> <?php require(DIR_WS_INCLUDES . 'header.php'); ?> <!-- header_eof //--> <!-- body //--> <table border="0" width="100%" class="bgcolor" cellspacing="0" cellpadding="0"> <tr> <?php if(COLUMN_LEFT == 1){ ?> <td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" class="column_left"> <!-- left_navigation //--> <?php require(DIR_WS_INCLUDES . 'column_left.php'); ?> <!-- left_navigation_eof //--> </table></td> <?php } ?> <!-- body_text //--> <td width="100%" valign="top" class="padding_top"><?php echo tep_draw_form('cart_quantity', tep_href_link(FILENAME_PRODUCT_INFO, tep_get_all_get_params(array('action')) . 'action=add_product')); ?><table border="0" width="100%" cellspacing="0" cellpadding="0"> <?php if ($product_check['total'] < 1) { ?> <tr> <td><?php new infoBox(array(array('text' => TEXT_PRODUCT_NOT_FOUND))); ?></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <tr> <td><table border="0" width="100%" cellspacing="1" cellpadding="2" class="infoBox"> <tr class="infoBoxContents"> <td><table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td width="10"><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td> <td align="right"><?php echo '<a href="' . tep_href_link(FILENAME_DEFAULT) . '">' . tep_image_button('button_continue.gif', IMAGE_BUTTON_CONTINUE) . '</a>'; ?></td> <td width="10"><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td> </tr> </table></td> </tr> </table></td> </tr> <?php } else { $product_info_query = tep_db_query("select p.products_id, pd.products_name, pd.products_description, p.products_model, p.products_quantity, p.products_image, products_subimage1, products_subimage2, products_subimage3, products_subimage4, products_subimage5, products_subimage6, pd.products_url, p.products_price, p.products_tax_class_id, p.products_date_added, p.products_date_available, p.manufacturers_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_status = '1' and p.products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and pd.products_id = p.products_id and pd.language_id = '" . (int)$languages_id . "'"); $product_info = tep_db_fetch_array($product_info_query); tep_db_query("update " . TABLE_PRODUCTS_DESCRIPTION . " set products_viewed = products_viewed+1 where products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and language_id = '" . (int)$languages_id . "'"); if ($new_price = tep_get_products_special_price($product_info['products_id'])) { $products_price = '<s>' . $currencies->display_price($product_info['products_price'], tep_get_tax_rate($product_info['products_tax_class_id'])) . '</s><br /><span class="productSpecialPrice">' . $currencies->display_price($new_price, tep_get_tax_rate($product_info['products_tax_class_id'])) . '</span>'; } else { $products_price = $currencies->display_price($product_info['products_price'], tep_get_tax_rate($product_info['products_tax_class_id'])); } $products_name = $product_info['products_name']; ?> <?php // category textbox mod if (DISPLAY_EXTRA_CATEGORIES == 'true' && DISPLAY_CATS_ON_PROD_LISTING == 'true') { if ($product_check['total'] >= 1) { // now get textbox description for this *product* and display $query = tep_db_query("select categories_description from " . TABLE_EXTRA_CATEGORIES . " left join " . TABLE_PRODUCTS_TO_CATEGORIES . " using (categories_id) where " . TABLE_PRODUCTS_TO_CATEGORIES .".products_id=" . (int)$HTTP_GET_VARS['products_id'] . " and " . TABLE_EXTRA_CATEGORIES .".language_id = '" . (int)$languages_id . "'"); while($category_info_text = tep_db_fetch_array($query)) { if(!empty($category_info_text['categories_description'])){ // prevent output where description not set for particular language echo ("<tr><td colspan=\"2\"><div class=\"cat_info_box\">".$category_info_text['categories_description']."</div></td></tr>"); } } } } ?> <?php $mopics_images = array(); for ( $mo_item=1; $mo_item<7; $mo_item++ ) { if (tep_not_null($product_info['products_subimage'.$mo_item])) { $mopics_images[] = $product_info['products_subimage'.$mo_item]; } } $mopics_count = sizeof($mopics_images); if ($mopics_count > 0) { $mopics_output .= '<table border="0" cellspacing="0" cellpadding="0">'; for ( $mo_item=0; $mo_item<$mopics_count; $mo_item++ ) { $mopics_output .= ' <t><td align="center" class="smallText"> <script language="javascript"><!-- document.write(\'<a href="' . tep_href_link(DIR_WS_IMAGES . $mopics_images[$mo_item]) . '" rel="lightbox-extra" title="' . $product_info['products_name'] . '">' . tep_image(DIR_WS_IMAGES . $mopics_images[$mo_item], "", SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a>\'); //--></script> <noscript> <a href="' . tep_href_link(DIR_WS_IMAGES . $mopics_images[$mo_item]) . '" target="_blank">' . tep_image(DIR_WS_IMAGES . $mopics_images[$mo_item], $product_info['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'hspace="5" vspace="5"') . '<br>' . TEXT_CLICK_TO_ENLARGE . '</a> </noscript></td></tr>'; } $mopics_output .= '</table>'."\n"; } ?> <tr> <td><table border="0" width="100%" cellspacing="0" cellpadding="0"> <tr> <td class="pageHeading"><?php echo $products_name; ?></td> </tr> </table></td> </tr> <tr> <td class="products_background"> <table cellspacing="0" cellpadding="0" border="0" width="100%"> <tr> <?php new drawLineBegin(); ?> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <tr> <td class="main"> <table border="0" cellspacing="0" cellpadding="2" align="right"> <?php if (tep_not_null($product_info['products_image'])) { ?> <tr> <td align="center" class="smallText"> <script language="javascript"><!-- document.write('<a href="<?= tep_href_link(DIR_WS_IMAGES . $product_info['products_image']); ?>" rel="lightbox-extra" title="<?php echo $product_info['products_name']; ?>"><?= tep_image(DIR_WS_IMAGES . $product_info['products_image'], "", SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT); ?></a>'); //--></script> <noscript> <?php echo '<a href="' . tep_href_link(DIR_WS_IMAGES . $product_info['products_image']) . '" target="_blank">' . tep_image(DIR_WS_IMAGES . $product_info['products_image'], $product_info['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'hspace="5" vspace="5"') . '<br>' . TEXT_CLICK_TO_ENLARGE . '</a>'; ?> </noscript> </td> </tr> <?php } ?> <tr> <td class="productInfoPrice" width="180" align="left"> <hr style="color: '#d2d2d2'; height: '1'; text-align: 'left'; width: '100%'"> <?php echo $products_price; ?><font size="1" align="left">Inclusief BTW</font> <?php $prod_quantity = tep_get_products_stock($product_info['products_id']); switch ($prod_quantity) { case 0: print '</br><div style="font-size: 10px; font-weight: normal; color: #000000;"><b>Gratis thuisbezorgd</b></font></div>'; break; default: print '</br><div style="font-size: 10px; font-weight: normal; color: #000000;">Aantal op voorraad: <font color="#077F2C">'.$prod_quantity.'</font></div>'; break; } ?> <!--</br> <A onclick="window.open('<?= HTTP_SERVER . DIR_WS_HTTP_CATALOG; ?>voorraadcheck.php?products_id=<?=$HTTP_GET_VARS['products_id']?>','','width=897,height=207,scrollbars=no,toolbar=no,location=no');" style="cursor:pointer"><?= tep_image_button('button_check_stock.gif', 'Actuele Voorraadcheck'); ?></a> <br /> //--> <br /> <?php echo tep_draw_hidden_field('products_id', $product_info['products_id']) . tep_image_submit('button_in_cart.gif', IMAGE_BUTTON_IN_CART); ?> <br /> <hr style="color: '#d2d2d2'; height: '1'; text-align: 'left'; width: '100%'"> </td> <!---------------------> </tr> <tr> <td align="center"><?php echo $mopics_output; ?> </td> </tr> </table> <p><?php echo stripslashes($product_info['products_description']); ?></p></p> <!-- bof Product Special Expire Date --> <tr> <td class="smallText" align="right" valign="top" colspan="2"> <?php $special_exp_date = tep_get_products_special_expire($product_info['products_id']); if (($special_exp_date != '') && ($special_exp_date != '0000-00-00 00:00:00')) { echo '<span class="inputRequirement">' . TEXT_SPECIAL_EXPIRES . tep_date_long($special_exp_date) . ' </span>';} ?> </td> </tr> <!-- eof Product Special Expire Date --> <?php } if ($product_info['products_date_available'] > date('Y-m-d H:i:s')) { ?> <tr> <td align="center" class="smallText"><?php echo sprintf(TEXT_DATE_AVAILABLE, tep_date_long($product_info['products_date_available'])); ?></td> </tr> <?php } else { ?> <?php $products_attributes_query = tep_db_query("select count(*) as total from " . TABLE_PRODUCTS_OPTIONS . " popt, " . TABLE_PRODUCTS_ATTRIBUTES . " patrib where patrib.products_id='" . (int)$HTTP_GET_VARS['products_id'] . "' and patrib.options_id = popt.products_options_id and popt.language_id = '" . (int)$languages_id . "'"); $products_attributes = tep_db_fetch_array($products_attributes_query); if ($products_attributes['total'] > 0) { ?> <table border="0" cellspacing="0" cellpadding="2"> <tr> <td class="main" colspan="2"><?php echo TEXT_PRODUCT_OPTIONS; ?></td> </tr> <?php $products_options_name_query = tep_db_query("select distinct popt.products_options_id, popt.products_options_name from " . TABLE_PRODUCTS_OPTIONS . " popt, " . TABLE_PRODUCTS_ATTRIBUTES . " patrib where patrib.products_id='" . (int)$HTTP_GET_VARS['products_id'] . "' and patrib.options_id = popt.products_options_id and popt.language_id = '" . (int)$languages_id . "' order by popt.products_options_name"); while ($products_options_name = tep_db_fetch_array($products_options_name_query)) { $products_options_array = array(); $products_options_query = tep_db_query("select pov.products_options_values_id, pov.products_options_values_name, pa.options_values_price, pa.price_prefix from " . TABLE_PRODUCTS_ATTRIBUTES . " pa, " . TABLE_PRODUCTS_OPTIONS_VALUES . " pov where pa.products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and pa.options_id = '" . (int)$products_options_name['products_options_id'] . "' and pa.options_values_id = pov.products_options_values_id and pov.language_id = '" . (int)$languages_id . "'"); while ($products_options = tep_db_fetch_array($products_options_query)) { $products_options_array[] = array('id' => $products_options['products_options_values_id'], 'text' => $products_options['products_options_values_name']); if ($products_options['options_values_price'] != '0') { $products_options_array[sizeof($products_options_array)-1]['text'] .= ' (' . $products_options['price_prefix'] . $currencies->display_price($products_options['options_values_price'], tep_get_tax_rate($product_info['products_tax_class_id'])) .') '; } } if (isset($cart->contents[$HTTP_GET_VARS['products_id']]['attributes'][$products_options_name['products_options_id']])) { $selected_attribute = $cart->contents[$HTTP_GET_VARS['products_id']]['attributes'][$products_options_name['products_options_id']]; } else { $selected_attribute = false; } ?> <tr> <td class="main"><?php echo $products_options_name['products_options_name'] . ':'; ?></td> <td class="main"><?php echo tep_draw_pull_down_menu('id[' . $products_options_name['products_options_id'] . ']', $products_options_array, $selected_attribute); ?></td> </tr> <?php } ?> </table> <?php } ?> </td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <?php $reviews_query = tep_db_query("select count(*) as count from " . TABLE_REVIEWS . " where products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "'"); $reviews = tep_db_fetch_array($reviews_query); if ($reviews['count'] > 0) { ?> <tr> <td class="main"><?php echo TEXT_CURRENT_REVIEWS . ' ' . $reviews['count']; ?></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <?php } if (tep_not_null($product_info['products_url'])) { ?> <tr> <td class="main"><?php echo sprintf(TEXT_MORE_INFORMATION, tep_href_link(FILENAME_REDIRECT, 'action=url&goto=' . urlencode($product_info['products_url']), 'NONSSL', true, false)); ?></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <?php } ?> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <?php } ?> </table></td> </tr> <?php new drawLineEnd(); new drawFooter(); ?> </table></form></td> <?php if(COLUMN_RIGHT == 1){ ?> <!-- body_text_eof //--> <td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" class="column_right"> <!-- right_navigation //--> <?php require(DIR_WS_INCLUDES . 'column_right.php'); ?> <!-- right_navigation_eof //--> </table></td> <?php } ?> </tr> </table> <!-- body_eof //--> <!-- footer //--> <?php require(DIR_WS_INCLUDES . 'footer.php'); ?> <!-- footer_eof //--> <br> </body> </html> <?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?>
artful Posted August 4, 2010 Posted August 4, 2010 Hello again Rob, I see several conflicts with the add-on Mopics and the options... I need a little time to sort it out and will get back to you as quickly as possible. Barbara
Guest Posted August 4, 2010 Posted August 4, 2010 Hello again Rob, I see several conflicts with the add-on Mopics and the options... I need a little time to sort it out and will get back to you as quickly as possible. Barbara Thanks in advance
germ Posted August 4, 2010 Posted August 4, 2010 Off subject but worth mentioning... Your Histats.com script is causing the infamous "unsecure items" popup in IE on your SSL pages. If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you. "Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice." - Me - "Headers already sent" - The definitive help "Cannot redeclare ..." - How to find/fix it SSL Implementation Help Like this post? "Like" it again over there >
Guest Posted August 4, 2010 Posted August 4, 2010 Off subject but worth mentioning... Your Histats.com script is causing the infamous "unsecure items" popup in IE on your SSL pages. Thanks........removed it right away.
artful Posted August 4, 2010 Posted August 4, 2010 Hello again Rob, I see several conflicts with the add-on Mopics and the options... I need a little time to sort it out and will get back to you as quickly as possible. Barbara OK Rob, It looks like your More Pics has errors on the product page and needs to be upgraded on the entire site to ensure the proper placement of the images in relation to the other elements. Check that out. Then check out the Extra categories add-on you have as well as the special Expire date as they seem to need ajusting with the More Pics. The table structure involved with all three is what appears to be throwing the page format off. I have not been able to determine which option mod you are using as it is definitely not the standard so that is to be verified. Look at all those and see if the changes bring you back to a normal page with options. Note: back up the original files that you modify by naming them for example product_infoOLD.php and then modify the file not renamed OLD so that you can always revert to the original in case of problems. Concerning your database back it up too before modifying it if upgrading tese mods needs database changes. There too you can restore your database if necessary. Take é aspirins and call me in the morning! Barbara
Guest Posted August 5, 2010 Posted August 5, 2010 OK Rob, It looks like your More Pics has errors on the product page and needs to be upgraded on the entire site to ensure the proper placement of the images in relation to the other elements. Check that out. Then check out the Extra categories add-on you have as well as the special Expire date as they seem to need ajusting with the More Pics. The table structure involved with all three is what appears to be throwing the page format off. I have not been able to determine which option mod you are using as it is definitely not the standard so that is to be verified. Look at all those and see if the changes bring you back to a normal page with options. Note: back up the original files that you modify by naming them for example product_infoOLD.php and then modify the file not renamed OLD so that you can always revert to the original in case of problems. Concerning your database back it up too before modifying it if upgrading tese mods needs database changes. There too you can restore your database if necessary. Take é aspirins and call me in the morning! Barbara Ok............I wil get starting today, thanks
Recommended Posts
Archived
This topic is now archived and is closed to further replies.