| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | User manuals | Login |
Custom Sales Reports by Product (item total and by qty) | ||||
|
|
Thread Tools | Search this Thread |
#31
|
|||||||
|
|||||||
Do you have register_globals turned on in your version of PHP? It looks like the variables that are being POSTed are not working, which makes it seem as if register_globals is not allowing the PHP vars to be automatically assigned.
Can you confirm if register_globals is on (check your phpinfo() file)?
__________________
Jeremy X-Cart Gold v3.4.14 [Linux/Apache] Heavily Modded |
|||||||
#32
|
|||||||
|
|||||||
Going on a hunch that your problem is with register_globals, try adding this code to the top of your php file:
Code:
This will assign all the variables from the _POST array. Let me know if this works.
__________________
Jeremy X-Cart Gold v3.4.14 [Linux/Apache] Heavily Modded |
|||||||
#33
|
|||||||
|
|||||||
For those of you using 3.4.14 and below, I added a few snippets of code to keep the page secure, meaning you have to be logged in to the admin area to view the report. My concern was that AS IS, the file has no security measures.
To secure your report, save the file to your [xcart]/admin/ directory. Next go into your PHP file and add the following lines to the very top: Code:
I know this works for my version of xcart, others may need to just look at another file in your /admin/ directory and see what include files they are requiring at the top of each page. In order to access this, you must be logged into your admin area. Then you can copy/paste the URL, or create a special link in your admin area. Hope this helps some of you.
__________________
Jeremy X-Cart Gold v3.4.14 [Linux/Apache] Heavily Modded |
|||||||
#34
|
|||||||
|
|||||||
I know, I know, I wrote this MOD but I am having an issue with the speediness of my SQL query used for gathering product/order data across multiple tables. Here is my SQL query for sales reports between Aug 1 and Aug 3 (real small timespan):
Code:
The problem is that if I am running a sales report for a whole month or a few months, it runs SUPER slow. Any ideas on how I can optimize this query to make it run a lot faster? Thanks!
__________________
Jeremy X-Cart Gold v3.4.14 [Linux/Apache] Heavily Modded |
|||||||
#35
|
|||||||
|
|||||||
Reporting
Hi,
Just thought to let you all know, I created reporting, that sits in the Admin Area, and produces reports based on what you want. Totals taxes, shipping, you can hide or display any field, use it as a shipping list for completed orders.... It was developed for 3.5.x, but I think it should work for 3.4.x. Have not updated it or tested with version 4.x yet. Take a look, I have some sample images at http://www.x-cart-plus.com/au/xcart/customer/product.php?productid=6&cat=0&page=
__________________
All versions of X-Cart Been in eCommerce 10 years, Coding, PM, SEO, Social. X-Cart 11 years. IT 30+ years. Head of Web Dev for Australia's largest eCommerce 2 years. Attended conferences, Velocity 2009 US, CeBit 2009, MySQL 2010 US, Online Retailer 2010, Web 2.0 2011 US, MySQL 2012 US (Percona). Specialise in High Performance, High Volume, PHP, MySQL, HTML, CSS, JAVASCRIPT, SMARTY, MEMCACHED, APACHE, LIGHTTPD, FREEBSD, LINUX. Email your requests to xcart@gazwebtech.com |
|||||||
#36
|
|||||||
|
|||||||
I've had some requests for updates to this script (which hasn't been updated in quite some time). I made modifications to allow for the admin to choose what order status values the report should include. Note the new "Order Status" dropdown at the top. Here's the code, let me know if you have any questions:
Code:
__________________
Jeremy X-Cart Gold v3.4.14 [Linux/Apache] Heavily Modded |
|||||||
#37
|
|||||||
|
|||||||
The new code below adds the ability to show the Product Code (SKU #) as an option. It is disabled by default; to enable it find where $show_sku = false; and change to true.
Code:
__________________
Jeremy X-Cart Gold v3.4.14 [Linux/Apache] Heavily Modded |
|||||||
#38
|
|||||||
|
|||||||
This looks like a great mod, just a quick question
1) which folder would I put this into? I have currently put it in the admin folder, but it always redirects me to the admin home page ? Thanks
__________________
... v 4.0.18; 4.1 |
|||||||
#39
|
|||||||
|
|||||||
You need to put it in the [xcart]/admin/ directory. Make sure you put the following code at the top:
Code:
The reason it redirects you to the admin login page is because you don't have admin authentication, most likely. Let me know if that works.
__________________
Jeremy X-Cart Gold v3.4.14 [Linux/Apache] Heavily Modded |
|||||||
#40
|
|||||||
|
|||||||
wow thanks for the fast reply...
unfortunately - i'm still getting that error even when I put it in the admin folder... It just redirects me to the home page of the admin site (not the login page, but the page after I log in) any ideas?
__________________
... v 4.0.18; 4.1 |
|||||||
|
|||
X-Cart forums © 2001-2020
|