Latest News: (loading..)

wHiTeHaT

Community Team
  • Content count

    1,157
  • Joined

  • Last visited

  • Days Won

    42

wHiTeHaT last won the day on February 2

wHiTeHaT had the most liked content!

About wHiTeHaT

  • Birthday 07/08/1976

Profile Information

  • Real Name
    Henry
  • Gender
    Male
  • Location
    Netherlands
  • Skype
    the_whitehat

Recent Profile Visitors

35,478 profile views
  1. Searched worked instantly
  2. Can we have a url or send it via pm? i do not believe that this comes from oscommerce stock code. if it is, then i assume you running a AV what prevents cookie generation ... unless this is happen to any site visitor. For that i would like to see it for myself.
  3. What oscommerce version ? Stock (default) or bootstrap version? From where is been searched? -From the header (bootstrap version)? -From the searchbox? -From the advanced_search page?
  4. you can by changing your host file on your local pc. C:\Windows\System32\drivers\etc\hosts 127.0.0.1 localhost dev.example.com For mac users there exist an add on soft to even use directory's.
  5. Running osCommerce with IceCat whoohoo!!!!!!!! :cool:

    1. Show previous comments  4 more
    2. wHiTeHaT

      wHiTeHaT

      No i not use or tried. :smile:

    3. discxpress

      discxpress

      Interesting. How can I use this for my site?

      Thanks

    4. Gyakutsuki

      Gyakutsuki

      there is no add on for the moment.

  6. Both are useless, i recently checked them and they are bogus. So i did it myself and it is quite easy... in admin/categories.php directly in the top , change the set_flag case to: case 'setflag': if ( ($_GET['flag'] == '0') || ($_GET['flag'] == '1') ) { if (isset($_GET['pID'])) { tep_set_product_status($_GET['pID'], $_GET['flag']); tep_redirect(tep_href_link('categories.php', 'cPath=' . $_GET['cPath'] . '&pID=' . $_GET['pID'])); } if (isset($_GET['cID'])) { tep_set_category_status($_GET['cID'], $_GET['flag']); tep_redirect(tep_href_link('categories.php', 'cPath=' . $_GET['cPath'] . '&cID=' . $_GET['cID'])); } if (USE_CACHE == 'true') { tep_reset_cache_block('categories'); tep_reset_cache_block('also_purchased'); } } break; To show the red/green icons, change around line 928 change your code to something like: ?> <td class="dataTableContent"><?php echo '<a href="' . tep_href_link('categories.php', tep_get_path($categories['categories_id'])) . '">' . tep_image('images/icons/folder.gif', ICON_FOLDER) . '</a> <strong>' . $categories['categories_name'] . '</strong>'; ?></td> <td class="dataTableContent" align="center"> <?php if ($categories['categories_status'] == '1') { echo tep_image('images/icon_status_green.gif', IMAGE_ICON_STATUS_GREEN, 10, 10) . ' <a href="' . tep_href_link('categories.php', 'action=setflag&flag=0&cID=' . $categories['categories_id'] . '&cPath=' . $cPath) . '">' . tep_image('images/icon_status_red_light.gif', IMAGE_ICON_STATUS_RED_LIGHT, 10, 10) . '</a>'; } else { echo '<a href="' . tep_href_link('categories.php', 'action=setflag&flag=1&cID=' . $categories['categories_id'] . '&cPath=' . $cPath) . '">' . tep_image('images/icon_status_green_light.gif', IMAGE_ICON_STATUS_GREEN_LIGHT, 10, 10) . '</a> ' . tep_image('images/icon_status_red.gif', IMAGE_ICON_STATUS_RED, 10, 10); } ?> </td> <td class="dataTableContent" align="right"><?php if (isset($cInfo) && is_object($cInfo) && ($categories['categories_id'] == $cInfo->categories_id) ) { echo tep_image('images/icon_arrow_right.gif', ''); } else { echo '<a href="' . tep_href_link('categories.php', 'cPath=' . $cPath . '&cID=' . $categories['categories_id']) . '">' . tep_image('images/icon_info.gif', IMAGE_ICON_INFO) . '</a>'; } ?> </td> </tr> <?php in admin/includes/functions/general.php add: //// // Sets the status of a category function tep_set_category_status($category_id, $status) { if ($status == '1') { return tep_db_query("update categories set categories_status = '1', last_modified = now() where categories_id = '" . (int)$category_id . "'"); } elseif ($status == '0') { return tep_db_query("update categories set categories_status = '0', last_modified = now() where categories_id = '" . (int)$category_id . "'"); } else { return -1; } } Alter your categories table like: ALTER TABLE `categories` ADD `categories_status` TINYINT( 1 ) NOT NULL DEFAULT '1'; ALTER TABLE `categories` CHANGE `categories_status` `categories_status` TINYINT( 1 ) NOT NULL DEFAULT '0' ; After find all corresponding calls to categories (pages,modules,boxes, etc) where a product is shown. A sample out of my index.php and can be used as resource to all the other files where a product is shown: // show the products of a specified manufacturer if (isset($_GET['manufacturers_id']) && !empty($_GET['manufacturers_id'])) { if (isset($_GET['filter_id']) && tep_not_null($_GET['filter_id'])) { // We are asked to show only a specific category $listing_sql = "select " . $select_column_list . " p.products_id, SUBSTRING_INDEX(pd.products_description, ' ', 20) as products_description, 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 left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id, " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_MANUFACTURERS . " m, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c, categories c where p2c.categories_id = c.categories_id and c.categories_status = 1 and p.products_status = '1' and p.manufacturers_id = m.manufacturers_id and m.manufacturers_id = '" . (int)$_GET['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)$_GET['filter_id'] . "'"; } else { // We show them all $listing_sql = "select " . $select_column_list . " p.products_id, SUBSTRING_INDEX(pd.products_description, ' ', 20) as products_description, 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 left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id, " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_MANUFACTURERS . " m, products_to_categories p2c, categories c where p.products_id = p2c.products_id and p2c.categories_id = c.categories_id and c.categories_status = 1 and 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)$_GET['manufacturers_id'] . "'"; } } else { // show the products in a given categorie if (isset($_GET['filter_id']) && tep_not_null($_GET['filter_id'])) { // We are asked to show only specific catgeory $listing_sql = "select " . $select_column_list . " p.products_id, SUBSTRING_INDEX(pd.products_description, ' ', 20) as products_description, 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 left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id, " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_MANUFACTURERS . " m, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c, categories c where p2c.categories_id = c.categories_id and c.categories_status = 1 and p.products_status = '1' and p.manufacturers_id = m.manufacturers_id and m.manufacturers_id = '" . (int)$_GET['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, SUBSTRING_INDEX(pd.products_description, ' ', 20) as products_description, 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, products_to_categories p2c, categories c where p.products_id = p2c.products_id and p2c.categories_id = c.categories_id and c.categories_status = 1 and p.products_status = '1' and pd.products_id = p2c.products_id and pd.language_id = '" . (int)$languages_id . "' and p2c.categories_id = '" . (int)$current_category_id . "'"; } } That's IT.
  7. who's online....
    long time ago i seen that many users online.:blink::ohmy::wub::biggrin::heart:

    1. Harald Ponce de Leon

      Harald Ponce de Leon

      It's now showing the last 100 users, regardless if more are online. This is better for the cache.

  8. mmm, i like new concepts if they proven to work. i must be honest i not see it in this application as it not follow what we already have. What we already have is based on 3 : latitude, longitude, altitude. and they are unique. 3 words are not unique as anyone can use the same words, but no one i allow to step on my toes (as a way of speaking), as my foot is where it is.. on an exact spot what can be calculated with math. for me that 3 word idea i strip it down to 2 words: Money pit.
  9. Hi Tom, You are very diligent in try understanding coding. But i must say also that your question is related to the basics of programming, giving you the answer will not help you in future questions or learning. I would like to encourage you to learn a little more so you understand the global principe of that. the code above works perfectly as you found already out via the pagesource. Now be a little more clever, you already know how to directly show something on your screen, use the same principle for the code i provided to get something to show up. I am 100% when you figure that out, more things will getting clear for you.
  10. That part is/should already be covered in the product_info.php file if use the osCommerce bs community version. if ($product_info['manufacturers_id'] > 0) { $manufacturer_query = tep_db_query("select manufacturers_name from " . TABLE_MANUFACTURERS . " where manufacturers_id = '" . (int)$product_info['manufacturers_id'] . "'"); if (tep_db_num_rows($manufacturer_query)) { $manufacturer = tep_db_fetch_array($manufacturer_query); echo '<span itemprop="manufacturer" itemscope itemtype="http://schema.org/Organization"><meta itemprop="name" content="' . tep_output_string($manufacturer['manufacturers_name']) . '" /></span>'; } }
  11. $parts = preg_split("#/#", $product_info['products_image']); print_r($parts); echo $parts[1]; http://sandbox.onlinephpfunctions.com/code/2fcffbe8f70daa768b5cd8f722c8804c58213a1a
  12. With the new App for osCommerce Online Merchant v2.3 you can refund orders within oscommerce itself.
  13. @@Gergely, now load a product where master or slave is like like Bug's life. requires to sanitize $data before inserted to the dom quick solution: line 86: ' ' . addslashes($Qrelated->value('products_name')) . or $data = '<div id="section_relatedAppRelated_content" class="tab-pane oscom-m-top-15">' . addslashes($data) . '</div>';