Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls

X-Cart reBOOT (reDUX) Template

 
Reply
   X-Cart forums > X-Cart 4 > Third Party Add-Ons for X-Cart 4
 
Thread Tools
  #561  
Old 09-11-2024, 07:15 PM
 
www.cheapglasses.net www.cheapglasses.net is offline
 

Advanced Member
  
Join Date: Dec 2015
Posts: 79
 

Default Re: X-Cart reBOOT (reDUX) Template

Breadcrumb fluid, right not full.
Attached Images
File Type: jpg Screenshot-2024-09-12-111102.jpg (14.5 KB, 5 views)
Reply With Quote
  #562  
Old 09-24-2024, 01:01 AM
  nauticalstyle's Avatar 
nauticalstyle nauticalstyle is offline
 

Advanced Member
  
Join Date: Jun 2012
Posts: 59
 

Default Re: X-Cart reBOOT (reDUX) Template

Unfortunately I haven't kept up with all the updates that Phil has put out over the last few years, but I'm back on the PC now, determined to get the ReBOOT(ReDUX) template fully updated and running like a Swiss watch, but as is usual for me, I've come across a stumbling block...

While trying to implement the v4.7.12.5 Security & Testimonials update from June 10 2021, the database patch is throwing up a SQL syntax error in the first few lines of code.

I'm running XAMPP v3.3.0, with Apache and MySQL, and MariaDB v10.4.18, on a Windows 10 PC.

Here's the relevant section of code from the patch.sql file that produces the error code 1064:

