bsmither
-
Posts
18,132 -
Joined
-
Last visited
-
Days Won
607
Posts posted by bsmither
-
-
From this query, I see that there is a plugin (or hard code edits) that either makes a new query with custom order statuses, or creates an array with custom order statuses that is supplied to the existing $GLOBALS['db']->select() statement.
Please let us know what this plugin might be.
-
In admin, Store Settings, Advanced tab.
-
In the Dashboard, the Unsettled Orders tab has a red circle with a number in it. Is this more than 25? I would assume so.
Please enable CubeCart's debug mode. (Be sure to have your IP address in the next text entry field -- www.showmyip.com.)
From the 'per page' dropdown, select 100. The page will auto reload.
The browser will want to display a popup window. Let it do so. You may need to reload the page if the popup has what looks like the same content as the main window.
Scroll to the database queries section. At about query number 41, look for:
SELECT * FROM `CubeCart_order_summary` WHERE `status` IN (1,2) OR `dashboard` = 1 ORDER BY `dashboard` DESC, `order_date` ASC LIMIT 100 OFFSET 0;
Is the LIMIT 100 present?
-
Please mention the exact version of CubeCart where you see this happening.
With CC656, I do not see this.
-
An automated page request with stuff in the querystring (the part after the question mark) trying to exploit a known weakness in some (undetermined) application.
CubeCart does not let stuff like this get through. As a courtesy, this detection and removal gets logged -- just in case there was, in fact, something that was intended but was badly programmed, and needs to be fixed.
-
Just discovered there are a number of places where a customer's email address is available as a clickable mailto: link.
Order Summary, Overview tab, Contact Details section
Product Settings, Product Reviews tab
Product Statistics (reached via Product Inventory list, Product Statistics icon)
Product Reviews page
Dashboard, Pending Reviews tabClicking a mailto: link, will cause your web browser to activate the assigned email application (or online GMail or Yahoo Mail - depending) to prepare an email compose window -- on your workstation.
This means your email application (Outlook, Firebird, etc) should have an "account" under the business's name and email address.
-
A specific config.xml file is not needed.
There is no harm in keeping the skin named 'default'. It seems to me that the 'default' skin must exist in order to get at the selector to change it.
However, by adding:
$glob['admin_skin'] = "custom";
to the /includes/global.inc.php file, one can force the alternate skin to be used.
-
After a brief look-see, there can be more administrative skins. In admin, Store Settings, Layout tab, the Default admin skin can be chosen. (I have yet to find a means, if it exists, for any one admin to be assigned a specific admin skin.)
The drop-down selector is populated by a list created from code that scans the admin /skins/ folder for other folders. For a folder in admin's /skins/ to be considered an admin skin folder, that folder must have an /images/ folder, a /styles/ folder, and a /templates/ folder.
-
In:
https://forums.cubecart.com/topic/59315-syntax-error-in-classescubecartclassphp/
Looking at (your edited file's) line 2796 more closely, this happens when a non-logged-in customer wants to check on the status of an order.
When first presented with the Order Lookup form, the Order Number is taken from the web address given to the customer in their email, "/index.php?_a=vieworder&cart_order_id=xxxx".
If a visitor just happens to want to visit "/index.php?_a=vieworder" without providing the cart_order_id part, that will generate this error. How often will that happen? Can you list the steps needed to get this error on demand -- without actually munging the web address?
So, changing $_GET to $_REQUEST won't help.
Try this edit:
$cart_order_id = Order::validOrderId(trim($_GET['cart_order_id'] ?? '')) ? trim($_GET['cart_order_id'] ?? '') : '';
-
Having made the edits to synchronize lines of code to your file, line 2796 is:
$cart_order_id = Order::validOrderId(trim($_GET['cart_order_id'])) ? trim($_GET['cart_order_id']) : '';
A few lines of code just above it, the statements are using $_REQUEST. So, maybe try this edit:
$cart_order_id = Order::validOrderId(trim($_REQUEST['cart_order_id'])) ? trim($_REQUEST['cart_order_id']) : '';
We had discussed line 2197 earlier.
-
So, you added the debugMessage statement at line 279? Then two lines of code later it's gone? That inconceivable! Unless your "cPanel Error Log" is collecting errors from an installation of CubeCart that is other than what you are editing.
The first two pair of errors have been reported (see issue #3572).
The Product Appearances was discussed via PM.
As for the last error, line 2796 of cubecart.class.php must be different than stock in your set of files.
-
So, if $catData at line 273 has an array element 'cat_parse', but the $catData at line 281 does not, the only thing between them is a hook.
As an experiment, at line 279 (should be a blank line), add the debugMessage statement that was added to line 273.
If 'cat_parse' does not show up in the second showing in CubeCart's Debug Console, Debug Messages section, then we know that the hook is causing interference.
-
Please enable CubeCart's debug mode, if not already.
In the file /classes/catalogue.class.php, near line 273:
Find: $catData = $this->_categoryData; Change to: $catData = $this->_categoryData; $GLOBALS['debug']->debugMessage('<pre>'.print_r($catData,true).'</pre>');
View a category page.
CubeCart's Debug Console will popup(*). Scroll to the bottom to see the Debug Messages section.
Verify that [cat_parse] is an element of the array.
* If not having given permission before, the browser may complain about a page wanting to display a popup window. Let it do so. You may need to close the popup window and reload the category page.
-
In /classes/catalogue.class.php, near line 757, find:
if (($result = $GLOBALS['db']->select('CubeCart_category', false, array('cat_id' => $category_id, 'status' => 1))) !== false) {
Please determine if this statement is exactly as is shown above.
-
I think that would not be necessary.
But now we need to find out why that column and its value is not becoming available at line 281.
In /classes/catalogue.class.php, near line 757, find:
if (($result = $GLOBALS['db']->select('CubeCart_category', false, array('cat_id' => $category_id, 'status' => 1))) !== false) {
Please determine if this statement is exactly as is shown above.
-
Please use an external database utility to examine the database table CubeCart_category. The latest versions of CubeCart will have put a new column in this table named 'cat_parse'. (TINYINT, unsigned, default 0)
-
Can't change the code change above. Use this instead:
foreach (self::$_paths as $path) { $GLOBALS['debug']->debugMessage('Looking in this $path: '.(empty($path)?"Empty":$path));
-
You might also want to make this edit in /classes/autoloader.class.php, near line 92:
Find: foreach (self::$_paths as $path) { Change to: foreach (self::$_paths as $path) { $GLOBALS['debug']->debugMessage('Looking in this $path: '.empty($path)?"Empty":$path);
Then, when viewing CubeCart's Debug Console, at the bottom will be the collection of Debug Messages.
-
If the second reason posited as described above is the cause, then there seems to be an empty element in the include_path setting for PHP, or somehow an empty element is getting added.
You can try to make the edits in the following Github issue:
https://github.com/cubecart/v6/issues/3634
-
"there is some info about paths in the error message."
Please let us know the entirety of those paths.
Since this INSERT query, with the details of the error, was seen in CubeCart's Debug console, those details should also appear in admin, Error Log, System Error Log tab, as described earlier.
-
Make sure the admin folder has the same name as is specified in /includes/global.inc.php.
-
"Did the request password thing and yes that returns the red validation error banner."
So, you did get the email with the validation link? But when going to that link, the validation failed (red banner)?
The javascript may be crashing? The browser has "Developer Tools", with a "Console" screen. It will report any problems with the javascript.
Or maybe the browser has an extension that autofills (out of sight, after clicking Submit) sign-in forms - a 'password manager'. The Develop[er Tools has a "Network" screen that will show the data submitted by forms.
-
In what way does the reset link not work? Does the page refresh? If so, does the new page have a (narrow) banner that suggests one should check their email in a few minutes? Or, having clicked Submit, absolutely nothing happens?
Does your store use PHP's mail() feature, of have you entered settings for a SMTP Server?
Try these values for a test admin:
status = 1 name = Test Admin username = testadmin password = cf3c11a5a59f28a81eb3cfd3cc0b2114c6c7533b7626925e88bd7588eb15c86e2fca66e29820e8c8f2cce104a1b69ac0d2bdaab8f77ebcaff20af68a6c217e89 salt = 46056257 new_password = 1 email = (something [at] somewhere.com) super_user = 1
username: testadmin
password: testadmin -
I corrected the filename in my post above.
In CubeCart's admin, Documents, click the Edit icon for the row that has the Homepage column checked.
On the next page, click the Content tab. Click the editor's Source button.
Viewing the source code of the document, find:
<p><img alt="" src="/gts/images/source/cart-image.webp" style="width:1000px;height:300px;"></p> Change to: <p><img alt="" src="/gts/images/source/cart-image.webp"></p>
Save and have CubeCart clear its internal cache.
More than 25 listings in dashboard unsettled order
in Technical Help
Posted
The Custom Order Status plugin uses the admin.dashboard.unsettled_orders hook. (It's encoded, so I cannot determine what this hook code actually does. But the query shown suggests the hook code created that query.)
In the list of queries shown in CubeCart's debug window, was there a similar query just a few queries above the one you found? A query that has WHERE `status` IN (1,2) ?
Please contact Noodleman to determine if there is anything that would need to be done about the Github issue #3231 (implemented 19 Apr 2023 on CC652), versus the latest version of the plugin (v1.0.6 on 8 Feb 2018).