Foxtel Posted October 3, 2006 Share Posted October 3, 2006 </td>[/html] Is COLUMN_LEFT_WIDTH a constant you have defined somewhere that its suppose to evaluate to a number? Maybe this could be causing the issue. Hmm, to be honest im not sure, as im very new to this.. But what should that be? So do you think that is maybe causing the problem in all the files? Thanks a million for you help Lee. Looks like some of the tables need to be formatted to match the layout that you have. Try this... Change from this. <!-- body //--> </tr> </tbody> </table> <table border="0" cellpadding="2" cellspacing="1" width="100%"> <tbody> <tr> <td valign="top" width="125"> <table border="0" cellpadding="2" cellspacing="0" width="125"> <!-- left_navigation //--> To this. Note that the only change is in the 1st table parameters width="776" align="center" <!-- body //--> </tr> </tbody> </table> <table border="0" cellpadding="2" cellspacing="1" width="776" align="center"> <tbody> <tr> <td valign="top" width="125"> <table border="0" cellpadding="2" cellspacing="0" width="125"> <!-- left_navigation //--> This should now center that main body page. Now for COLUMN_LEFT_WIDTH, I think it should evaluate to a number. Looking at some or your <td> widths it might be 125. You should look in your code and find out where COLUMN_LEFT_WIDTH is defined to see what that number really is. There might be more formating to be done but lets see if this centers the page first. -Marizka Quote Link to comment Share on other sites More sharing options...
Guest Posted October 3, 2006 Share Posted October 3, 2006 I just installed HTC v2.5.9.1 and it seems to be working properly except for the admin section. When I update any of the fields on the Text Control page, any new information I have added disappears upon refresh BUT the info is still written to the DB. Any ideas on what is causing this? Quote Link to comment Share on other sites More sharing options...
Guest Posted October 4, 2006 Share Posted October 4, 2006 Hello I installed the Header Tags Controller contribution and follow all the instructions...in admin header tags every thing is normal, there isnt any error, but nothing happen when I see the index.php or any other page, the titles doesnt change...any ideas? Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted October 4, 2006 Share Posted October 4, 2006 I just installed HTC v2.5.9.1 and it seems to be working properly except for the admin section. When I update any of the fields on the Text Control page, any new information I have added disappears upon refresh BUT the info is still written to the DB. Any ideas on what is causing this?There is most likely a mistake in the admin/categories.php file changes. Try comparing your file to the one included in the contribution to find the problem. Jack Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
Jack_mcs Posted October 4, 2006 Share Posted October 4, 2006 Hello I installed the Header Tags Controller contribution and follow all the instructions...in admin header tags every thing is normal, there isnt any error, but nothing happen when I see the index.php or any other page, the titles doesnt change...any ideas? Look over the instructions in the Install_Catalog.txt file. It seems you may have missed some steps. Jack Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
hankster6911 Posted October 4, 2006 Share Posted October 4, 2006 (edited) I am looking to install Header tag controller as I have seen it recommended by several on the forums, I am trying to get the site I am working on as search engine friendly as possible. I already installed Ultimate SEO from a recommendation and the meta tag contrib. This is where my issue lies. Should I or can I have both the header tag controller and the meta tag? From what I have seen the meta tag contrib just took what was in the catalog and created the tags but with not much control over it. I see with this header tag I have lots more control and want to use it. I am at the start of the install where I am suppose to change the index.php this is what mine currently looks like <head> <meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>"> <?php require(DIR_WS_INCLUDES . 'meta_tags.php'); ?> <title><?php echo META_TAG_TITLE; ?></title> <meta name="description" content="<?php echo META_TAG_DESCRIPTION; ?>" /> <meta name="keywords" content="<?php echo META_TAG_KEYWORDS; ?>" /> <base href="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>"> <link rel="stylesheet" type="text/css" href="stylesheet.css"> </head> <body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0"> <!-- header //--> <?php require(DIR_WS_INCLUDES . 'header.php'); ?> <!-- header_eof //--> <!-- body //--> So I was wondering where I put this if I can use both contribs or remove the meta tag contrib. <?php // BOF: Header Tag Controller v2.5.7 if ( file_exists(DIR_WS_INCLUDES . 'header_tags.php') ) { require(DIR_WS_INCLUDES . 'header_tags.php'); } else { ?> <title><?php echo TITLE; ?></title> <?php } // EOF: Header Tag Controller v2.5.7 ?> Thanks for your time! Wendy Edited October 4, 2006 by hankster6911 Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted October 4, 2006 Share Posted October 4, 2006 You have to remove the other contribution. They perform the same function so only one will work. Jack Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
Grimmyfrombar Posted October 4, 2006 Share Posted October 4, 2006 ] This should now center that main body page. Now for COLUMN_LEFT_WIDTH, I think it should evaluate to a number. Looking at some or your <td> widths it might be 125. You should look in your code and find out where COLUMN_LEFT_WIDTH is defined to see what that number really is. There might be more formating to be done but lets see if this centers the page first. -Marizka WOW, thank you, that centered the page alright, its just a faction off now.. going to mess about abit more, ifyou have anymore suggestions please let me know.. day #2 as i try to install these header tags.. Thank you very much.. lee. Quote Link to comment Share on other sites More sharing options...
Grimmyfrombar Posted October 4, 2006 Share Posted October 4, 2006 ] This should now center that main body page. Now for COLUMN_LEFT_WIDTH, I think it should evaluate to a number. Looking at some or your <td> widths it might be 125. You should look in your code and find out where COLUMN_LEFT_WIDTH is defined to see what that number really is. There might be more formating to be done but lets see if this centers the page first. -Marizka WOW, thank you, that centered the page alright, its just a faction off now.. going to mess about abit more, ifyou have anymore suggestions please let me know.. day #2 as i try to install these header tags.. Thank you very much.. lee. Well here is the code for the header tags in the index.php file.. can anyone see whats wrong with it? <?php /* $Id: index.php,v 1.1 2003/06/11 17:37:59 hpdl Exp $ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright © 2003 osCommerce Released under the GNU General Public License */ $col_right_display = 'no'; require('includes/application_top.php'); // the following cPath references come from application_top.php $category_depth = 'top'; if (isset($cPath) && tep_not_null($cPath)) { $categories_products_query = tep_db_query("select count(*) as total from " . TABLE_PRODUCTS_TO_CATEGORIES . " where categories_id = '" . (int)$current_category_id . "'"); $cateqories_products = tep_db_fetch_array($categories_products_query); if ($cateqories_products['total'] > 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); // ADDED BY CLEMENT for design define('HEADING_IMAGE_FILE', 'table_background_default.gif'); require(DIR_WS_INCLUDES . FILENAME_DESIGN); //** ?> <!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN"> <HTML <?php echo HTML_PARAMS; ?>> <HEAD> <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=<?php echo CHARSET; ?>"> <TITLE><?php echo TITLE; ?></TITLE> <BASE HREF="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>"> <LINK REL="stylesheet" TYPE="text/css" HREF="stylesheet.css"> <?php echo HEAD_TAGS; ?> <?php echo BODY_TAG; ?> <!-- header //--> <?php require(DIR_WS_INCLUDES . 'header.php'); if (COLUMN_LEFT_DISPLAY == 'true') { echo '<!-- left_navigation //-->'; require(DIR_WS_INCLUDES . 'column_left.php'); echo '<!-- left_navigation_eof //-->'; } ?> <!-- body_text //--> <?php if ($category_depth == 'nested') { $category_query = tep_db_query("select cd.categories_name, c.categories_image, cd.categories_htc_title_tag, cd.categories_htc_description from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where c.categories_id = '" . (int)$current_category_id . "' and cd.categories_id = '" . (int)$current_category_id . "' and cd.language_id = '" . (int)$languages_id . "'");?> <TD <?php echo CONTENT_PARAM_FIRST_TD; ?>> <?php echo CONTENT_TOP_FIRST_TD; ?> <TABLE <?php echo CONTENT_PARAM_FIRST_TABLE; ?>> <TR> <TD><TABLE BORDER="0" WIDTH="100%" CELLSPACING="0" CELLPADDING="0"> <TR> <TD valign="top"><TABLE BORDER="0" WIDTH="100%" CELLSPACING="0" CELLPADDING="0"> <TR> <td><h1><?php echo $category['categories_htc_title_tag']; ?></h1></td> <td class="pageHeading" align="right"><?php echo tep_image(DIR_WS_IMAGES . $category['categories_image'], $category['categories_name'], HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT); ?></td> </tr> <?php if (tep_not_null($category['categories_htc_description'])) { ?> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <tr> <td><h2><?php echo $category['categories_htc_description']; ?></h2></td> </tr> <?php } ?> </TR> <TR> <TD><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></TD> </TR> <TR> <TD><TABLE BORDER="0" WIDTH="100%" CELLSPACING="0" CELLPADDING="2"> <TR> <TD><TABLE BORDER="0" WIDTH="100%" CELLSPACING="0" CELLPADDING="2"> <TR> <?php if (isset($cPath) && strpos('_', $cPath)) { // check to see if there are deeper categories within the current category $category_links = array_reverse($cPath_array); for($i=0, $n=sizeof($category_links); $i<$n; $i++) { $categories_query = tep_db_query("select count(*) as total from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where c.parent_id = '" . (int)$category_links[$i] . "' and c.categories_id = cd.categories_id and cd.language_id = '" . (int)$languages_id . "'"); $categories = tep_db_fetch_array($categories_query); if ($categories['total'] < 1) { // do nothing, go through the loop } else { $categories_query = tep_db_query("select c.categories_id, cd.categories_name, c.categories_image, c.parent_id from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where c.parent_id = '" . (int)$category_links[$i] . "' and c.categories_id = cd.categories_id and cd.language_id = '" . (int)$languages_id . "' order by sort_order, cd.categories_name"); break; // we've found the deepest category the customer is in } } } else { $categories_query = tep_db_query("select c.categories_id, cd.categories_name, c.categories_image, c.parent_id from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where c.parent_id = '" . (int)$current_category_id . "' and c.categories_id = cd.categories_id and cd.language_id = '" . (int)$languages_id . "' order by sort_order, cd.categories_name"); } $number_of_categories = tep_db_num_rows($categories_query); $rows = 0; while ($categories = tep_db_fetch_array($categories_query)) { $rows++; $cPath_new = tep_get_path($categories['categories_id']); $width = (int)(100 / MAX_DISPLAY_CATEGORIES_PER_ROW) . '%'; echo ' <td align="center" class="smallText" width="' . $width . '" valign="top"><a style="color: #D1D1D1;" href="' . tep_href_link(FILENAME_DEFAULT, $cPath_new) . '">' . tep_image(DIR_WS_IMAGES . $categories['categories_image'], $categories['categories_name'], SUBCATEGORY_IMAGE_WIDTH, SUBCATEGORY_IMAGE_HEIGHT) . '<br>' . $categories['categories_name'] . '</a></td>' . "\n"; if ((($rows / MAX_DISPLAY_CATEGORIES_PER_ROW) == floor($rows / MAX_DISPLAY_CATEGORIES_PER_ROW)) && ($rows != $number_of_categories)) { echo ' </tr>' . "\n"; echo ' <tr>' . "\n"; } } // needed for the new products module shown below $new_products_category_id = $current_category_id; ?> </TR> </TABLE></TD> </TR> <TR> <TD><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></TD> </TR> </TABLE></TD> </TR> </TABLE></TD> <TD WIDTH="<?php echo COLUMN_RIGHT_WIDTH; ?>" VALIGN="top" STYLE="background: url(images/design/bg_repeat_column_right.gif) repeat-y left top;"><?php include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS); ?></TD> </TR> </TABLE></TD> </TR> <?php echo CONTENT_BOTTOM_FIRST_TABLE; ?> </TABLE> <?php echo CONTENT_BOTTOM_FIRST_TD; ?> </TD> <?php } elseif ($category_depth == 'products' || isset($HTTP_GET_VARS['manufacturers_id'])) { // create column list $define_list = array('PRODUCT_LIST_MODEL' => 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 .= "final_price " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; } } ?> <TD <?php echo CONTENT_PARAM_FIRST_TD; ?>> <?php echo CONTENT_TOP_FIRST_TD; ?> <TABLE <?php echo CONTENT_PARAM_FIRST_TABLE; ?>> <TR> <TD>if (isset($HTTP_GET_VARS['manufacturers_id'])) $db_query = tep_db_query("select manufacturers_htc_title_tag as htc_title, manufacturers_htc_description as htc_description from " . TABLE_MANUFACTURERS_INFO . " where languages_id = '" . (int)$languages_id . "' and manufacturers_id = '" . (int)$HTTP_GET_VARS['manufacturers_id'] . "'"); else $db_query = tep_db_query("select categories_htc_title_tag as htc_title, categories_htc_description as htc_description from " . TABLE_CATEGORIES_DESCRIPTION . " where categories_id = '" . (int)$current_category_id . "' and language_id = '" . (int)$languages_id . "'"); $htc = tep_db_fetch_array($db_query); ?> <td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0"> <tr> <td><table border="0" width="100%" cellspacing="0" cellpadding="0"> <tr> <td><h1><?php echo $htc['htc_title']; ?></h1></td> </TR> <TR> <?php // optional Product List Filter if (PRODUCT_LIST_FILTER > 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 ' <td align="right" class="main" style="padding-right: 10px;">' . 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 '</form></td>' . "\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']; } ?> </TR> </TABLE></TD> </TR> <TR> <TD><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></TD> </TR> <TR> <TD><?php include(DIR_WS_MODULES . FILENAME_PRODUCT_LISTING); ?></TD> </TR> <?php echo CONTENT_BOTTOM_FIRST_TABLE; ?> </TABLE> <?php echo CONTENT_BOTTOM_FIRST_TD; ?> </TD> <?php require(DIR_WS_INCLUDES . 'column_right.php'); } else { // default page ?> <TD <?php echo CONTENT_PARAM_FIRST_TD; ?>> <?php echo CONTENT_TOP_FIRST_TD; ?> <TABLE <?php echo CONTENT_PARAM_FIRST_TABLE; ?>> <?php //echo CONTENT_TOP_FIRST_TABLE; ?> <TR> <TD><TABLE BORDER="0" WIDTH="100%" CELLSPACING="0" CELLPADDING="0"> <TR> if (isset($HTTP_GET_VARS['manufacturers_id'])) $db_query = tep_db_query("select manufacturers_htc_title_tag as htc_title, manufacturers_htc_description as htc_description from " . TABLE_MANUFACTURERS_INFO . " where languages_id = '" . (int)$languages_id . "' and manufacturers_id = '" . (int)$HTTP_GET_VARS['manufacturers_id'] . "'"); else $db_query = tep_db_query("select categories_htc_title_tag as htc_title, categories_htc_description as htc_description from " . TABLE_CATEGORIES_DESCRIPTION . " where categories_id = '" . (int)$current_category_id . "' and language_id = '" . (int)$languages_id . "'"); $htc = tep_db_fetch_array($db_query); ?> <td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0"> <tr> <td><table border="0" width="100%" cellspacing="0" cellpadding="0"> <tr> <td><h1><?php echo $htc['htc_title']; ?></h1></td> <?php echo CONTENT_TOP_FIRST_TABLE; ?> <TR> <TD CLASS="main"><?php echo tep_customer_greeting(); ?></TD> </TR> <TR> <TD><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></TD> </TR> <TR> <TD align="left" valign="middle" style="padding-left: 10px;"><img src="images/design/photo_index.jpg" border="0"></TD> </TR> <TR> <TD><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></TD> </TR> <TR> <TD CLASS="main"><?php echo TEXT_MAIN; ?></TD> </TR> <TR> <TD><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></TD> </TR> </TABLE> </TD> <TD WIDTH="<?php echo COLUMN_RIGHT_WIDTH; ?>" VALIGN="top" STYLE="background: url(images/design/bg_repeat_column_right.gif) repeat-y left top;"><?php include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS); ?></TD> </TR> <?php include(DIR_WS_MODULES . FILENAME_UPCOMING_PRODUCTS); ?> </TABLE></TD> </TR> <?php echo CONTENT_BOTTOM_FIRST_TABLE; ?> </TABLE> <?php echo CONTENT_BOTTOM_FIRST_TD; ?> </TD> <?php } ?> <!-- body_text_eof //--> <?php if (COLUMN_RIGHT_DISPLAY == 'true') { echo '<!-- right_navigation //-->'; require(DIR_WS_INCLUDES . 'column_right.php'); echo '<!-- right_navigation_eof //-->'; } require(DIR_WS_INCLUDES . 'footer.php'); ?> <?php echo ENDING_TAGS; ?> <?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?> Sorry to be asking all the time... damn it i cant seem to get it.. Thanks Lee. Quote Link to comment Share on other sites More sharing options...
Foxtel Posted October 4, 2006 Share Posted October 4, 2006 ] This should now center that main body page. Now for COLUMN_LEFT_WIDTH, I think it should evaluate to a number. Looking at some or your <td> widths it might be 125. You should look in your code and find out where COLUMN_LEFT_WIDTH is defined to see what that number really is. There might be more formating to be done but lets see if this centers the page first. -Marizka WOW, thank you, that centered the page alright, its just a faction off now.. going to mess about abit more, ifyou have anymore suggestions please let me know.. day #2 as i try to install these header tags.. Thank you very much.. lee. O.K, Now try the following to make the centered body align with the rest of the page. Change <!-- body //--> </tr> </tbody> </table> <table align="center" border="0" cellpadding="2" cellspacing="1" width="776"> <tbody> <tr> <td valign="top" width="125"> <table border="0" cellpadding="2" cellspacing="1" width="125"> <!-- left_navigation //--> To: <!-- body //--> </tr> </tbody> </table> <table align="center" border="0" cellpadding="0" cellspacing="0" width="776"> <tbody> <tr> <td valign="top" width="125"> <table border="0" cellpadding="0" cellspacing="0" width="125"> <!-- left_navigation //--> Chage: <!-- body_text //--> <td valign="top" width="100%"> <table border="0" cellpadding="0" cellspacing="0" width="10%"> <tbody> <tr> <td> <table border="0" cellpadding="0" cellspacing="0" width="10%"> <tbody> <tr> <td class="pageHeading"> Site Map </td> <td class="pageHeading" align="right"> <img src="images/table_background_specials.gif" alt="Site Map" title=" Site Map " border="0" height="40" width="57"> </td> </tr> </tbody> </table> </td> </tr> To: <!-- body_text //--> <td valign="top" width="100%"> <table border="0" cellpadding="0" cellspacing="0" width="10%"> <tbody> <tr> <td> <table border="0" cellpadding="0" cellspacing="0" width="553"> <tbody> <tr> <td class="pageHeading"> Site Map </td> <td class="pageHeading" align="right"> <img src="images/table_background_specials.gif" alt="Site Map" title=" Site Map " border="0" height="40" width="57"> </td> </tr> </tbody> </table> </td> </tr> -Marizka Quote Link to comment Share on other sites More sharing options...
Grimmyfrombar Posted October 4, 2006 Share Posted October 4, 2006 Right thank you very much... seems much better now.. Just one peice of code left , I keep getting this Parse error: parse error, unexpected '<' in /home/leather/public_html/catalog/index.php on line 294 form this: // Get the right image for the top-right <td align="right"><?php echo tep_image(DIR_WS_IMAGES . $image, $category['categories_htc_title_tag'], HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT); ?></td> </tr> <?php if (tep_not_null($htc['htc_description'])) { ?> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <tr> <td><h2><?php echo $htc['htc_description']; ?></h2></td> </tr> <?php } ?> Thank you very much, i dont know how i would have managed with out your help... Quote Link to comment Share on other sites More sharing options...
Foxtel Posted October 5, 2006 Share Posted October 5, 2006 Well here is the code for the header tags in the index.php file..can anyone see whats wrong with it? Thanks Lee. Looking over the index.php, there are two places that the starting <?php is missing. First <?php if (isset($HTTP_GET_VARS['manufacturers_id'])) <TD <?php echo CONTENT_PARAM_FIRST_TD; ?>> <?php echo CONTENT_TOP_FIRST_TD; ?> <TABLE <?php echo CONTENT_PARAM_FIRST_TABLE; ?>> <TR> <TD><?php if (isset($HTTP_GET_VARS['manufacturers_id'])) $db_query = tep_db_query("select manufacturers_htc_title_tag as htc_title, manufacturers_htc_description as htc_description from " . TABLE_MANUFACTURERS_INFO . " where languages_id = '" . (int)$languages_id . "' and manufacturers_id = '" . (int)$HTTP_GET_VARS['manufacturers_id'] . "'"); else $db_query = tep_db_query("select categories_htc_title_tag as htc_title, categories_htc_description as htc_description from " . TABLE_CATEGORIES_DESCRIPTION . " where categories_id = '" . (int)$current_category_id . "' and language_id = '" . (int)$languages_id . "'"); $htc = tep_db_fetch_array($db_query); ?> Second <?php if (isset($HTTP_GET_VARS['manufacturers_id'])) <TABLE <?php echo CONTENT_PARAM_FIRST_TABLE; ?>> <?php //echo CONTENT_TOP_FIRST_TABLE; ?> <TR> <TD><TABLE BORDER="0" WIDTH="100%" CELLSPACING="0" CELLPADDING="0"> <TR> <?php if (isset($HTTP_GET_VARS['manufacturers_id'])) $db_query = tep_db_query("select manufacturers_htc_title_tag as htc_title, manufacturers_htc_description as htc_description from " . TABLE_MANUFACTURERS_INFO . " where languages_id = '" . (int)$languages_id . "' and manufacturers_id = '" . (int)$HTTP_GET_VARS['manufacturers_id'] . "'"); else $db_query = tep_db_query("select categories_htc_title_tag as htc_title, categories_htc_description as htc_description from " . TABLE_CATEGORIES_DESCRIPTION . " where categories_id = '" . (int)$current_category_id . "' and language_id = '" . (int)$languages_id . "'"); $htc = tep_db_fetch_array($db_query); ?> -Marizka Quote Link to comment Share on other sites More sharing options...
daz_75 Posted October 5, 2006 Share Posted October 5, 2006 I've said this before but i believe there is a problem somewhere in this code. I have been through 1300 items and changed the header tags to something better than the default description. I use oscommerce product manager to update and add items to be product lists. Sometimes, when i use the fill empty header tags on my products it will reset all the ones i have manually changed back to their default description. As you can imagine, with 1300 products this is very annoying. Any ideas? Thanks Daz Quote Link to comment Share on other sites More sharing options...
Grimmyfrombar Posted October 5, 2006 Share Posted October 5, 2006 Hello, Just wondering should there be a file catalog/manufactures.php ?? As i dont seem to have one.. Thanks, Lee. Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted October 5, 2006 Share Posted October 5, 2006 No, the manufacturers display is handled by index.php. Jack Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
Grimmyfrombar Posted October 5, 2006 Share Posted October 5, 2006 (edited) Ok thank you, Well i got the code finished but for the index.php file, but its still red in in admin.. Any ideas? Here is the finished code <?php /* $Id: index.php,v 1.1 2003/06/11 17:37:59 hpdl Exp $ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright ? 2003 osCommerce Released under the GNU General Public License */ $col_right_display = 'no'; require('includes/application_top.php'); // the following cPath references come from application_top.php $category_depth = 'top'; if (isset($cPath) && tep_not_null($cPath)) { $categories_products_query = tep_db_query("select count(*) as total from " . TABLE_PRODUCTS_TO_CATEGORIES . " where categories_id = '" . (int)$current_category_id . "'"); $cateqories_products = tep_db_fetch_array($categories_products_query); if ($cateqories_products['total'] > 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); // ADDED BY CLEMENT for design define('HEADING_IMAGE_FILE', 'table_background_default.gif'); require(DIR_WS_INCLUDES . FILENAME_DESIGN); //** ?> <!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN"> <HTML <?php echo HTML_PARAMS; ?>> <HEAD> <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=<?php echo CHARSET; ?>"> <TITLE><?php echo TITLE; ?></TITLE> <BASE HREF="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>"> <LINK REL="stylesheet" TYPE="text/css" HREF="stylesheet.css"> <?php echo HEAD_TAGS; ?> <?php echo BODY_TAG; ?> <!-- header //--> <?php require(DIR_WS_INCLUDES . 'header.php'); if (COLUMN_LEFT_DISPLAY == 'true') { echo '<!-- left_navigation //-->'; require(DIR_WS_INCLUDES . 'column_left.php'); echo '<!-- left_navigation_eof //-->'; } ?> <!-- body_text //--> <?php if ($category_depth == 'nested') { $category_query = tep_db_query("select cd.categories_name, c.categories_image, cd.categories_htc_title_tag, cd.categories_htc_description from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where c.categories_id = '" . (int)$current_category_id . "' and cd.categories_id = '" . (int)$current_category_id . "' and cd.language_id = '" . (int)$languages_id . "'"); $category = tep_db_fetch_array($category_query); ?> <TD <?php echo CONTENT_PARAM_FIRST_TD; ?>> <?php echo CONTENT_TOP_FIRST_TD; ?> <TABLE <?php echo CONTENT_PARAM_FIRST_TABLE; ?>> <TR> <TD><TABLE BORDER="0" WIDTH="100%" CELLSPACING="0" CELLPADDING="0"> <TR> <TD valign="top"><TABLE BORDER="0" WIDTH="100%" CELLSPACING="0" CELLPADDING="0"> <TR> <TD CLASS="h1" valign="middle"><?php echo HEADING_TITLE; ?></TD> </tr> <?php if (tep_not_null($category['categories_htc_description'])) { ?> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <tr> <td><h2><?php echo $category['categories_htc_description']; ?></h2></td> </tr> <?php } ?> <TR> <TD><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></TD> </TR> <TR> <TD><TABLE BORDER="0" WIDTH="100%" CELLSPACING="0" CELLPADDING="2"> <TR> <TD><TABLE BORDER="0" WIDTH="100%" CELLSPACING="0" CELLPADDING="2"> <TR> <?php if (isset($cPath) && strpos('_', $cPath)) { // check to see if there are deeper categories within the current category $category_links = array_reverse($cPath_array); for($i=0, $n=sizeof($category_links); $i<$n; $i++) { $categories_query = tep_db_query("select count(*) as total from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where c.parent_id = '" . (int)$category_links[$i] . "' and c.categories_id = cd.categories_id and cd.language_id = '" . (int)$languages_id . "'"); $categories = tep_db_fetch_array($categories_query); if ($categories['total'] < 1) { // do nothing, go through the loop } else { $categories_query = tep_db_query("select c.categories_id, cd.categories_name, c.categories_image, c.parent_id from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where c.parent_id = '" . (int)$category_links[$i] . "' and c.categories_id = cd.categories_id and cd.language_id = '" . (int)$languages_id . "' order by sort_order, cd.categories_name"); break; // we've found the deepest category the customer is in } } } else { $categories_query = tep_db_query("select c.categories_id, cd.categories_name, c.categories_image, c.parent_id from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where c.parent_id = '" . (int)$current_category_id . "' and c.categories_id = cd.categories_id and cd.language_id = '" . (int)$languages_id . "' order by sort_order, cd.categories_name"); } $number_of_categories = tep_db_num_rows($categories_query); $rows = 0; while ($categories = tep_db_fetch_array($categories_query)) { $rows++; $cPath_new = tep_get_path($categories['categories_id']); $width = (int)(100 / MAX_DISPLAY_CATEGORIES_PER_ROW) . '%'; echo ' <td align="center" class="smallText" width="' . $width . '" valign="top"><a style="color: #D1D1D1;" href="' . tep_href_link(FILENAME_DEFAULT, $cPath_new) . '">' . tep_image(DIR_WS_IMAGES . $categories['categories_image'], $categories['categories_name'], SUBCATEGORY_IMAGE_WIDTH, SUBCATEGORY_IMAGE_HEIGHT) . '<br>' . $categories['categories_name'] . '</a></td>' . "\n"; if ((($rows / MAX_DISPLAY_CATEGORIES_PER_ROW) == floor($rows / MAX_DISPLAY_CATEGORIES_PER_ROW)) && ($rows != $number_of_categories)) { echo ' </tr>' . "\n"; echo ' <tr>' . "\n"; } } // needed for the new products module shown below $new_products_category_id = $current_category_id; ?> </TR> </TABLE></TD> </TR> <TR> <TD><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></TD> </TR> </TABLE></TD> </TR> </TABLE></TD> <TD WIDTH="<?php echo COLUMN_RIGHT_WIDTH; ?>" VALIGN="top" STYLE="background: url(images/design/bg_repeat_column_right.gif) repeat-y left top;"><?php include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS); ?></TD> </TR> </TABLE></TD> </TR> <?php echo CONTENT_BOTTOM_FIRST_TABLE; ?> </TABLE> <?php echo CONTENT_BOTTOM_FIRST_TD; ?> </TD> <?php } elseif ($category_depth == 'products' || isset($HTTP_GET_VARS['manufacturers_id'])) { // create column list $define_list = array('PRODUCT_LIST_MODEL' => 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 .= "final_price " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; } } ?> <TD <?php echo CONTENT_PARAM_FIRST_TD; ?>> <?php echo CONTENT_TOP_FIRST_TD; ?> <TABLE <?php echo CONTENT_PARAM_FIRST_TABLE; ?>> <?php if (isset($HTTP_GET_VARS['manufacturers_id'])) $db_query = tep_db_query("select manufacturers_htc_title_tag as htc_title, manufacturers_htc_description as htc_description from " . TABLE_MANUFACTURERS_INFO . " where languages_id = '" . (int)$languages_id . "' and manufacturers_id = '" . (int)$HTTP_GET_VARS['manufacturers_id'] . "'"); else $db_query = tep_db_query("select categories_htc_title_tag as htc_title, categories_htc_description as htc_description from " . TABLE_CATEGORIES_DESCRIPTION . " where categories_id = '" . (int)$current_category_id . "' and language_id = '" . (int)$languages_id . "'"); $htc = tep_db_fetch_array($db_query); ?> <TD><TABLE BORDER="0" WIDTH="100%" CELLSPACING="0" CELLPADDING="0"> <TR> <td><h1><?php echo $htc['htc_title']; ?></h1></td> </TR> <TR> <?php // optional Product List Filter if (PRODUCT_LIST_FILTER > 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 ' <td align="right" class="main" style="padding-right: 10px;">' . 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 '</form></td>' . "\n"; } } // Get the right image for the top-right 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']; } ?> </TR> </TABLE></TD> </TR> <TR> <TD><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></TD> </TR> <TR> <TD><?php include(DIR_WS_MODULES . FILENAME_PRODUCT_LISTING); ?></TD> </TR> <?php echo CONTENT_BOTTOM_FIRST_TABLE; ?> </TABLE> <?php echo CONTENT_BOTTOM_FIRST_TD; ?> </TD> <?php require(DIR_WS_INCLUDES . 'column_right.php'); } else { // default page ?> <TD <?php echo CONTENT_PARAM_FIRST_TD; ?>> <?php echo CONTENT_TOP_FIRST_TD; ?> <TABLE <?php echo CONTENT_PARAM_FIRST_TABLE; ?>> <?php //echo CONTENT_TOP_FIRST_TABLE; ?> <TR> <TD><TABLE BORDER="0" WIDTH="100%" CELLSPACING="0" CELLPADDING="0"> <TR> <TD valign="top"><TABLE BORDER="0" WIDTH="100%" CELLSPACING="0" CELLPADDING="0"> <?php echo CONTENT_TOP_FIRST_TABLE; ?> <TR> <TD CLASS="main"><?php echo tep_customer_greeting(); ?></TD> </TR> <TR> <TD><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></TD> </TR> <TR> <TD align="left" valign="middle" style="padding-left: 10px;"><img src="images/design/photo_index.jpg" border="0"></TD> </TR> <TR> <TD><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></TD> </TR> <TR> <TD CLASS="main"><?php echo TEXT_MAIN; ?></TD> </TR> <TR> <TD><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></TD> </TR> </TABLE> </TD> <TD WIDTH="<?php echo COLUMN_RIGHT_WIDTH; ?>" VALIGN="top" STYLE="background: url(images/design/bg_repeat_column_right.gif) repeat-y left top;"><?php include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS); ?></TD> </TR> <?php include(DIR_WS_MODULES . FILENAME_UPCOMING_PRODUCTS); ?> </TABLE></TD> </TR> <?php echo CONTENT_BOTTOM_FIRST_TABLE; ?> </TABLE> <?php echo CONTENT_BOTTOM_FIRST_TD; ?> </TD> <?php } ?> <!-- body_text_eof //--> <?php if (COLUMN_RIGHT_DISPLAY == 'true') { echo '<!-- right_navigation //-->'; require(DIR_WS_INCLUDES . 'column_right.php'); echo '<!-- right_navigation_eof //-->'; } require(DIR_WS_INCLUDES . 'footer.php'); ?> <?php echo ENDING_TAGS; ?> <?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?> Maybe i am missing some code as i might not have gotten the final peice right, thanks, Lee. Edited October 5, 2006 by Grimmyfrombar Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted October 5, 2006 Share Posted October 5, 2006 You didn't install the title code. Please see the Install_Catalog.txt file for installation instructions. Jack Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
Grimmyfrombar Posted October 5, 2006 Share Posted October 5, 2006 WOOOO HOOOO!!!!! Yes that was it thank you very much!!! Jes that took me long enough... So I am ready to go? Iven installed everything including the admin files and all seems ok... Only allprods is still red, how important is this? As i can seem to find that file. Thanks again, Lee. Quote Link to comment Share on other sites More sharing options...
Guest Posted October 5, 2006 Share Posted October 5, 2006 Hi, I'm hoping someone out there might be able to help figure out what I've done wrong. I had this contribution working perfectly on my previous installation but since I've moved my site to the root directory I haven't been able to get it working. I have the header tag file show up in my admin section, but nothing in my catergories or products (new or old) even after trying the auto fill option. I can't work out what I've missed. I don't know it will help if you look at My Webpage but please feel free. Any advice will be greatly appreciated. :-) Carol Quote Link to comment Share on other sites More sharing options...
strangename Posted October 6, 2006 Share Posted October 6, 2006 I was wondering if anyone has been able to get this great contribution to work with Dynamic MoPics or More Pics_6. I have successfully installed this contribution and it's working great but I don't think it likes to play with either of the above. Any help or suggestions would be gratefully appreciated. Thanks in advance Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted October 6, 2006 Share Posted October 6, 2006 WOOOO HOOOO!!!!! Yes that was it thank you very much!!! Jes that took me long enough... So I am ready to go? Iven installed everything including the admin files and all seems ok... Only allprods is still red, how important is this? As i can seem to find that file. Thanks again, Lee. The All Products with Images contribution provides the search engines with a quick link to all of your products. It is one of the "should have" SEO contributions. Jack Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
Jack_mcs Posted October 6, 2006 Share Posted October 6, 2006 Hi, I'm hoping someone out there might be able to help figure out what I've done wrong. I had this contribution working perfectly on my previous installation but since I've moved my site to the root directory I haven't been able to get it working. I have the header tag file show up in my admin section, but nothing in my catergories or products (new or old) even after trying the auto fill option. I can't work out what I've missed. I don't know it will help if you look at My Webpage but please feel free. Any advice will be greatly appreciated.:-) Carol What do you mean when you say nothing shows up in the catergories or products? Is that referring to your admin section or your shop? Jack Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
Jack_mcs Posted October 6, 2006 Share Posted October 6, 2006 I was wondering if anyone has been able to get this great contribution to work with Dynamic MoPics or More Pics_6. I have successfully installed this contribution and it's working great but I don't think it likes to play with either of the above. Any help or suggestions would be gratefully appreciated. Thanks in advance Yes, they work fine together. When you are installing the changes to the admin/categories.php file, you have to be careful to merge the sql statements since some are shared. Jack Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
rrrhythm Posted October 6, 2006 Share Posted October 6, 2006 (edited) While I like the Header Tags contrib, I found the behaviour of it confusing, with regard to the HTTA, HTKA, etc radio buttons, and the explanation included didn't help either. So I took the time to analyze it, and make a a chart of what it does. Note this is only in reference to index.php Also note there are two scenarios for index.php: either you're at the top (default) level, or you're at the category (or subcategory) level. In the following Index Title = whatever you enter in "Index Title" field on the Header Tags Text Control page, Default Title = whatever you enter into "Default Title" field on same page. Results are ordered at they will be on the page, and things that are added when a button is on are in blue text. All OFF: Top: Title = Index Title Key = Index Key Descrip = Index Descrip Category Level (Sub-Categories are similar with their own tags) Title = Category Title Key = Category Key Descrip =Category Descrip (short) HTTA ON: Adds Default Title Top: Title = Index Title - Default Title (note: it adds the spaces and the dash between Index Title and Default Title Key = Index Key Descrip = Index Descrip Category Level Title = Category Title - Default Title Key = Category Key Descrip =Category Descrip HTDA ON: Adds Default Description Top: Title = Index Title Key = Index Key Descrip = Index Descrip Default Description Category Level (Sub-Categories are similar with their own tags) Title = Category Title Key = Category Key Descrip =Category Descrip (short) Default Description HTKA ON: Adds Default Key to Top, Index Key to Categories Top: Title = Index Title Key = Default Key, Index Key (Note it adds the comma and space) Descrip = Index Descrip Category Level Title = Category Title Key = Category Key, Index Key (Note it adds the comma and space) Descrip =Category Descrip HTCA ON: Adds Index Title, Key and Descrip to Categories Top: Title = Index Title Key = Index Key Descrip = Index Descrip Category Level (Sub-Categories are similar with their own tags) Title = Category Title Index Title Key = Category Key, Index Key Descrip =Category Descrip (short) Index Descrip ALL ON: Top: Title = Index Title - Default Title Key = Default Key, Index Key Descrip = Index Descrip Default Description Category Level Title = Category Title Index Title - Default Title Key = Category Key, Default Key Index Key (comma between Cat and Default, not between Default and Index) Descrip =Category Descrip Index Descrip Default Descrip Why this particular ordering and logic, I'm not sure, but that's what it is. also, I referenced "Category Descrip (short)". That's because when you edit a category, there are two fields, a short one marked "Header Tags Category Description" and a long one at the bottom marked "Header Tags Categories Description". On the install i did, this longer field wasn't originally used for anything, but I used it to put a description of each category at the top of that page. cheers, rj Edited October 6, 2006 by rrrhythm Quote Link to comment Share on other sites More sharing options...
hankster6911 Posted October 6, 2006 Share Posted October 6, 2006 Thank you for your reply about this contrib v meta tag, I will be adding this one. Has anyone added this with More_pics_6 v1.1, I thought I may have read about some problems with them working together. Wendy Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.