X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Third Party Add-Ons for X-Cart 4 (https://forum.x-cart.com/forumdisplay.php?f=45)
-   -   X-Cart - reBOOT - Responsive Template (https://forum.x-cart.com/showthread.php?t=66570)

PhilJ 09-04-2019 06:39 AM

Re: X-Cart - reBOOT - Responsive Template

1) In skin/reboot/customer/home.tpl




<script>var $ccatid;{if $current_category.categoryid}$ccatid={$current_category.categoryid};{/if}</script>
2) In skin/reboot/js/custom/reboot_products.js


        setGrid(); // USAGE: setGrid(); or setRows(); or setList();



    // Set Products Layout to 'List' for Specific Categories

    if ($ccatid){
        var prev_products_layout = products_layout;
        console.log("Current Layout: "+prev_products_layout);
        console.log("Category ID: "+$cat);
        if ($ccatid == 7 || $ccatid == 999999999){
            $('.products-container .item').removeClass('col-xs-12 col-sm-6 col-md-4 col-lg-4 col-lg-12 grid-view rows-view list-view').addClass('col-lg-12 list-view');
        } else {
            if (prev_products_layout == 'Grid') {
            } else if (prev_products_layout == 'Rows') {
            } else if (prev_products_layout == 'List') {

Replace the numbers in red with the category ID(s).

zone1creative 09-04-2019 06:43 AM

Re: X-Cart - reBOOT - Responsive Template
Awesome stuff Phil .

peggyr 09-11-2019 04:06 PM

Re: X-Cart - reBOOT - Responsive Template
Thanks Phil,

It has taken me a while to figure your reBOOT template out, but have made exponential progress this week. Looking forward to new update.

THANK YOU SO MUCH! Just tested mobile on my phone, and it works great --

thank you , thank you, thank you!

peggyr 09-16-2019 05:49 PM

Re: X-Cart - reBOOT - Responsive Template
Hi Phil,

I'm just confirming the wordpress level to use with reBOOT 4.7.11 on a 4.7.11 Goldplus.

I had installed wordpress 5.2.3 but would get publish failed when trying to publish a new post.

Then I saw the install.txt had "Currently supports Wordpress v4.7 - https://wordpress.org/download/"

So, I downloaded and installed 4.7, and now I get a fatal error

Uncaught Error: Call to undefined function determine_locale() in /homepages/11/999/htdocs/xcart/blog/wp-includes/script-loader.php:1199 Stack trace: #0 /homepages/11/999/htdocs/xcart/blog/wp-includes/class-wp-hook.php(298): wp_default_scripts(Object(WP_Scripts)) #1

what is the correct version I should be using? 4.7 or some later revision? If it is 4.7, I'll go back and retrace my steps to see if I created another problem somewhere


PhilJ 09-17-2019 01:40 AM

Re: X-Cart - reBOOT - Responsive Template
POST UPDATED 15th Oct 2019

You can actually use WP v5.2.4, which the demo is using (also using PHP v7.3.9)

WP auto-updates can break the blog, so I recommend disabling them in favour of manual updates...

In /blog/wp-config.php at the very end insert...

define( 'WP_AUTO_UPDATE_CORE', false );
/blog/includes/script-loader.php is a core file that sometimes get's overwritten when an update is performed.

If the blog is broken as a result of an update, in /blog/includes/script-loader.php *


    // jQuery
    $scripts->add( 'jquery', false, array( 'jquery-core', 'jquery-migrate' ), '1.12.4-wp' );
    $scripts->add( 'jquery-core', '/wp-includes/js/jquery/jquery.js', array(), '1.12.4-wp' );
    $scripts->add( 'jquery-migrate', "/wp-includes/js/jquery/jquery-migrate$suffix.js", array(), '1.4.1' );


    // jQuery
    if(is_admin()) { // reBOOT Template
    $scripts->add( 'jquery', false, array( 'jquery-core', 'jquery-migrate' ), '1.12.4-wp' );
    $scripts->add( 'jquery-core', '/wp-includes/js/jquery/jquery.js', array(), '1.12.4-wp' );
    $scripts->add( 'jquery-migrate', "/wp-includes/js/jquery/jquery-migrate$suffix.js", array(), '1.4.1' );
    } // reBOOT Template

You should also ensure that /blog/.htaccess is blank and non-writable, so CHMOD it to 444, which you may or may not be able to do in your FTP client, in which case use your control panel file manager to change it's permissions.

That's really all you need to know. The Alienship theme has to be used as it's Bootstrap 3 based. The next reBOOT reDUX blog uses this theme instead which is Bootstrap 4 based.

Some WP plugins will work, some may not. You should also be aware that some plugins may be dangerous or call home etc. so be careful what you install.

I recommend using the Yoast plugin for tweaking the SEO.

reBOOT reDUX has it's own blog feature if you don't wish to use WP. I am trying to get reDUX finished ASAP.


To avoid the issue with /blog/includes/script-loader.php
In /blog/wp-content/themes/alienship/functions.php
At the end insert...

if (!is_admin()) {
    wp_register_script('jquery', '', '', '', true);

peggyr 09-19-2019 12:04 PM

Re: X-Cart - reBOOT - Responsive Template
Thanks Phil and Paul,

I have WP 5.2.3 working and am on PHP 7.3.9. I needed to use the Classic Editor (thx Paul) to successfully publish a BLOG page or post and since I'm using a subdirectory for this store, I had to add the

RewriteBase /xcart/ to my .htaccess file.

I also had turned on 'clean urls' which turned out if it was listed 'first' in the .htaccess file, before the 'reBOOT' updates to .htaccess, I got 404. When I changed the order for the reBOOT lines first, followed by the clean urls, it worked.

I just reran a test on the order, and failed with 404 on blog entry if clean URLs are first, and succeed if reBOOT blog updates first as shown below.

# Wordpress Blog [[[
RewriteEngine On
#RewriteBase /
RewriteBase /xcart/
RewriteRule ^blog/(wp-login\.php|wp-admin|wp-includes|wp-content|wp-comments-post\.php|wp-cron\.php|xmlrpc\.php)(.*)$ blog/$1$2 [QSA,L]
RewriteRule ^blog/(.*).(css|js|gif|jpg|png|html|php)$ reboot_blog.php?incl_file=$1.$2 [QSA,L]
RewriteRule ^blog/.*$ reboot_blog.php?url=$1 [QSA,L]
RewriteRule ^blog$ reboot_blog.php [QSA,L]
# /Wordpress Blog ]]]

# Clean URLs [[[
# Options +FollowSymLinks -MultiViews -Indexes
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /xcart/
RewriteCond %{REQUEST_URI} !^/xcart/(payment|admin|provider|partner)/
RewriteCond %{REQUEST_URI} !^/server-status
RewriteCond %{REQUEST_URI} !\.(gif|jpe?g|png|js|css|swf|php|ico|svg|tif|avi|m p3|mp4|flv)$
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-l
RewriteRule ^(.*)$ dispatcher.php [L]
# /Clean URLs ]]]

peggyr 09-24-2019 11:30 AM

Re: X-Cart - reBOOT - Responsive Template
In case this is helpful for others, I was having a 'layout alignment' when resizing screen for featured categories.

Phil told me a couple changes to try, in the following 2 files, which worked for me.

in /skin/reboot/css/reboot.css -- I changed max-height value from 100 to 150 for class .featured_category_icon in

in /skin/reboot/custom/home/home_featured_categories.tpl -- I changed the truncate value from 150 to 155 for {$c.description|truncate:155:"...":true}

Including here in case helpful for others.

Thanks again Phil!

PhilJ 09-24-2019 02:13 PM

Re: X-Cart - reBOOT - Responsive Template
Small favour...

For reDUX I'm planning to use Minify to serve the template CSS/JS assets separately from the X-Cart assets and I would like to do a quick survey to see if it works on most servers.

If you have a spare moment, please grab this file (it's safe) and upload the /min folder to your store root, then try the following in your browser...


If CSS code appears, it works. Please drop me a quick PM (don't reply here) letting me know if it worked or not, along with your PHP version.

If it doesn't work, please let me know what type of server you have.

Then just delete the /min folder. If you're using less than PHP v5.3, no need to bother.

I appreciate your time, TIA :)

Updated 18/03/20, new link to zip file.

PhilJ 10-10-2019 01:22 AM

Re: X-Cart - reBOOT - Responsive Template
Mad, what have I started? So much to do.

zone1creative 10-10-2019 01:53 AM

Re: X-Cart - reBOOT - Responsive Template

Originally Posted by PhilJ
Mad, what have I started? So much to do.

Damn!! that form is longer than the one for getting UK settlement after brexit

All times are GMT -8. The time now is 10:03 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2022, Jelsoft Enterprises Ltd.