Guest Posted February 17, 2011 Share Posted February 17, 2011 Ok Guys, I thought I had corrected the child category issue with r01. However it would appear I have not. I will make revisions to correct the issue and upload another revision in a couple of days. Sorry for the confusion. Chris Quote Link to comment Share on other sites More sharing options...
netsub Posted February 17, 2011 Share Posted February 17, 2011 Thank you very much Chris! The module you're rebuilding is a great thing that many people expect, I searched the Internet for more than 20 days a module that makes almost the same as yours but it is impossible to find! In other words both Joomla, Magento, CsCart, ZenCart, and many more ... The problem is just the final sorting by category, after sorting "make model year", and your module can almost do that! Thank you again Nathan! Quote Link to comment Share on other sites More sharing options...
netsub Posted February 17, 2011 Share Posted February 17, 2011 I think the problem is that originally the module considers that if all the products have not been published according to make module year, they will be posted as universal products valid for all other year make module ... The original help filefor osc 2.2 : NOTE: If You Have Added A Few data only to items All The Other items Always Will Be Shown Because The items Without model / make / year / set are Treated as for all models, all year, all Makes if you want to select only BMW BMW products and see all products The Other Should Be Set to another car. So you should "edit all your products to see The Effect Quote Link to comment Share on other sites More sharing options...
easyq Posted February 22, 2011 Share Posted February 22, 2011 Not a comment nor a problem but a question for advice here. i sell doorsills, dashtrimkits, doorskirts and bootstrips all from stainless steel. That means if 1 car/model would have all of this available there would be max 4 articles available. For most there is max of 2 different articles for a car/model. Which of you using this contrib thinks it would be wise to add this, based on usage by customers in a similar number of items available in your shop? And, because i didnot install it yet, is it easy fillable through an excel sheet or via EP or do i have to add all manually one by one? Appreciate your feedback on this, in case you wanna look, peek at www.jamello.nl (Dutch market based so only available in Dutch, sorry) Quote Everything is conditional, you just can't always anticipate the conditions. Link to comment Share on other sites More sharing options...
wildvettes Posted March 9, 2011 Share Posted March 9, 2011 Quick question, I'm getting serious formatting issues with my right or left columns after the install. Everything appears to be working normally but it threw the column widths way off on my default theme. Even when I uninstall the module now and try to go back to the default look, my columns are way off. I know this is probably simple formatting, but I'm new to this stuff. How can I make the columns go back to the desired size? Quote Link to comment Share on other sites More sharing options...
wildvettes Posted March 9, 2011 Share Posted March 9, 2011 Quick question, I'm getting serious formatting issues with my right or left columns after the install. Everything appears to be working normally but it threw the column widths way off on my default theme. Even when I uninstall the module now and try to go back to the default look, my columns are way off. I know this is probably simple formatting, but I'm new to this stuff. How can I make the columns go back to the desired size? I just took every single box out and the formatting went back to normal. I figured adding them back in one at a time could identify the problem. It is doing the same thing for one or all boxes, whether left or right side... Quote Link to comment Share on other sites More sharing options...
wildvettes Posted March 9, 2011 Share Posted March 9, 2011 I just took every single box out and the formatting went back to normal. I figured adding them back in one at a time could identify the problem. It is doing the same thing for one or all boxes, whether left or right side... It is doing something with the content that normally shows up in the middle of my two columns as it vanishes and the formatting goes bad after the change to index.php Any ideas? I will note however that even without this coding it does this same thing when the box is enabled, otherwise everything is as it should be. I back tracked through the code changes and it doesn't start having the problem until you change the index.php by adding the following include(DIR_WS_MODULES . FILENAME_PRODUCT_LISTING); ?> </div> <?php } //bof Year_Make_Model Contribution v2.3.x by Dunweb Designs elseif($_GET['Make'] || $_GET['Model'] || $_GET['Year']){ $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; } } if($current_category_id){ $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 left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c where " . (YMM_FILTER_PRODUCT_LISTING == 'Yes' ? $YMM_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 . "'"; }else{ $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 left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c where " . (YMM_FILTER_PRODUCT_LISTING == 'Yes' ? $YMM_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 . "'"; } if ( (!isset($HTTP_GET_VARS['sort'])) || (!preg_match('/^[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); switch ($column_list[$sort_col-1]) { case 'PRODUCT_LIST_MODEL': $listing_sql .= " order by p.products_model " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; case 'PRODUCT_LIST_NAME': $listing_sql .= " order by pd.products_name " . ($sort_order == 'd' ? 'desc' : ''); break; case 'PRODUCT_LIST_MANUFACTURER': $listing_sql .= " order by m.manufacturers_name " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; case 'PRODUCT_LIST_QUANTITY': $listing_sql .= " order by p.products_quantity " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; case 'PRODUCT_LIST_IMAGE': $listing_sql .= " order by pd.products_name"; break; case 'PRODUCT_LIST_WEIGHT': $listing_sql .= " order by p.products_weight " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; case 'PRODUCT_LIST_PRICE': $listing_sql .= " order by final_price " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; } } $catname = HEADING_TITLE; if (isset($HTTP_GET_VARS['manufacturers_id'])) { $image = tep_db_query("select manufacturers_image, manufacturers_name as catname from " . TABLE_MANUFACTURERS . " where manufacturers_id = '" . (int)$HTTP_GET_VARS['manufacturers_id'] . "'"); $image = tep_db_fetch_array($image); $catname = $image['catname']; } elseif ($current_category_id) { $image = tep_db_query("select c.categories_image, cd.categories_name as catname from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where c.categories_id = '" . (int)$current_category_id . "' and c.categories_id = cd.categories_id and cd.language_id = '" . (int)$languages_id . "'"); $image = tep_db_fetch_array($image); $catname = $image['catname']; } ?> <h1><?php echo $catname; ?></h1> <div class="contentContainer"> <?php include(DIR_WS_MODULES . FILENAME_PRODUCT_LISTING); echo '</div>'; //eof Year_Make_Model Contribution v2.3.x by Dunweb Designs ?> Quote Link to comment Share on other sites More sharing options...
PupStar Posted March 9, 2011 Share Posted March 9, 2011 do you have a url so we can see what you mean? It is doing something with the content that normally shows up in the middle of my two columns as it vanishes and the formatting goes bad after the change to index.php Any ideas? I will note however that even without this coding it does this same thing when the box is enabled, otherwise everything is as it should be. I back tracked through the code changes and it doesn't start having the problem until you change the index.php by adding the following include(DIR_WS_MODULES . FILENAME_PRODUCT_LISTING); ?> </div> <?php } //bof Year_Make_Model Contribution v2.3.x by Dunweb Designs elseif($_GET['Make'] || $_GET['Model'] || $_GET['Year']){ $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; } } if($current_category_id){ $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 left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c where " . (YMM_FILTER_PRODUCT_LISTING == 'Yes' ? $YMM_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 . "'"; }else{ $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 left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c where " . (YMM_FILTER_PRODUCT_LISTING == 'Yes' ? $YMM_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 . "'"; } if ( (!isset($HTTP_GET_VARS['sort'])) || (!preg_match('/^[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); switch ($column_list[$sort_col-1]) { case 'PRODUCT_LIST_MODEL': $listing_sql .= " order by p.products_model " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; case 'PRODUCT_LIST_NAME': $listing_sql .= " order by pd.products_name " . ($sort_order == 'd' ? 'desc' : ''); break; case 'PRODUCT_LIST_MANUFACTURER': $listing_sql .= " order by m.manufacturers_name " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; case 'PRODUCT_LIST_QUANTITY': $listing_sql .= " order by p.products_quantity " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; case 'PRODUCT_LIST_IMAGE': $listing_sql .= " order by pd.products_name"; break; case 'PRODUCT_LIST_WEIGHT': $listing_sql .= " order by p.products_weight " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; case 'PRODUCT_LIST_PRICE': $listing_sql .= " order by final_price " . ($sort_order == 'd' ? 'desc' : '') . ", pd.products_name"; break; } } $catname = HEADING_TITLE; if (isset($HTTP_GET_VARS['manufacturers_id'])) { $image = tep_db_query("select manufacturers_image, manufacturers_name as catname from " . TABLE_MANUFACTURERS . " where manufacturers_id = '" . (int)$HTTP_GET_VARS['manufacturers_id'] . "'"); $image = tep_db_fetch_array($image); $catname = $image['catname']; } elseif ($current_category_id) { $image = tep_db_query("select c.categories_image, cd.categories_name as catname from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where c.categories_id = '" . (int)$current_category_id . "' and c.categories_id = cd.categories_id and cd.language_id = '" . (int)$languages_id . "'"); $image = tep_db_fetch_array($image); $catname = $image['catname']; } ?> <h1><?php echo $catname; ?></h1> <div class="contentContainer"> <?php include(DIR_WS_MODULES . FILENAME_PRODUCT_LISTING); echo '</div>'; //eof Year_Make_Model Contribution v2.3.x by Dunweb Designs ?> Quote Link to comment Share on other sites More sharing options...
kenkja Posted March 11, 2011 Share Posted March 11, 2011 I have already installed the various add ons in the Security Forum Post 1, language packs and a payment module. So I guess I no longer have a clean installation as required by the YMM install guidelines, does this mean I would have to make a new installation to use YMM. thanks Ken Quote Os-commerce v2.3.3 Security Pro v11 Site Monitor IP Trap htaccess Protection Bad Behaviour Block Year Make Model Document Manager X Sell Star Product Modular Front Page Modular Header Tags Link to comment Share on other sites More sharing options...
Guest Posted March 11, 2011 Share Posted March 11, 2011 Ken, Along with the Drop on Top files for vanilla installations, there are manual installation instructions included for modified sites. Chris Quote Link to comment Share on other sites More sharing options...
RMD27 Posted March 11, 2011 Share Posted March 11, 2011 (edited) Hello Chris Maybe it is a backward step for you but I am using 2.2. I looked at the 2.2 version of YMM and from what I saw you have to enter the data it needs manually. My question is, instead of YMM having its own table, can it be made so it uses the product description table (and adds its own fields). This way everything can be edited through Easy Populate With Easy Populate you would not need to put mutiple cars for one part number, you would have one part number and the one car that it fits. Also with Easy Populate you would no longer need to use anything in the admin for it too work, so you could strip out the admin side of the install What are thoughts on integrating YMM with Easy Populate? Edited March 11, 2011 by RMD27 Quote Link to comment Share on other sites More sharing options...
Guest Posted March 11, 2011 Share Posted March 11, 2011 Hi Ricardo, I am sure YMM can be altered to integrate fields into existing tables, but this would require SQL paths to be altered. It isn't a bad idea, perhaps someone with more time will make a transition version. Chris Quote Link to comment Share on other sites More sharing options...
kenkja Posted March 12, 2011 Share Posted March 12, 2011 Thank you Chris My apologies, must have misread the file before ken Quote Os-commerce v2.3.3 Security Pro v11 Site Monitor IP Trap htaccess Protection Bad Behaviour Block Year Make Model Document Manager X Sell Star Product Modular Front Page Modular Header Tags Link to comment Share on other sites More sharing options...
RMD27 Posted March 12, 2011 Share Posted March 12, 2011 Hi Ricardo, I am sure YMM can be altered to integrate fields into existing tables, but this would require SQL paths to be altered. It isn't a bad idea, perhaps someone with more time will make a transition version. Chris Okay, instead of getting changing the SQL paths, I was thinking it might be easier to customise EP to work with YMM contribution If you can bear with me because I don't know code! These are the instructions EP gives to add data to custom fields in the product description // ****************************************************************** // BEGIN Define Custom Fields for your products database // ****************************************************************** // the following line is always left as is. $custom_fields = array(); // // The following setup will allow you to define any additional // field into the "products" and "products_description" tables // in your shop. If you have installed a custom contribution // that adds fields to these tables you may simply and easily add // them to the EasyPopulate system. // // ******************** // ** products table ** // Lets say you have added a field to your "products" table called // "products_upc". The header name in your import file will be // called "v_products_upc". Then below you will change the line // that looks like this (without the comment double-slash at the beginning): // $custom_fields[TABLE_PRODUCTS] = array(); // this line is used if you have no custom fields to import/export // // TO: // $custom_fields[TABLE_PRODUCTS] = array( 'products_upc' => 'UPC' ); // // If you have multiple fields this is what it would look like: // $custom_fields[TABLE_PRODUCTS] = array( 'products_upc' => 'UPC', 'products_restock_quantity' => 'Restock' ); // // ******************************** // ** products_description table ** // Lets say you have added a field to your "products_description" table called // "products_short_description". The header name in your import file will be // called "v_products_short_description_1" for English, "v_products_short_description_2" for German, // "v_products_short_description_3" for Spanish. Other languages will vary. Be sure to use the // langugage ID of the custom language you installed if it is other then the original // 3 installed languages of osCommerce. If you are unsure what language ID you need to // use, do a complete export and examine the file headers EasyPopulate produces. // // Then below you will change the line that looks like this (without the comment double-slash at the beginning): // $custom_fields[TABLE_PRODUCTS_DESCRIPTION] = array(); // this line is used if you have no custom fields to import/export // // TO: // $custom_fields[TABLE_PRODUCTS_DESCRIPTION] = array( 'products_short_description' => 'short' ); // // If you have multiple fields this is what it would look like: // $custom_fields[TABLE_PRODUCTS_DESCRIPTION] = array( 'products_short_description' => 'short', 'products_viewed' => 'Viewed' ); // // the array format is: array( 'table_field_name' => 'Familiar Name' ) // the array key ('table_field_name') is always the exact name of the // field in the table. The array value ('Familiar Name') is any text // name that will be used in the custom EP export download checkbox. // // I believe this will only work for text/varchar and numeric field // types. If your custom field is a date/time or any other type, you // may need to incorporate custom code to correctly import your data. // $custom_fields[TABLE_PRODUCTS] = array(); // this line is used if you have no custom fields to import/export $custom_fields[TABLE_PRODUCTS_DESCRIPTION] = array(); // this line is used if you have no custom fields to import/export // // FINAL NOTE: this currently only works with the "products" & "products_description" table. // If it works well and I don't get a plethora of problems reported, // I may expand it to more tables. Feel free to make requests, but // as always, only as me free time allows. // // ****************************************************************** // END Define Custom Fields for your products database // ****************************************************************** To use it with YMM, can I change TABLE_PRODUCTS_DESCRIPTION to TABLE_TheNameOfTheTableYMMUses and change 'products_short_description' => 'short' to 'products_TheNameOfTheFieldYMMUses' => 'YMMfield' and that is all you need to do as far as populating the database with the data that YMM needs (in principle at least)? Quote Link to comment Share on other sites More sharing options...
kenkja Posted March 12, 2011 Share Posted March 12, 2011 Re Part 9B 9.b] Find: include(DIR_WS_MODULES . FILENAME_PRODUCT_LISTING); ?> </div> <?php } Add after: etc //bof Year_Make_Model Contribution v2.3.x by Dunweb Designs elseif($_GET['Make'] || $_GET['Model'] || $_GET['Year']){ $define_list = array('PRODUCT_LIST_MODEL' => PRODUCT_LIST_MODEL, 'PRODUCT_LIST_NAME' => PRODUCT_LIST_NAME, 'PRO etc, etc I found include(DIR_WS_MODULES . FILENAME_PRODUCT_LISTING); ?> </div> <?php } else { // default page ?> So I added the code after } and before else { // default page, then I'm left with a line of code else { // default page which produces an error message "Parse error: syntax error, unexpected T_ELSE in /home/public_html/mysite.com/index.php on line 378" I've added // before it, so it's no longer a command index.php will load, but I don't think that what I'm supposed to be doing, is it ? Ken Quote Os-commerce v2.3.3 Security Pro v11 Site Monitor IP Trap htaccess Protection Bad Behaviour Block Year Make Model Document Manager X Sell Star Product Modular Front Page Modular Header Tags Link to comment Share on other sites More sharing options...
kenkja Posted March 12, 2011 Share Posted March 12, 2011 Hello have fixed the above thanks Ken Quote Os-commerce v2.3.3 Security Pro v11 Site Monitor IP Trap htaccess Protection Bad Behaviour Block Year Make Model Document Manager X Sell Star Product Modular Front Page Modular Header Tags Link to comment Share on other sites More sharing options...
kenkja Posted March 12, 2011 Share Posted March 12, 2011 Hello All Me again I'm now working on making the add-on work in other languages. I've dealt with adding the bm_year_make_model.php to the includes/languages/"Country Language"/Modules/boxes/ folder and thus changed the title of the YMM box as it appears on index.php But the first line on each drop down list is still in English. As far as I can work out these titles are given by the includes/modules/boxes/bm_year_make_model.php file in lines 30,31 & 32, as below $Make_array[] = array('id' => 'all', 'text' => 'Choose Vehicle'); $Model_array[] = array('id' => 'all', 'text' => 'Choose Model'); $Year_array[] = array('id' => 0, 'text' => 'Choose Year'); If I require two languages, say english and german, should I replace these with say $Make_array[] = array('id' => 'Whatever id represents English', 'text' => 'Choose Vehicle' 'id' => "Whatever id represent German', 'text' => 'German text'); etc, etc thanks ken Quote Os-commerce v2.3.3 Security Pro v11 Site Monitor IP Trap htaccess Protection Bad Behaviour Block Year Make Model Document Manager X Sell Star Product Modular Front Page Modular Header Tags Link to comment Share on other sites More sharing options...
kenkja Posted March 14, 2011 Share Posted March 14, 2011 Regarding last post, it would be great to have the first lines of the created arrays language specific, but as it is reasonable obvious what should be done even if you don't speak/read english, its not a big deal. More concerning is I don't think I have the install correct as I have 2 issues which I didn't expect. 1. Unless there is at least 1 product with YMM attributes the whole index.php page looses its formatting quite dramatically. The centre section (which contains the user greeting) disappears, both left & right _column(s) change width, the "OS Commerce" logo become left justified and the YMM box has no title. Clearly the obvious answer is to keep a product with YMM attributes, but is this normal ?? 2. Within Admin create/edit a product 2 lines of the coding appear as text between the page title and the product status lines - Page Title - New Product in "Clothing =>Shirts" Text Code - //bof Year_Make_Model Contribution V2.3.x by Dunweb Designs Text Code - //eof Year_Make_Model Contribution V2.3.x by Dunweb Designs Then - Product Status In Stock/Out of stock line Again as these lines are only text, they don't really matter, but are something I didn't expect. I've doubled checked the files affected by the install with the readme.txt file and copied all of them into a spreadsheet along with all of those from the "Drop on Top Files" folder, then asked the spreadsheet to compare each line. Aside from some changes in includes/application_top.php as required by the Secuirty Pro & Ip Trap contributions and some colour changes in stylesheet.css, all of my files appear identical to the "Drop on Top Files" with the exception of Includes/application_top.php My Code - Define('PROJECT_VERSION', 'osCommerce Online Merchant v2.3'); Drop on Top - Define('PROJECT_VERSION', 'osCommerce Online Merchant v2.3.1'); Include/Functions/general.php Instruction 8b of the readme.txt requires the following code to be added before the last ?> the two lines in Red bold type are not in the "Drop on Top Files" version //bof Year_Make_Model Contribution v2.3.x by Dunweb Designs function YMM_get_categories_where($id,$where){ global $languages_id; $cq = tep_db_query("SELECT c.categories_id, c.parent_id FROM " . TABLE_CATEGORIES . " c," . TABLE_CATEGORIES_DESCRIPTION . " cd WHERE c.categories_id = cd.categories_id AND cd.language_id = '" . (int)$languages_id . "'"); $inc_cat = array(); while ($r = tep_db_fetch_array($cq)) $inc_cat[] = array ('id' => $r['categories_id'],'parent' => $r['parent_id']); $cat_info = array(); for ($i=0; $i < sizeof($inc_cat); $i++) $cat_info[$inc_cat[$i]['id']] = array ('parent'=> $inc_cat[$i]['parent'],'path' => array($inc_cat[$i]['id'])); for ($i=0; $i < sizeof($inc_cat); $i++) { $cat_id = $inc_cat[$i]['id']; while ($cat_info[$cat_id]['parent'] != 0){ $cat_info[$inc_cat[$i]['id']]['path'] [] = $cat_info[$cat_id]['parent']; if($cat_info[$cat_id]['parent'] == $id) $cat_info[$inc_cat[$i]['id']]['ind'] = count($cat_info[$inc_cat[$i]['id']]['path']) - 2; $cat_id = $cat_info[$cat_id]['parent']; } $cat_info[$inc_cat[$i]['id']]['path'] [] = 0; if($cat_info[$cat_id]['parent'] == $id) $cat_info[$inc_cat[$i]['id']]['ind'] = count($cat_info[$inc_cat[$i]['id']]['path']) - 2; } $ids = ''; if(trim($where) != 'p.products_id in () and'){ for ($i=0; $i < sizeof($inc_cat); $i++) { if(isset($cat_info[$inc_cat[$i]['id']]['ind'])){ $q = tep_db_query("select c.categories_id FROM " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_TO_CATEGORIES . " pc, " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd WHERE $where p.products_id = pc.products_id AND c.categories_id = pc.categories_id AND p.products_status = '1' AND c.categories_id = ".$cat_info[$inc_cat[$i]['id']]['path'][0]." AND c.categories_id = cd.categories_id AND cd.language_id = '" . (int)$languages_id . "' LIMIT 1"); if(tep_db_num_rows($q) == 1) $ids .= ($ids != '' ? ',' : '') . $cat_info[$inc_cat[$i]['id']]['path'][$cat_info[$inc_cat[$i]['id']]['ind']]; } } return ($ids != '' ? ' c.categories_id in ('.$ids.') and ' : ''); } } //eof Year_Make_Model Contribution v2.3.x by Dunweb Designs Also the "Drop on top files" folder includes categories.php with the Admin/Includes/Languages directory, however in my install this is in admin/includes/languages/english ken silverkorn 1 Quote Os-commerce v2.3.3 Security Pro v11 Site Monitor IP Trap htaccess Protection Bad Behaviour Block Year Make Model Document Manager X Sell Star Product Modular Front Page Modular Header Tags Link to comment Share on other sites More sharing options...
kenkja Posted March 14, 2011 Share Posted March 14, 2011 (edited) I'm not sure why, but removing the //bof .... & //eof... from code copied into admin/catgories.php (2b in readme.txt) seems to have corrected the admin. ken Edited March 14, 2011 by kenkja Quote Os-commerce v2.3.3 Security Pro v11 Site Monitor IP Trap htaccess Protection Bad Behaviour Block Year Make Model Document Manager X Sell Star Product Modular Front Page Modular Header Tags Link to comment Share on other sites More sharing options...
Anasazy Posted March 15, 2011 Share Posted March 15, 2011 Hello this is a very usefull module. Can I ask to help me to modify this module to make permanent filtering, infact when a custemer select his make, model, year to be showno only categories with contragents exactky for his search puted in their caegories for example you want to look parts for Fiat, Tipo 1.6, 1993, Bumpers, front bumpers with YMM you choose Fiat, tipo 1.6, 1993 and form categories you choose Bumpers and sub category bumpers, but at that moment with YMM i can sort only in home category cant search in sub categories can you help me to make it little better and can we add more fields to YMM like Modification? Thanks with best regrads V.Zhechev P.S. excuse me for my English Quote Link to comment Share on other sites More sharing options...
cubifil Posted March 16, 2011 Share Posted March 16, 2011 small amelioration in file language/index.php define('TEXT_NO_PRODUCTS', '<h3> No products in this category for your ' . $Make_selected_var . ' ' . $Model_selected_var . ' ! </h3><br/>To see all the products in this category, <br/> please click <a href="'.tep_href_link(basename($_SERVER['SCRIPT_NAME']), tep_get_all_get_params(array('Make','Model','Year')).'Make=all&Model=all&Year=0', 'NONSSL', false).'"> <font color="#ff0000"><b>See all cancel and atricles</b></font></a> .'); exemple:My link Quote Link to comment Share on other sites More sharing options...
silverkorn Posted March 29, 2011 Share Posted March 29, 2011 nevermind i went ahead and installed a new fresh osc and gave it a test run. the script looks clean. possible things you may want to add are: 2. the product info pages seem to have an incorrect css coding somewhere. all links are underlined for some reason i found the error in the code that has caused the underline error, there is a missing </u> in the \Drop On Top Files\product_info.php Before: <li><u><?php echo TEXT_PRODUCTS_CAR_MODEL; ?></li> After: <li><u><?php echo TEXT_PRODUCTS_CAR_MODEL; ?></u></li> More concerning is I don't think I have the install correct as I have 2 issues which I didn't expect. 1. Unless there is at least 1 product with YMM attributes the whole index.php page looses its formatting quite dramatically. The centre section (which contains the user greeting) disappears, both left & right _column(s) change width, the "OS Commerce" logo become left justified and the YMM box has no title. Clearly the obvious answer is to keep a product with YMM attributes, but is this normal ?? This is a good find as I originally thought my installation was not performed correctly when I saw this. Once you create the first product YMM data the display errors disappears. I would think the easiest solution would be to create some default data within the SQL database when creating the new products_ymm Table, but I do not know enough about SQL to say this would work. The only thing I want to change is to add a 4th drop down to use for submodel information, ie Make: Ford, Model: Focus, Year: 2010, Submodel: 2.0L. Has anyone added this to their install? Quote Link to comment Share on other sites More sharing options...
mods4rides Posted April 3, 2011 Share Posted April 3, 2011 I'm still new to using OSC and I've attempted to install this module yet i'm stuck. In the read me file step 10 is: 10] install box from Admin >> Modules >>Boxes I'm running OSC v2.2 RC2a with only a few modifications. I followed the manual route of editing of the files. The folders inside zipfile for YMM2.3.x has drop on top files>admin>includes> and newfiles>includes>modules>boxes. Inside the boxes folder there is a file named BM_year_make_model.php. MY version of OSC doesn't have an admin/modules/boxes. I'm stuck at how to add this PHP file into my store to test the rest of the edits. Any assistance would be greatly appreciated. Thanks Quote Link to comment Share on other sites More sharing options...
Guest Posted April 3, 2011 Share Posted April 3, 2011 Alex, This version is for v2.3.1 ONLY. You will have to uninstall it and then download and install this version for RC2a: http://addons.oscommerce.com/info/6684 Chris Quote Link to comment Share on other sites More sharing options...
gt4dude Posted April 3, 2011 Share Posted April 3, 2011 Filtering is not working on product listings. Also the categories box is failing to show the number of listings in sub-cats which contain universal items. 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.