mindloop Posted April 1, 2006 Share Posted April 1, 2006 I believe STS uses the start and end of content html comments to extract and plugin the content in the template. You might need to add that to the compare.php page for the page to show using STS. HTH. sorry, i am new to php and sql, i dont quite understand what you mean can you be more specific, please? Quote Link to comment Share on other sites More sharing options...
Kjolebutikken Posted April 3, 2006 Share Posted April 3, 2006 sorry, i am new to php and sql, i dont quite understand what you meancan you be more specific, please? Hi, I'm also using sts and nothing shows on my page after installing this contribution. I also would like what to do to make this show and function. Here is a link to my shop to show you what it looks like: http://www.kjolebutikken.com/oscdemo1/index.php Thanks Kjolebutikken Quote Best regards Kjolebutikken Link to comment Share on other sites More sharing options...
Kjolebutikken Posted April 5, 2006 Share Posted April 5, 2006 Hi, I'm also using sts and nothing shows on my page after installing this contribution. I also would like what to do to make this show and function. Here is a link to my shop to show you what it looks like: http://www.kjolebutikken.com/oscdemo1/index.php Thanks Kjolebutikken Hi, did not solve the problem, but found out that sts is not the problem. I have put the new code for this contribution in my product_listing_col.php which I had from before. This file has been modified a few times with other contributions as well. I think I have implemented the code for this cintribution as I should, but nothing shows. I tried to use the product_listing_col.php file included in this contribution and now I can see the checkboxes and the buttonlink for the comparision, but when I press the button to compare, I get this error message on the compare.php page: 1146 - Table 'kjolebutikken_c.products_to_products_extra_fields' doesn't exist select distinct p.products_id, pef.products_extra_fields_id, pef.products_extra_fields_name from products p join products_to_products_extra_fields p2pef using (products_id) left join products_extra_fields pef on p2pef.products_extra_fields_id = pef.products_extra_fields_id where p.products_id in (29,30) and pef.products_extra_fields_status = 1 order by p.products_id, pef.products_extra_fields_order asc [TEP STOP] I'm not sure what may be wrong with my edited product_listing_col.php file. I would like to use this if possible, so if anyone could take the time to look at it for me, I would appreciate it. I also hope someone can help me with the error message I get. Thanks:-) Kjolebutikken Quote Best regards Kjolebutikken Link to comment Share on other sites More sharing options...
Kjolebutikken Posted April 12, 2006 Share Posted April 12, 2006 Hi, did not solve the problem, but found out that sts is not the problem. I have put the new code for this contribution in my product_listing_col.php which I had from before. This file has been modified a few times with other contributions as well. I think I have implemented the code for this cintribution as I should, but nothing shows. I tried to use the product_listing_col.php file included in this contribution and now I can see the checkboxes and the buttonlink for the comparision, but when I press the button to compare, I get this error message on the compare.php page: I'm not sure what may be wrong with my edited product_listing_col.php file. I would like to use this if possible, so if anyone could take the time to look at it for me, I would appreciate it. I also hope someone can help me with the error message I get. Thanks:-) Kjolebutikken Well, I have finally got it to work. The reason for the error is that I had forgotten to set this option in admin to false, as I have not installed the products extra fields contribution yet. And I was wrong about sts. Sts IS the reason for nothing showing up in the table on the compare.php page. The fix for this is to make a new set of the following files and give them another name as I have done, like this: includes/application_top1.php includes/application_bottom1.php includes/column_left1.php includes/column_right1.php includes/header1.php includes/footer1.php In the new files, remove all sts codes. Then in compare.php, change all require........ to the above files, to the new files instead. If you have named the new files like me, just add the number 1 to the filenames. Good luck. Kjolebutikken:-) Quote Best regards Kjolebutikken Link to comment Share on other sites More sharing options...
Ervino Posted April 24, 2006 Share Posted April 24, 2006 Dear all, I'm walking through this topic, but before installing I want to know for sure it's working with OScommerce MS2.2 with REGISTER_Global_OFF fix included. If this is the case, what is the latest full version? Am I correct that this is the 1.1 version and I should update that version with the 4 updates/fixes posted between 25 Oct till 21 Nov 2004? Thanks in advance. Quote Link to comment Share on other sites More sharing options...
bandix Posted May 8, 2006 Share Posted May 8, 2006 Is there any way to avoid the page to reload each time you select a product? Quote Link to comment Share on other sites More sharing options...
Kjolebutikken Posted May 8, 2006 Share Posted May 8, 2006 Is there any way to avoid the page to reload each time you select a product? I would also like a solution to this please. I think this reloading can be annoying for the customers:-) Anyone???? Thanks Kjolebutikken Quote Best regards Kjolebutikken Link to comment Share on other sites More sharing options...
♥bruyndoncx Posted May 16, 2006 Author Share Posted May 16, 2006 I would also like a solution to this please. I think this reloading can be annoying for the customers:-)Anyone???? Thanks Kjolebutikken Given time and/or money, I'm sure it can be done, but at the moment it's not. The main issue being that you might or might not have other contributions installed that embed the whole listing into a single form already, so any solution like that would have to cater for all kinds of variations which I personally didn't have time to investigate, test and support. Perhaps when the new oscommerce release 3 comes out, me or someone else might be motivated enough to do this "right" ;) Quote KEEP CALM AND CARRY ON I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support). So if you are still here ? What are you waiting for ?! Find the most frequent unique errors to fix: grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt Link to comment Share on other sites More sharing options...
Kjolebutikken Posted July 3, 2006 Share Posted July 3, 2006 Hi, I just installed the "Search engine friendly URL v.1.10" contribution, and my compare products page will not open. When I try to open it I get this error: Fatal error: Class 'url_rewrite' not found in /customers/kjolebutikken.com/kjolebutikken.com/httpd.www/oscdemo1/includes/functions/html_output.php on line 70 I've tried to ask on the Search engine friendly contribution support, but did not get any answer, so I will try here. Is it something special with the compare products page that provokes this error maybe? It works fine except for the compare products page and for another page which is for my printable catalog. Hope somebody can help. Thank you so much:-) Kjolebutikken Quote Best regards Kjolebutikken Link to comment Share on other sites More sharing options...
utkirbek Posted August 3, 2006 Share Posted August 3, 2006 and is there a contribution for showing categories with their imgaes on the index page? Yes, see here - http://www.oscommerce.com/community/contri..._categories+1.0 Quote Link to comment Share on other sites More sharing options...
sinjhin Posted August 9, 2006 Share Posted August 9, 2006 Hello I have a problem with this contrib : when I select a item, the screen refresh :blink: this is the link to my site includes/modules/product_listing.php <?php/* $Id: product_listing.php,v 1.1.1.1 2003/09/18 19:04:51 wilt Exp $ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright © 2003 osCommerce Released under the GNU General Public License */ $listing_split = new splitPageResults($listing_sql, MAX_DISPLAY_SEARCH_RESULTS, 'p.products_id'); if ( ($listing_split->number_of_rows > 0) && ( (PREV_NEXT_BAR_LOCATION == '1') || (PREV_NEXT_BAR_LOCATION == '3') ) ) { ?> <!--<table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td class="smallText"><?php echo $listing_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?></td> <td class="smallText" align="right"><?php echo TEXT_RESULT_PAGE . ' ' . $listing_split->display_links(MAX_DISPLAY_PAGE_LINKS, tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> </table>--> <?php } /* BoF Compare Products side-by-side */ echo tep_draw_form('compare', tep_href_link("compare.php", tep_get_all_get_params(array('action')))); ?> <?php /* EoF Compare Products side-by-side */ $list_box_contents = array(); /* BoF Compare Products side-by-side Insert first column to add checkbox to compare products */ $list_box_contents[0][] = array('align' => "center", 'params' => 'class="productListing-heading"', 'text' => TABLE_HEADING_COMPARE . '<br>' . tep_image_submit('button_compare.gif', IMAGE_BUTTON_COMPARE) . '</form>'); /* EoF Compare Products side-by-side */ 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[0][] = array('align' => $lc_align, 'params' => 'class="productListing-heading"', 'text' => ' ' . $lc_text . ' '); } if ($listing_split->number_of_rows > 0) { $rows = 0; /* BoF Compare Products side-by-side Generate hidden fields to submit with each checkbox */ $hidden_get_variables = ''; reset($HTTP_GET_VARS); while (list($key, $value) = each($HTTP_GET_VARS)) { if ((substr($key,0,8) != 'columns_') && ($key != tep_session_name()) && ($key != 'x') && ($key != 'y')) { $hidden_get_variables .= tep_draw_hidden_field($key, $value); } } /* EoF Compare Products side-by-side */ $listing_query = tep_db_query($listing_split->sql_query); while ($listing = tep_db_fetch_array($listing_query)) { $rows++; /* BoF Compare Products side-by-side Hide all columns selected except for this product, which will be generated by the checkbox form is needed */ $hidden_get_columns = ''; reset($HTTP_GET_VARS); while (list($key, $value) = each($HTTP_GET_VARS)) { if ((substr($key,0,8) == 'columns_') && ($key != 'columns_'.$listing['products_id']) ) { $hidden_get_columns .= tep_draw_hidden_field($key, $value); } } /* EoF Compare Products side-by-side */ if (($rows/2) == floor($rows/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; /* BoF Compare Products side-by-side Add checkbox to compare products */ $lc_align = 'center'; $lc_text = tep_draw_form('compare', tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) ), 'get'); $lc_text .= tep_draw_checkbox_field('columns_'.$listing['products_id'],$listing['products_id'],false,'onclick="this.form.submit();"'); $lc_text .= $hidden_get_variables; $lc_text .= $hidden_get_columns; $lc_text .= tep_hide_session_id(); $lc_text .= '</form>'; $list_box_contents[$cur_row][] = array('align' => $lc_align, 'params' => 'class="productListing-data"', 'text' => $lc_text); /* EoF Compare Products side-by-side */ 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> '; } $review_stars_query = tep_db_query("select round(avg(reviews_rating)) as rating from " . TABLE_REVIEWS . " where products_id = '" . $listing['products_id'] . "'"); $review_stars = tep_db_fetch_array($review_stars_query); if ($review_stars['rating'] > 0) { $lc_text .= '<br>' . TEXT_RATED . tep_image(DIR_WS_IMAGES . 'stars_' . $review_stars['rating'] . '.gif'); $lc_text .= ' <br> ' . YOUR_TEXT_SEE; $lc_text .= ' <font style="font-size: 8.5pt" color="#808080">|</font> ' . '<a href="' . tep_href_link(FILENAME_PRODUCT_REVIEWS_WRITE, 'products_id=' . $listing['products_id']) . '">' . YOUR_TEXT_WRITE; } else { $lc_text .= '<br> ' . YOUR_TEXT_NOT_RATED; $lc_text .= ' <font style="font-size: 8.5pt" color="#808080"></font> ' . '<a href="' . tep_href_link(FILENAME_PRODUCT_REVIEWS_WRITE, 'products_id=' . $listing['products_id']) . '">' . YOUR_TEXT_WRITE; } 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_get_products_special_price($listing['products_id'])) { $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(tep_get_products_special_price($listing['products_id']), 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_template_image_button('button_buy_now.gif', IMAGE_BUTTON_BUY_NOW) . '</a> '; break; } $list_box_contents[$cur_row][] = array('align' => $lc_align, 'params' => 'class="productListing-data"', 'text' => $lc_text); } } new productListingBox($list_box_contents); } else { $list_box_contents = array(); $list_box_contents[0] = array('params' => 'class="productListing-odd"'); $list_box_contents[0][] = array('params' => 'class="productListing-data"', 'text' => TEXT_NO_PRODUCTS); new productListingBox($list_box_contents); } if ( ($listing_split->number_of_rows > 0) && ((PREV_NEXT_BAR_LOCATION == '2') || (PREV_NEXT_BAR_LOCATION == '3')) ) { ?> <table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <tr> <td class="smallText"><?php echo $listing_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?></td> <td class="smallText" align="right"><?php echo TEXT_RESULT_PAGE . ' ' . $listing_split->display_links(MAX_DISPLAY_PAGE_LINKS, tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></td> </tr> </table> <?php } ?> Thank a lot to help me ... and excuse me for my english Quote Link to comment Share on other sites More sharing options...
WarWraith Posted October 25, 2006 Share Posted October 25, 2006 I've installed this contribution on my site, and I've sorted out most of the bugs that worried me, there are a couple of things I've been unable to resolve thus far. 1. Is there any way to move the Compare column from the left hand side to the right hand side? 2. Is there a way to give the Compare column a fixed width? 3. Is there a way to set the columns on the compare.php page to be an even width? On my store, when comparing two mice, one column is very wide, and one is very narrow. The store is here Thanks Quote Link to comment Share on other sites More sharing options...
Guest Posted November 11, 2006 Share Posted November 11, 2006 Hi, can you give me an actually, work link exaple of this contribution, in english please? Thx so much. Quote Link to comment Share on other sites More sharing options...
Rezolles_Net Posted December 15, 2006 Share Posted December 15, 2006 I've installed this contribution on my site, and I've sorted out most of the bugs that worried me, there are a couple of things I've been unable to resolve thus far. 1. Is there any way to move the Compare column from the left hand side to the right hand side? 2. Is there a way to give the Compare column a fixed width? 3. Is there a way to set the columns on the compare.php page to be an even width? On my store, when comparing two mice, one column is very wide, and one is very narrow. The store is here Thanks Hi WarWraith,may I know,how did you set a table at http://megamedia.com.au/index.php?cPath=2_19 ?Its look nice to me....Can you guide me... Thx Quote Link to comment Share on other sites More sharing options...
Rezolles_Net Posted December 15, 2006 Share Posted December 15, 2006 My table is mess around.....Take a look at http://www.rezolles.com/index.php?columns_...123&sort=2a Can anyone show me how to fix this? thx Quote Link to comment Share on other sites More sharing options...
Guest Posted February 15, 2007 Share Posted February 15, 2007 First off all, I'd like to say this contri kicksass! Now here is my situation... 1- Installed the contri v1.1 - all works great! ( I have a lot of other contri's installed aswell just to keep in mind ) 2- I read this thread over and over because I wanted a more detailed comparisation with extra fields. 3- I installed the PEF v2 contri. Works great aswell. 4- Now for the linkage between both there has been an update in v1.2 of the Compare Products SBS which enables the option for PEF including. 5- So I downloaded the v1.2 package. Used the remove.sql file to remove the old queries, and executed the changed install.sql 6- Then I also changed the compare.php from v1.1 to v1.2 7- This is where I get stuck... I have set the value of PEF to true in the Compare Products SBS module administration. My guess is that I missed a step somewhere... IE: When I add a new product and fill in the PEF information for that product. It shows up on the Admin-Preview-Before-Publish page. But when it is published on the shop itself this PEF information doesn't show anywhere... Also when I look in Product Listing in the main store config. There is no PEF there... Anyway been busy for hours now trying to figure it out. Any help is much appreciated! Cheers. Quote Link to comment Share on other sites More sharing options...
♥bruyndoncx Posted February 15, 2007 Author Share Posted February 15, 2007 But when it is published on the shop itself this PEF information doesn't show anywhere... if this is the case, to me it looks like your PEF contribution is not installed properly. After you have added PEF fields, can you see/edit them again from the admin interface ? Quote KEEP CALM AND CARRY ON I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support). So if you are still here ? What are you waiting for ?! Find the most frequent unique errors to fix: grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt Link to comment Share on other sites More sharing options...
Guest Posted February 19, 2007 Share Posted February 19, 2007 Hi, Yes, I can add/edit them in the admin interface. Then when publishing a product I can see the fields added there. I fill in the right information for the fields, then I get a preview of the product that I want to publish and the information is there. I hit save and check on the front-end side... The information is nowhere to be seen... So My guess is that there is something wrong with product_info.php ( Either I forgot some code or I have made a mistake ) Anyway here some pics to elaborate the situation: Cheers for the help! Quote Link to comment Share on other sites More sharing options...
♥bruyndoncx Posted February 19, 2007 Author Share Posted February 19, 2007 So, you have an issue first of all with the PEF installation. You should post in the PEF support thread, this thread is for issues with the Compare products module. I don't have PEF installed so no handson experience to easily tell what could have gone wrong or what to check for. Sorry. Quote KEEP CALM AND CARRY ON I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support). So if you are still here ? What are you waiting for ?! Find the most frequent unique errors to fix: grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt Link to comment Share on other sites More sharing options...
Guest Posted March 16, 2007 Share Posted March 16, 2007 Hi dear Carine Bruyndoncx. I read all this forum searching for a solution, but, =/, theres not. I still having troubles with this error: 1054 - Unknown column 'po.products_options_is_visible' in 'where clause' select distinct po.products_options_id, po.products_options_name as options, po.products_options_is_static as static from products p join products_description pd using (products_id) left join products_attributes pa using (products_id) left join products_options po on pa.options_id = po.products_options_id and pd.language_id = po.language_id left join products_options_values pov on pa.options_values_id = pov.products_options_values_id and pd.language_id = pov.language_id where p.products_id in (30,32) and (po.products_options_is_static = 0 or ( po.products_options_is_static = 1 and po.products_options_is_visible = 1) ) and pd.language_id = '3' order by p.products_id, po.products_options_is_static desc, po.products_options_name asc [TEP STOP] do you know why this happens? Cheers. :rolleyes: Quote Link to comment Share on other sites More sharing options...
♥bruyndoncx Posted March 16, 2007 Author Share Posted March 16, 2007 Hi dear Carine Bruyndoncx. I read all this forum searching for a solution, but, =/, theres not. I still having troubles with this error: do you know why this happens? Cheers. :rolleyes: product_options_is_static and product_options_is_visible are from the static options contribution. If you don't have that installed, you can just remove any reference to it in this query. Quote KEEP CALM AND CARRY ON I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support). So if you are still here ? What are you waiting for ?! Find the most frequent unique errors to fix: grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt Link to comment Share on other sites More sharing options...
vinod41 Posted May 21, 2007 Share Posted May 21, 2007 hi all i just followed this whole thread, and don't found any install doc. for this contribution. i've downloaded the package it only contain compare.php file and that demo link in first post was at parking. i'm looking for Install Documentation for compare module. where can i found it, i've already scribbled through this whole 12 page forum. many thanks. Quote Link to comment Share on other sites More sharing options...
vinod41 Posted May 22, 2007 Share Posted May 22, 2007 anyone ?????? Quote Link to comment Share on other sites More sharing options...
redstang308 Posted July 17, 2007 Share Posted July 17, 2007 Has anyone tried this Contrib with CRE Loaded? I am having a real problem. Can anyone please take a look at it: CRE Loaded Site With Contrib Please let me know if you know how to get this working for me. That would be GREAT!!! THANK YOU!! Quote Link to comment Share on other sites More sharing options...
njtermite Posted September 8, 2007 Share Posted September 8, 2007 Hi Guys, I'm having a problem with my compare, I have it installed on a custom layout. My compare button isn't showing up. My first check box on the page is acting like the compare button, when checked it takes it to the compare page. Could some please look at my code for me? Thanks, Mark product_listing.php <?php /* $Id: product_listing.php,v 1.44 2003/06/09 22:49:59 hpdl Exp $ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright (c) 2003 osCommerce Released under the GNU General Public License */ $listing_split = new splitPageResults($listing_sql, MAX_DISPLAY_SEARCH_RESULTS, 'p.products_id'); if ( ($listing_split->number_of_rows > 0) && ( (PREV_NEXT_BAR_LOCATION == '1') || (PREV_NEXT_BAR_LOCATION == '3') ) ) { ?> <table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td class="smallText"><?php echo $listing_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?></td> <td class="smallText" align="right"><?php echo TEXT_RESULT_PAGE . ' ' . $listing_split->display_links(MAX_DISPLAY_PAGE_LINKS, tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></td> </tr> </table> <?php } /* BoF Compare Products side-by-side */ echo tep_draw_form('compare', tep_href_link(basename('compare.php'), tep_get_all_get_params(array('action')) ));?> <?php /* EoF Compare Products side-by-side */ $list_box_contents = array(); /* BoF Compare Products side-by-side Insert first column to add checkbox to compare products */ $list_box_contents[0][] = array('align' => "center", 'params' => 'class="productListing-heading"', 'text' => TABLE_HEADING_COMPARE . '<br>' . tep_image_submit('button_continue.gif', IMAGE_BUTTON_CONTINUE) . '</form>'); /* EoF Compare Products side-by-side */ 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[0][] = array('align' => $lc_align, 'params' => 'class="productListing-heading"', 'text' => ' ' . $lc_text . ' '); } if ($listing_split->number_of_rows > 0) { $rows = 0; /* BoF Compare Products side-by-side Generate hidden fields to submit with each checkbox */ $hidden_get_variables = ''; reset($HTTP_GET_VARS); while (list($key, $value) = each($HTTP_GET_VARS)) { if ((substr($key,0,8) != 'columns_') && ($key != tep_session_name()) && ($key != 'x') && ($key != 'y')) { $hidden_get_variables .= tep_draw_hidden_field($key, $value); } } /* EoF Compare Products side-by-side */ $listing_query = tep_db_query($listing_split->sql_query); while ($listing = tep_db_fetch_array($listing_query)) { $rows++; /* BoF Compare Products side-by-side Hide all columns selected except for this product, which will be generated by the checkbox form is needed */ $hidden_get_columns = ''; reset($HTTP_GET_VARS); while (list($key, $value) = each($HTTP_GET_VARS)) { if ((substr($key,0,8) == 'columns_') && ($key != 'columns_'.$listing['products_id']) ) { $hidden_get_columns .= tep_draw_hidden_field($key, $value); } } /* EoF Compare Products side-by-side */ if (($rows/2) == floor($rows/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; /* BoF Compare Products side-by-side Add checkbox to compare products */ $lc_align = 'center'; // $lc_text = tep_draw_form('compare', tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=compare&columns_cnt='.$columns_cnt), 'get'); $lc_text = tep_draw_form('compare', tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) ), 'get'); $lc_text .= tep_draw_checkbox_field('columns_'.$listing['products_id'],$listing['products_id'],false,'onclick="this.form.submit();"'); $lc_text .= $hidden_get_variables; $lc_text .= $hidden_get_columns; $lc_text .= tep_hide_session_id(); $lc_text .= '</form>'; $list_box_contents[$cur_row][] = array('align' => $lc_align, 'params' => 'class="productListing-data"', 'text' => $lc_text); /* EoF Compare Products side-by-side */ for ($col=0, $n=sizeof($column_list); $col<$n; $col++) { $lc_align = ''; switch ($column_list[$col]) { case 'PRODUCT_LIST_MODEL': //$lc_align = ''; $lc_model_text = ' ' . $listing['products_model'] . ' '; $lc_model_2_text = ' ' . $listing['products_model_2'] . ' '; $products_type = ' ' . $listing['products_type'] . ' '; $products_code = ' ' . $listing['products_code'] . ' '; $products_short_description = $listing['products_info'] . ' '; $products_default_price = ' ' . $currencies->display_price($listing['products_default_price'], tep_get_tax_rate($listing['products_tax_class_id'])) . ' '; $products_lease_price = ' ' . $currencies->display_price($listing['products_lease_price'], tep_get_tax_rate($listing['products_tax_class_id'])) . ' '; $more_info_button = ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath=' . $cPath . '&' : '') . 'products_id=' . $listing['products_id']) . '">' . tep_image_button('more_info.gif', 'More Information') . '</a> '; 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_name = ' <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_manufacturer_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'; $lc_SS_price_text = ' ' . $currencies->display_price($listing['specials_new_products_price'], tep_get_tax_rate($listing['products_tax_class_id'])); $lc_dd_price_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_image_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_image_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_buy_now_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('add_to_cart.gif', IMAGE_BUTTON_BUY_NOW) . '</a> '; $lc_model_text = $listing['products_model']; $lc_model_2_text = $listing['products_model_2']; $products_model_3 = $listing['products_model_3']; $products_category = $listing['products_category']; $products_type = $listing['products_type']; $products_code = $listing['products_code']; $products_short_description = $listing['products_info']; $products_default_price = $currencies->display_price($listing['products_default_price'], tep_get_tax_rate($listing['products_tax_class_id'])); $products_lease_price = ' ' . $currencies->display_price($listing['products_lease_price'], tep_get_tax_rate($listing['products_tax_class_id'])) . ' '; $more_info_button = ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath=' . $cPath . '&' : '') . 'products_id=' . $listing['products_id']) . '">' . tep_image_button('more_info.gif', 'More Information') . '</a> '; $more_info_link_1 = ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath=' . $cPath . '&' : '') . 'products_id=' . $listing['products_id']) . '">' . "…details and options." . '</a> '; $lc_manufacturer_text = '<a href="' . tep_href_link(FILENAME_DEFAULT, 'manufacturers_id=' . $listing['manufacturers_id']) . '">' . $listing['manufacturers_name'] . '</a>'; break; } //$list_box_contents[$cur_row][] = array('align' => $lc_align, // 'params' => 'class="productListing-data"', //'text' => $lc_text); } ?> <table border="1" width="100%" cellspacing="0" bordercolor="#666666" cellpadding="0"> <tr> <td width="100%" > <table border="0" width="100%"> <tr> <td width="15%" rowspan="2" valign ="top"> <?php if ( $listing['specials_new_products_price'] != 0 ) { ?> <IMG SRC="images/bluelight_spacer.gif"><br> <IMG SRC="images/bluelight.gif"><br> <?php echo '<br>'; }else{ } ?> <?php echo $lc_image_text; ?><br> <IMG SRC="images/review1.gif"><br> <IMG SRC="images/review_spacer.gif"><br> <?php echo $lc_text; ?><IMG SRC="images/compare1.gif"> </td> <td width="15%" rowspan="2" valign ="top"><font id="productBox">Product Type</font> <font id="productBoxSubHeading">[Category]</font><font id="productBoxContent"><br><?php echo $products_category; ?></font><br> <font id="productBoxSubHeading">[Type]</font><br><font id="productBoxContent"><?php echo $products_type; ?></font><br> <font id="ProductBox">Manufacturer</font> <font id="productBoxSubHeading">[Make]</font><br><font id="productBoxContent"><?php echo $lc_manufacturer_text; ?></font><br> <font id="productBoxSubHeading">[Model]</font><br><font id="productBoxContent"><?php echo $lc_model_text; ?></font><br> <?php if ( $lc_model_2_text != "" ) { ?> <font id="productBoxContentModel2"> <?php echo ($lc_model_2_text). '<br>'; ?></font> <?php } ?> <?php if ( $products_model_3 != "" ) { ?> <font id="productBoxContentModel2"> <?php echo ($products_model_3). '<br>'; ?></font> <?php } ?> <font id="productBoxSubHeading">[Code]</font><br><font id="productBoxContentCode"><?php echo $products_code;?></td> <td width="50%" valign ="top"><center><font id="DescriptiontBox">Description</font></center> <?php echo $products_short_description . '<br>';?> </td> <td width="10%" valign ="top"><center><IMG SRC="images/signal_light1.gif"><br> <font id="productSalePrice"><?php echo $products_default_price; ?></font><br><br> <IMG SRC="images/signal_light2.gif"><br> <font id="productDDPrice"><?php echo $lc_dd_price_text; ?></font><br> <br> <?php if ( $listing['specials_new_products_price'] != 0 ) { ?> <IMG SRC="images/bluelight2.gif"><br> <font id="productSpecialPriceList"><?php echo $lc_SS_price_text; ?></font> <?php echo '<br>'; }else{ echo '<br>'; } ?> <?php if ( $listing['products_lease_price'] != 0 ) { ?> <font id="productLeaseFor">or lease for...</font><br> <font id="productLeaseMonthly">Monthly</font> <font id="productLeasePriceList"><?php echo $products_lease_price .'/36'; ?></font> <font id="productLeaseMonthly">Months</b></font> <?php echo '<br>'; }else{ echo '<br>'; } ?> </center> </td> </tr> <tr> <td width="50%" valign="top"><center><?php echo $more_info_button; ?></center> </td> <td width="10%" valign="top"><center><?php echo $lc_buy_now_text; ?></center> </td> </tr> </table></td> </tr> </table> <br> <? } // new productListingBox($list_box_contents); } else { $list_box_contents = array(); $list_box_contents[0] = array('params' => 'class="productListing-odd"'); $list_box_contents[0][] = array('params' => 'class="productListing-data"', 'text' => TEXT_NO_PRODUCTS); new productListingBox($list_box_contents); } if ( ($listing_split->number_of_rows > 0) && ((PREV_NEXT_BAR_LOCATION == '2') || (PREV_NEXT_BAR_LOCATION == '3')) ) { ?> <table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td class="smallText"><?php echo $listing_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?></td> <td class="smallText" align="right"><?php echo TEXT_RESULT_PAGE . ' ' . $listing_split->display_links(MAX_DISPLAY_PAGE_LINKS, tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></td> </tr> </table> <?php } ?> 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.