DROP TABLE IF EXISTS reboot_visitors;
CREATE TABLE IF NOT EXISTS reboot_visitors (
id int(11) NOT NULL AUTO_INCREMENT,
time int(20) NOT NULL,
ip varchar(50) NOT NULL,
city varchar(255) NOT NULL,
region varchar(255) NOT NULL,
country varchar(255) NOT NULL,
org varchar(255) NOT NULL,
host varchar(255) NOT NULL,
referer varchar(255) NOT NULL,
useragent varchar(255) NOT NULL,
device varchar(1) NOT NULL,
blocked varchar(1) NOT NULL DEFAULT 'N',
PRIMARY KEY (id)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

#REPLACE INTO `reboot_visitors` (`id`, `time`, `ip`, `city`, `region`, `country`, `org`, `host`, `referer`, `useragent`, `device`, `blocked`) VALUES
(1, 1622817139, '**.**.**.**', 'City', 'Region', 'US', 'Example Org', 'Example Host Name', 'https://example.com', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:89.0) Gecko/20100101 Firefox/89.0', 'D', 'Y');


The SQL error log file says:

SQL query : (1, 1622817139, '**.**.**.**', 'City', 'Region', 'US', 'Example Org', 'Example Host Name', 'https://example.com', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:89.0) Gecko/20100101 Firefox/89.0', 'D', 'Y')
Error code : 1064
Description : You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '1, 1622817139, '**.**.**.**', 'City', 'Region', 'US', 'Example Org', 'Example...' at line 1
__________________
Tony
Skipper at Nautical Style
X-Cart Gold Version 4.7.12
X-Cart reBOOT (reDUX) Template 4.7.12.5 (in development)
Reply With Quote
  #563  
Old 09-25-2024, 03:34 AM
  pauldodman's Avatar 
pauldodman pauldodman is offline
 

X-Guru
  
Join Date: Jul 2003
Location: Spain / UK
Posts: 3,060
 

Default Re: X-Cart reBOOT (reDUX) Template

The code seems to be commented out - you have


#REPLACE INTO


remove the #


REPLACE INTO
__________________
Paul Dodman
e-business & m-commerce consultant
w: www.luminointernet.com
e: xcart@luminointernet.com

Professional X-Cart help, advice, support and services, specialists in Mobile X-Cart.
Reply With Quote
  #564  
Old 09-25-2024, 07:39 AM
  nauticalstyle's Avatar 
nauticalstyle nauticalstyle is offline
 

Advanced Member
  
Join Date: Jun 2012
Posts: 59
 

Default Re: X-Cart reBOOT (reDUX) Template

Thanks pauldodman, I found the error in patch.sql. I just had to make sure that if a segment of code is commented out, with a # at the beginning of the line, then the complete segment of code must be on one line in the editor.
__________________
Tony
Skipper at Nautical Style
X-Cart Gold Version 4.7.12
X-Cart reBOOT (reDUX) Template 4.7.12.5 (in development)
Reply With Quote
  #565  
Old 10-02-2024, 06:58 PM
  nauticalstyle's Avatar 
nauticalstyle nauticalstyle is offline
 

Advanced Member
  
Join Date: Jun 2012
Posts: 59
 

Default Re: X-Cart reBOOT (reDUX) Template

Quote:
Originally Posted by elmirage001
Hi Phil,

I've updated to v4.7.12.9 and all looks good!

Thank you so much for the UPDATES Folder with all of the individual updates. This was brilliant and made upgrading from v4.7.12.4 a breeze.

Thanks again!

Paul




Hi Paul,


After a long break from working on the upgrade to reBOOT[reDUX] on my Linux laptop (running PopOS), I'm back on the path towards updating to V4.7.12.9, starting from my installed version V4.7.12.5. But with five V4.7.12.5 updates ([01], [02], [03], [04], and [05]) to work from in download, I was somewhat confused as to where I should start. So the update has not been such a breeze for me



I basically didn't properly check what version I had installed and so I started to reinstall the V4.7.12.5_[01]_May_12_2021_Update by mistake. It was OK until I copied all the update files from the 4.7.12.5_[01] upload folder to my installed x-cart root directory.



I have managed to access the site admin back-end but can't open the storefront (the resulting page is blocked.html "Sorry, access is not permitted"). I'm not getting any clues as to why this is happening from the error log in /var/log, so I'm not sure where to go from here, except to start debugging.
__________________
Tony
Skipper at Nautical Style
X-Cart Gold Version 4.7.12
X-Cart reBOOT (reDUX) Template 4.7.12.5 (in development)
Reply With Quote
  #566  
Old 10-07-2024, 05:16 PM
  nauticalstyle's Avatar 
nauticalstyle nauticalstyle is offline
 

Advanced Member
  
Join Date: Jun 2012
Posts: 59
 

Default Re: X-Cart reBOOT (reDUX) Template

I have isolated the problem down to the X-Cart_reBOOT_reDUX_v4.7.12.5_[01]_May_12_2021_Update of /reboot/country_redirect.php.
__________________
Tony
Skipper at Nautical Style
X-Cart Gold Version 4.7.12
X-Cart reBOOT (reDUX) Template 4.7.12.5 (in development)
Reply With Quote
  #567  
Old 10-10-2024, 04:39 PM
  nauticalstyle's Avatar 
nauticalstyle nauticalstyle is offline
 

Advanced Member
  
Join Date: Jun 2012
Posts: 59
 

Default Re: X-Cart reBOOT (reDUX) Template

How are the trusted IP addresses determined for the array $trusted_ips = array("231.123.321.123", "654.456.654.456");
in /reboot/country_redirect.php?
__________________
Tony
Skipper at Nautical Style
X-Cart Gold Version 4.7.12
X-Cart reBOOT (reDUX) Template 4.7.12.5 (in development)
Reply With Quote
  #568  
Old 10-11-2024, 06:42 PM
  nauticalstyle's Avatar 
nauticalstyle nauticalstyle is offline
 

Advanced Member
  
Join Date: Jun 2012
Posts: 59
 

Default Re: X-Cart reBOOT (reDUX) Template

I'm working from localhost (IP: 127.0.0.1) using XAMPP on a Windows PC, and LAMPP on a Linux machine. In /reboot/country_redirect.php, the variable defined by...

$details = json_decode(file_get_contents("https://ipinfo.io/{$ip}"));

...does not return a $country_code for $ip = 127.0.0.1, so when it checks if it's a "good country", it returns false, and exits to the /blocked.html page.

To get it to work with localhost I have put a in new if statement to check if the IP address is 127.0.0.1, and then it bypasses the "good country" check.
__________________
Tony
Skipper at Nautical Style
X-Cart Gold Version 4.7.12
X-Cart reBOOT (reDUX) Template 4.7.12.5 (in development)
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Third Party Add-Ons for X-Cart 4


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 05:36 AM.

   

 
X-Cart forums © 2001-2020