Jump to content

bsmither

Member
  • Posts

    17,980
  • Joined

  • Last visited

  • Days Won

    603

Posts posted by bsmither

  1. When CubeCart determines that the security key is invalid, one of the things done is to destroy the $_GET and $_POST variables. That way, nothing untoward gets processed.

    The missing array key 'HTTP_USER_AGENT' has been dealt with elsewhere in the CubeCart code to not throw a warning - so maybe an issue in the Github regarding this specific statement in the code may show up. In the meantime, you may wish to make this edit:

    In /classes/user.class.php, near line 719, from:
    
    $agent = strtolower($_SERVER['HTTP_USER_AGENT']);
    
    To:
    
    $agent = strtolower($_SERVER['HTTP_USER_AGENT'] ?? "unknown");

    I think this group of errors involve a search spider submitting an obsolete or incomplete page request.

    The array offset warning identifies a statement that has not been fixed correctly. Please make this edit:

    In /classes/cubecart.class.php, near line 660, from:
    
    if ($_GET['_a'] == 'basket' && $this->_basket['billing_address']['user_defined'] ?? false) {
    
    To:
    
    if ($_GET['_a'] == 'basket' && isset($this->_basket['billing_address']) && $this->_basket['billing_address']['user_defined'] ?? false) {

     

  2. When CubeCart starts up, eventually the HookLoader class is instantiated. During this class's construction, a call is made to build a "hooks list". The source of data for this list is the database table CubeCart_hooks. The table CubeCart_hooks is populated with references to a plugin's hooks when that plugin is installed and enabled.

    For every record in the table CubeCart_hooks, the plugin's filename is used in a path, such as "CC_ROOT_DIR/modules/plugins/plugin_filename", and then that path is added to PHP's 'include_path', as well as CubeCart's internal list of paths. (You can examine the current 'include_path' in admin, PHP Info, in the Core table. The 'include_path' is a list of all file paths that PHP will look into for a given file.)

    Up to this point, to get the AutoLoader to locate and register a class, that class must be in the /classes/ folder (as the default location), and the main folder of enabled plugins. (Other modules, such as Shipping and Gateway, are understood to have a required class in their main folder, and it will get registered as needed.)

    There are plugins that have their own classes in their /classes/ folder. To get these classes registered, the plugin uses a hook that is available near the end of CubeCart's wake-up sequence, 'controller.index', just before CubeCart starts fetching data to populate and display the intended page. (There are earlier hooks available, however.)

    The AutoLoader class has a static function appendPaths($path) that can be used to add to CubeCart's list of paths to look in for a requested class. CubeCart's list of paths may have more entries than PHP's 'include_path' value.

     

  3. Hm. We can see that right away CubeCart is told to use fr-FR, but the phrases are not coming from that language pack. (See Debug Messages[0])

    Please examine the following and try the suggested action:

    In admin, Languages, take note of any actual entries in the Domain column (not the slightly greyed-out suggested examples).

    If there are actual entries, blank them out and Save.

    Have CubeCart clear its internal cache.

    Did anything change?

    • Thanks 1
  4. Try this. Place the four lines of jacascript (do not include the <script> tags) in the skin's file 2.cubecart.js (if your skin has that file).

    Find near lines 2-3:
    
    var validation_ini = {};
    jQuery(document).ready(function() {
    
    Add after:
    
        $('.vnb-sub-cbd').hide();
        $('.has-sub-cbd').hover(function(){
            $(this).children('.vnb-sub-cbd').fadeToggle(200);
        });

     

  5. Just to clarify: the group of statements that starts with <li class="has-sub-cbd"> is located in the skin template file element.navigation_tree.php.

    If so, then the code at /classes/catalogue.class.php, public function getCategoryTree() might be malfunctioning. Near line 898 is where $children is evaluated. Specifically, this statement:

    if ($GLOBALS['config']->get('config', 'catalogue_expand_tree') && $children = $this->getCategoryTree($category['cat_id'], $level)) {

    suggests that there is a setting in admin, Store Settings, Layout tab, "Expand category navigation tree", and that there are subcategories for the given category, for there to be children coded in the HTML.

  6. Using a programmer's text editor, make the following change to the file /classes/language.class.php:

    Near lines 234-237, find:
    
        public function assignLang()
        {
            $GLOBALS['smarty']->assign('LANG', $this->_language_strings);
        }
    
    
    Change to:
    
        public function assignLang()
        {
            $GLOBALS['smarty']->assign('LANG', $this->_language_strings);
            $GLOBALS['debug']->debugMessage('Assigning language strings to Smarty LANG. Example ('.$this->_language.'): '.$this->_language_strings['account']['already_registered'].'<br><pre>'.print_r(debug_backtrace(0),true).'</pre>');
        }

    Be sure to have CubeCart's debug mode enabled.

    View the Homepage.

    Near the bottom of the debug window, there will be a section showing Debug Messages:.

    Copy that section to a reply. (You can reply in a PM if you wish.)

  7. If we are working with CC651, then I suspect that the database was not properly updated. At some version a while ago, the programmers decided that all active values in CubeCart_seo_urls, 'path' column, would not have the .html suffix. That database update from not too many versions ago should have pruned all .html suffixes from this database table. (That update also added a few specific entries that do have the .html suffix but also has a 301 in the 'redirect' column. This part of the update is not critically important.)

    You say the legitimate URL for your store is:

    http://www.champcoclothing.com.au

    that is without including the /champco_champcoclothing/ sub-directory. Then you need to edit the .htaccess file and remove that reference from the various directives:

    Change to:
    
    RewriteBase /
    
    Change to:
    
    RewriteCond %{REQUEST_URI} !=/favicon.ico
    
    Change to:
    
    ErrorDocument 404 /index.php

    Note: the seo paths the update added to Cubecart_seo_urls are:

    contact-us.html
    gift-certificates.html
    login.html
    recover.html
    register.html
    search.html

    for the case where a non-current skin had these links hard-coded in the template.

  8. In admin, Store Settings, Search Engines tab, what is the "SEO URL Extension" set at?

    Examine the contents of the database table CubeCart_seo_urls. Does any entry in the 'path' column end in .html? (There should be only a few, and those few that do should also have '301' in the 'redirect' column.

     

  9. On the live server, are you, in fact, actually running CubeCart in the sub-directory /champco_champcoclothing/, and that the real web address is something like:

    http://www.mainsite.com/champco_champcoclothing/index.php

    I would have to assume so.

    As for the 404 Error, do you get a CubeCart page where it has the typical CubeCart stuff and that the main content area says "404 Error: Sorry but the page you are looking for could not be found.", or do you get very basic page (no CubeCart skin styling at all) simply saying 404 Not Found?

  10. So, the 'language' key says you (admin #2) want to use de-DE, but the admin is actually showing fr-FR?

    In admin, PHP Info, scroll to the Core table, and find include_path.

    If /usr/share/pear/ appears in the Local Value or Master Value, the hosting provider support will need to help you resolve the 'open_basedir' conflict.

    However, I think is not the cause of this issue.

     

  11. "emails are in french" ==> Good.

    "admin is in french" ==> Ok, good.

    In admin, Store Settings, Advanced tab, enable the Debug mode. Enter your local IP address (www.showmyip.com) in the next text entry field.

    Debug mode will have CubeCart create code that the browser will want to show in a popup-window. Allow the popup. (You may need to close that popup and reload the page to get the correct data to show.)

    The debug data will show any errors that PHP encountered, and will show some data from SESSION:. In the '__client' sub-array, what is the value for the 'language' key when viewing the storefront.

    (If using the Firefox browser, you may need to close the popup window before requesting the next page.)

  12. "the database table" ==> Good, seems to be no problem here.

    "the language file" ==> I have version 1.0.0 - will need to check version 2.0.0.

    "other files" ==> Good. I expect to see the email file. But no sub-file for that language.

    When CubeCart sends an email, does the content of that email appear in either de-DE or fr-FR, or do they, as well, appear in English?

    Does the admin section appear in English as well?

  13. So, this is from the skin "savonnerieNeptune" - which is based on Basix, and has had no customizations made to it.

    Then, we need to find why the Smarty variable $LANG has arrays that are not correct.

    Please use an external database utility to directly view the table CubeCart_lang_strings. (Your hosted account's control panel should have phpMyAdmin to do this.) How many rows of data are there, and if there are any, do the phrases in the 'value' column not match the language code in the 'language' column?

    Please examine the file in /language/ folder named 'de-DE.xml'. Please post the first 40 lines into a code window.

    Is there any other file in the /language/ folder that has de-DE in the filename?

     

  14. CubeCart should load the language strings from definitions.xml (which are UK-based), then overload that array with strings found in the chosen language pack. (Note that the "en-US.xml" file has only five strings for common US terms.)

    The language packs are not kept up to par as new strings are added to definitions.xml (for new features). But more than 99% of the language strings are common all the way back to CC5 - so, very nearly all of present-version CubeCart should show the correct language strings.

    One would need to do a deep dive into the CubeCart code to see if/where the problem lies.

    I see that your skin (savonnerieNeptune) is derived from Basix. Please post the contents of the skin's template "box.search.php" (use a code window - the <> tool on this editor will show a code editing box).

     

  15. Normal emails?

    If the admin, Store Settings, Advanced tab, Email section, "Sending Method" is set to PHP mail() function, but the server, where CubeCart is installed, does not have an email program installed (SendMail, QMail, etc), then PHP may not have the means to properly inform the script that sends the commands to that email program that the mail() command was executed, but nothing was available to respond to that command.

    Thus, CubeCart assumes all went well.

    But if the "Sending Method" is SMTP, and you have the proper credentials to use that external SMTP server, then failures would be reported properly.

     

×
×
  • Create New...