Jump to content

Updated Cubecart 6.2.8 Store Invisible - Admin Works Fine


whirringcogs

Recommended Posts

Just updated our Cubecart store from 622 to 628.

The admin side of the store is working OK, but the store is not visible. Nothing is apparently delivered to the browser.

I have just made a brand new fresh installation of 628 on the same server, and this installation has the same problem.

I have also tried a full clean install on a different web host, and again the same problem - a blank storefront.

Getting this system error:

[<strong>Exception</strong>] /domain.co.uk/cc628/includes/lib/smarty/filters/HTMLMinify.smarty.php:166 - syntax error, unexpected ';'

Link to comment
Share on other sites

One of the recent versions of CubeCart added the function to squeeze down the byte count of the HTML sent out by removing all unnecessary spaces, tabs, and line endings.

My copy of HTMLMinify.smarty.php shows line 166 is a PHP comment.

Please verify that this file has not been modified, is 9,935 bytes, and the file's timestamp shows it was last modified 22 November 2019.

Link to comment
Share on other sites

Many thanks for your reply. I can verify that this file has not been modified, is 9,935 bytes, and was last modified 6 November 2019 at 11:40:42. My line 166 on my PC is also a PHP comment.

Prompted by your reply I checked the file on the server, and it looks like for some reason, my (old) FTP client modified this particular file on upload in each case. This is how this file on the server looked, lines 160-168:

function fn_minify_html($input, $comment = 2, $quote = 1) {
    if (!is_string($input) || !$input = n(trim($input))) return $input;
    $output = $prev = "";
    foreach (fn_minify([MINIFY_COMMENT_HTML, MINIFY_HTML_KEEP, MINIFY_HTML, MINIFY_HTML_ENT], $input) as $part) {
        if ($part === "\n") continue;
        if ($part !== ' ' && trim($part) === "" || $comment !== 1 && strpos($part, '') {
                                                                      
                                                                          
                $output .= $part;
            }
            continue;

Link to comment
Share on other sites

Just for further edification, what specific FTP client removes what looks like HTML comments?

To specify, the code that is missing begins on line 165 starting with the HTML comment open sequence <!--, and finishes two lines later at the closing sequence -->.

This is extremely dangerous because this sequence very likely appears elsewhere in the code.

I would recommend, using a different FTP client (or the same with different config settings), re-upping the package.

Or, in the admin, Maintenance, Upgrade tab, there is a "Restore Current Version" which will re-install the package downloaded direct from CubeCart HQ (assuming no corruption of the installed admin code).

Link to comment
Share on other sites

Note to Self: Having imported a package into a local software version control repository, the files' timestamp will be the date of the import as seen in the repository viewer, then checking out a working copy, the files will have a Last Modified date of the date they were checked out. The Last Modified date from the source package is lost.

The files from the source package are, as you said, dated 6 Nov, at 40 minutes past the hour (the hour depends on the workstation's timezone).

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...