Jump to content

bsmither

Member
  • Posts

    18,013
  • Joined

  • Last visited

  • Days Won

    605

Posts posted by bsmither

  1. These are all Warnings (was Notices in PHP 7) that would not prevent a page from being delivered.

    You were able to log in as an admin?

    One of the errors in the file (regarding array_keys in dashboard.index.inc.php at line 311) suggests that you are not running CubeCart 6.4.7 -- at least the files in the folder admin_n6kWr4 are not the latest version.

    How folders on your site start with admin?

     

  2. Currently, no.

    But, CubeCart has the ability to respect a custom API call that a "cron job" would execute on schedule, as well as hooks that could be used every time that a web page is requested to update if a specified amount of time has elapsed since the last update.

     

    • Thanks 1
  3. Installing this shipping module will allow you to have whatever USPS gives, plus whatever the Free Shipping module gives (sets free shipping for over a set amount).

    https://www.cubecart.com/extensions/shipping-methods/free-shipping

     

     

  4. That's going to be very tricky. The order of the shipping module  might be able to be brute-forced into a custom order (why are there two Liefer- und Zustelloptionen?), and AIOS allows for a custom order of the Zones.

    However, CubeCart then sorts each module's package of rates by price.

    Then also allows the 'default' to be one of three conditions: Cheapest, Cheapest>0, Costliest.

    So, no built-in way to specifically target a rate from amongst all the module's rate packages.

    Fortunately, there are hooks that could be used to re-scan all the packages, looking for the one 'master default' targeted rate -- provided that somehow the module's admin settings screens be modified to have a radio button to indicate this 'master default'.

    Why are there two Liefer- und Zustelloptionen?

  5. I have written two plugins that may get you this: adds a tab to a product's Edit screen in admin that shows all orders that has included this item, also an "export" button that allows the admin to download a Sales Report (CSV) of orders that filters for a specified item.

    If interested, send me a Private Message with your email address, and I will send them to you.

  6. By looking at the list of SQL queries in the debug section, it can be determined which method CubeCart finally used: whether there are one, two, or three search queries.

    The first will be a query, if present, will have the word RELEVANCE in it, the second, if present, will have the word RLIKE in it, and the third, if present, will have the word LIKE in it.

    (There will also be several queries that have LIKE in them but searching against the CubeCart_manufacturers table. Ignore these.)

    There is a preliminary test that asks the database what is the minimum number of letters that the shortest search term must have. It will be this query:

    SHOW VARIABLES LIKE 'ft_min_word_len'

    The answer is usually 4. So, because at least one of the search terms is less than 4 characters, the RELEVANCE query won't be executed and you won't see it in the list of queries. Instead, CubeCart will skip that and go to RLIKE.

    Since TAR is a whole word, the search using RLIKE succeeds.

    Then, you remove the whole word TAR from the description, and now CubeCart uses LIKE which will find 'tar' as part of any word.

    I cannot explain why the results include obvious non-matches.

    However, the LIKE query is permitted to use the query cache. So, if there was a recent instance where the data for product_id 7817 (aka TR21-W) did include a word containing 'tar', then maybe we see this because of a cached recordset from an earlier search on 'tar'.

    We would have to explore your database directly.

     

  7. If you are referring to modifying Foundation, then, as an example, you can see Dirty Butter's site (highly customized but still based on Foundation) on the WayBack Machine:

    https://web.archive.org/web/20190722090647/https://dirtybutter.com/plushcatalog/

    I think she used SemperFi's "Vertical Navigation Box". (No longer available, commercially.)

    Or are you asking about doing this on your existing site?

  8. CubeCart has three methods to ask the database on how to formulate a query:

    1. Fulltext Relevance - if nothing found, then
    2. REGEX on word boundaries - if nothing found, then
    3. REGEX anywhere - if nothing found, then say "No products found."

    Fulltext Relevance is a somewhat complicated method to explain. Basically, if too few results are returned, the term(s) must not be all that important. If too many results, then the term(s) must not be all that unique. There are nuances.

    Word boundaries will find whole words. 'TAR' will find "TAR 735" but not "TAR735".

    Anywhere will find the sequence of characters in "TAR", "TAR367", "STAR-BRIGHT", etc.

    By looking at the list of SQL queries in the debug section, it can be determined which method CubeCart finally used: whether there are one, two, or three search queries.

    Several store owners have edited the searchCatalogue() function definition so that the default method is $search_mode = 'rlike', skipping the 'fulltext' method.

  9. Literally, the change involves replacing a digit (1) with the name of a variable ($page). This edit cannot have caused a white screen.

     

    Depending on the text editor used, the editor may be doubling the line endings, making the file double spaced.

    Thus, line 1941 becomes 3882.

    Do you recall seeing double spacing in the editor you used?

     

  10. FYI: I now completely understand the nature of this scenario. I was able to reproduce it and have traced the code where the mistake is being made.

    I am working on a solution: so that this doesn't happen in the future, and to create a 'fix-it' code snippet to solve all existing shopping baskets that suffer this situation.

     

     

  11. Please try this edit. In /classes/catalogue.class.php:

    The line numbers may be slightly different...
    
    Lines 1941-1943, find:
    
                        } elseif ($search_mode == 'fulltext') {
                            return $this->searchCatalogue($original_search_data, 1, $per_page, 'rlike');
                        }
    
    Change to:
    
                        } elseif ($search_mode == 'fulltext') {
                            return $this->searchCatalogue($original_search_data, $page, $per_page, 'rlike');
                        }
    
    Lines 1998-2000, find:
    
                        } elseif ($search_mode=="rlike") {
                            return $this->searchCatalogue($original_search_data, 1, $per_page, 'like');
                        }
    
    Change to:
    
                        } elseif ($search_mode=="rlike") {
                            return $this->searchCatalogue($original_search_data, $page, $per_page, 'like');
                        }
    

     

  12. Searching BPM.

    I see that the web address indicates that page=2 has been requested, but yes, the twelve results are the same as shown on page 1.

    Clearing CubeCart's internal cache had no effect.

    Asking for a sorted list (Price Low-High) got the twelve lowest priced products. Page=2 got the same products.

    I had a suspicion that the database is resisting in some fashion having to search on a three or less letter search term. The term UNF seems to work, but GRN has only one row returned in the resultset. GRN1 has 12 in the predicted search popover but shows only the two products where "GRN1" is the actual product code.

    So, I cannot see that there is a fault in the building of the query - specifically calculating the solution to 'per-page' multiplied by 'page-1'. (That is, for page=2: 12x1=starting at the 12th row in the resultset for 12 rows.)

    There must be a fault in the construction of the wildcards used in the REGEX query sent to the database.

    Examining the queries that CubeCart sends to the database would be helpful. In admin, Store Settings, Advanced tab, enable Debug Mode. Enter your local IP address in the following text field (www.showmyip.com). Save.

    Search for BPM.  Go to page=2. At the bottom of the screen will be some diagnostic info. Specifically, all the queries sent to the database. Copy and Paste that list of queries into a Private Message to me.

  13. In the PayPal Commerce plugin, there is a hook file named 'controller.index.php'. This hook code creates and registers a Smarty output filter. (An output filter can add, edit, and delete content from rendered sources, usually skin templates.)

    I assume this output filter is required for displaying PayPal stuff on the PayPal skin template when checking out, but the Smarty output filter also seems to be applied to any and all rendered templates universally, including email templates (the HTML component only).

    Then, the MailScanner utility catches the email, sees the <script> tag, and disarms it. The result is visible text.

    CubeCart's email templates do not have the target of the javascript generated by this hook, so it's not necessary. But, as an output filter that is instantiated at 'controller.index', the action this hook provides will get applied to unintended content.

    Resolving this will require the CubeCart programmers to come up with a solution: possibly testing for what will be using the output filter, or using different hooks.

    As for MailScanner, according to the documentation posted above, it is unfortunate that there is no choice to 'remove' script tags and the inner content.

  14. When you "click to the next page", do you actually get a new page, with the CubeCart header, sidebars, footer, but an empty main content area? Or is it a just a completely blank white screen? Or when you say "nothing happens" and "does nothing", are you saying that when clicking on the link, there was no effort by the browser to issue a request for a new page?

    Please remind us of the web address for the site.

     

  15. Please edit the Mobile skin template content.orders.php:

    Near line 34, find:
    
    <div><label for="lookup_order_id">{$LANG.basket.order_number}</label><span><input type="text" id="lookup_order_id" name="cart_order_id" value="" /></span></div>
    
    Change to:
    
    <div><label for="lookup_order_id">{$LANG.basket.order_number}</label><span><input type="text" id="lookup_order_id" name="cart_order_id" value="{$ORDER_NUMBER}" /></span></div>

     

  16. You said (post #3): "It's always passed when I try to recreate the issue."

    Also, "If I add an item to the basket that doesn't yet contain a matrix entry, then go back and create a matrix entry, this matrix entry is never populated in the basket."

    So, there exists the frequent scenario whereby a product has been made available for purchase, but has yet to have its Options Matrix table data fully populated (missing product codes). And that product has been put in shopping baskets, but the order has not yet been transacted.

    Having looked at the sequence of events during checkout, I recall where all the products are 'verified'. I'll see if, during this verification of the contents, the product code is included.

  17. This is found in an email received by the customer?

    It looks like javascript that would be found in the PayPal plugin module.

    If possible, look at the plain text component of the received email. (Granted, that might be a feature of the email program you use that simply isn't available.)

    If not, you should be able to look at the email's raw source.

    Does the rogue content also appear in the plain text component?

     

  18. Regarding #2, I would think that the content.category.php template has been edited such that the list of sub-cats do not collapse into a toggled slide-open from the category title.

    Regardless, in the template file content.category.php, find:

    {if isset($SUBCATS) && $SUBCATS}
    	<div class="collapse" id="collapseSubCats">

    Just ABOVE that, add:

    {if isset($SUBCATS) && $SUBCATS}
      <div class="panel panel-basix">
        <div class="panel-body">
          <div class="row">
            {foreach from=$SUBCATS item=subcat}
              <div class="product-box">
                <div class="inner">
                <div class="product-wrap">
                  <div class="photo-wrap">
                    <a class="th" href="{$subcat.url}" title="{$subcat.cat_name}">
                      <img class="thmb" src="{$subcat.cat_image}" alt="{$subcat.cat_name}">
                    </a>
                  </div>
                  <div class="product-name"><a href="{$subcat.url}" title="{$subcat.cat_name}">{$subcat.cat_name}</a></div>
                </div>
                </div>
              </div>
            {/foreach}
          </div>
        </div>
      </div>
    {/if}

    Then, near the bottom, find:

      {else}
    
        <div class="alert alert-danger text-center">{$LANG.category.no_products}</div>

    Just below that:

    Delete:
    
        {if isset($SUBCATS) && $SUBCATS}
          <div class="clear">
            <div class="list-group">
              {foreach from=$SUBCATS item=subcat}
                <a href="{$subcat.url}" class="list-group-item" title="{$subcat.cat_name}">{$subcat.cat_name}</a>
              {/foreach}
            </div>
          </div>
        {/if}
    

    The panels are wide enough to get four panels per row. (Same as the array of panels on the Homepage.) The image, however, may be too small.

    If not happy with the size of the sub-cat images, then in the skin's config.xml file:

    Find:
    <image reference="subcategory" maximum="105" quality="80" default="noimage.png" />
    
    Change to:
    <image reference="subcategory" maximum="150" quality="80" default="noimage.png" />

    Then have CubeCart clear its internal cache.

×
×
  • Create New...