Jump to content

katapofatico

Members
  • Content count

    63
  • Joined

  • Last visited

  • Days Won

    3

katapofatico last won the day on February 9 2017

katapofatico had the most liked content!

3 Followers

Profile Information

  • Real Name
    Marcos
  • Gender
    Male
  • Location
    Madrid

Recent Profile Visitors

5,870 profile views
  1. katapofatico

    Store Mode BS

    PHP Warning: file_put_contents(../maintenance.php): failed to open stream: Forbidden access in ...includes/modules/header_tags_amantis/ht_store_mode.php on line 166 Ok, I know it's a permissions problem. But I've never known what level of permissions to grant on this situations :( What's the minimum (most conservative and secure) chmod numbers to allow writting .htaccess from ht_store_mode.php? Can you guide me please? Thanks!
  2. katapofatico

    Store Mode BS

    @@raiwa Installing the content module, on URL ...admin/modules.php?set=header_tags&module=ht_store_mode Notice: Use of undefined constant MODULE_HEADER_TAGS_STORE_MODE_MESSAGE_ - assumed 'MODULE_HEADER_TAGS_STORE_MODE_MESSAGE_' in .../includes/modules/header_tags/ht_store_mode.php on line 201 $KeysArray[] = MODULE_HEADER_TAGS_STORE_MODE_MESSAGE_ . $key; Fixed: $KeysArray[] = 'MODULE_HEADER_TAGS_STORE_MODE_MESSAGE_' . $key;
  3. katapofatico

    Spam addon

    Excuse me, it looks a simple developer confusion. The addon is correct, only the last file is a mistake.
  4. katapofatico

    Spam addon

    There's a fake addon: http://addons.oscommerce.com/info/9501 Is there any control about it?
  5. katapofatico

    [Addon} Theme Switcher

    The addon description says: Instructions are included for using the ThemeRoller tool to download stock themes and design new ones. It includes a method that allows you to design WYSIWYG on your own store pages @@kymation Please, where can we see these features?
  6. katapofatico

    [Addon} Theme Switcher

    There's a new file on addons site, uploaded by @@beauty_Bar, versioned as theme_switcher_1.5.3_1 but it hasn't any differences to previous version theme_switcher_1.5.3 by @@kymation. Maybe an error?
  7. katapofatico

    [Addon] Modular Product Page (Bootstrap)

    Yeah! That is the key Excuse me, but are you reffering to a new version not yet published, aren't you? Because version 1.1 (http://addons.oscommerce.com/info/9453) from 5/April/2016 calls to tep_get_products_special_price(). Yes, I always implement OOP and general best practices: I wonder when somebody ask for reasons, advantages, justifications, etc. about it. I think best prastices have a lot of benefits to performance, reusability, manteinability, etc.: Predictable and not predictable benefits. My criteria is: First I implement them, later I suspect about them: not the reverse: First suspect, later implement them. Best practices and design patterns are more inteligent that me, because they are historically condensed programming experiences. I like that you like it ;)
  8. katapofatico

    [Addon] Modular Product Page (Bootstrap)

    Ok, the core PHP code is avoiding duplicated product_id on specials table, but no specials table himself: in this situations I use LIMIT 1 or I define the DBB field as UNIQUE. I want to avoid full scanning of tables... I don't know specifically if this problem occurs with this query :) I don't see caching improvements on http://addons.oscommerce.com/info/9453 : public function special_price() { return tep_get_products_special_price($this->product_info['products_id']); } ...therefore on cm_pi_price.php we will query 3 times on a product with special price: if ($product_info->has_special_price() === true) { // THIS CALL TO products_price() // HERE 2 CALLS MORE: $products_price = '<del>' . $currencies->display_price( $product_info->products_price(), tep_get_tax_rate( $product_info->products_tax_class_id() )) . '</del> <span class="productSpecialPrice" itemprop="price" content="' . preg_replace('/[^0-9.]*/', '', $currencies->display_price($new_price, tep_get_tax_rate($product_info->products_tax_class_id() ))) . '">' . $currencies->display_price($new_price, tep_get_tax_rate($product_info->products_tax_class_id() )) . '</span>'; } else { [...]
  9. katapofatico

    [Addon] Modular Product Page (Bootstrap)

    @@kymation @@burt I'm worried because if we implement this module we will break away from core improvements on product_info.php. @@burt What do you think about integrating this module on master branch?
  10. katapofatico

    [Addon] Modular Product Page (Bootstrap)

    @@kymation ok, then: a ) use your inner query b ) and cache the result (avoiding unnecessary queries) in instance attribute $new_price c ) I have added LIMIT 1 because products_id is not PRIMARY_KEY nor UNIQUE, only INDEX. What do you think about this? public function special_price() { if ($this->new_price === null) { $special_price_query_raw = " select specials_new_products_price from " . TABLE_SPECIALS . " where products_id = '" . $this->products_id . "' and status = 1 LIMIT 1"; $special_price_query = tep_db_query($special_price_query_raw ); $special_price_array = tep_db_fetch_array( $special_price_query ); $this->new_price = $special_price_array['specials_new_products_price']; } return $this->new_price; }
  11. katapofatico

    [Addon] Modular Product Page (Bootstrap)

    Hello, While I'm developing I active this: error_reporting(E_ALL); ...and the product_info.php of a product with special price throws: Notice: Undefined variable: new_price in [...]includes/modules/content/product_info/cm_pi_price.php on line 41 The line is: $products_price = '<del>' . $currencies->display_price( $product_info->products_price(), tep_get_tax_rate( $product_info->products_tax_class_id() )) . '</del> <span class="productSpecialPrice" itemprop="price" content="' . preg_replace('/[^0-9.]*/', '', $currencies->display_price($new_price, tep_get_tax_rate($product_info->products_tax_class_id() ))) . '">' . $currencies->display_price($new_price, tep_get_tax_rate($product_info->products_tax_class_id() )) . '</span>'; Replacing $new_price with $product_info->special_price() solves it. For performance, I suggest this change on product_info class, using the unused class public variable $new_price: public function special_price() { if ($this->new_price === null) { $this->new_price = tep_get_products_special_price($this->product_info['products_id']); } return $this->new_price; } Thanks a lot for your usefull module!
  12. katapofatico

    [Addon] Modular Navigation Bar (Bootstrap)

    On includes/modules/content/navbar/templates/cm_nb_cart.php line 23 there is a typing error: <li><a href="' . tep_href_link(FILENAME_SHOPPING_CART) . '">' . HEADER_CART_VIEW_CART . '</a></li> solution: <li><a href="'<?php echo tep_href_link(FILENAME_SHOPPING_CART) . '">' . HEADER_CART_VIEW_CART ?></a></li>
  13. katapofatico

    How to create payment module

    Payment module development how-to: http://forums.oscommerce.com/topic/187772-payment-module-development-how-to/
  14. katapofatico

    How to create payment module

    I'm also looking for guidelines coding a new payment method: do you know where can I find it?
×