Jump to content

Upgrade to CC 6.4.9 Problems


Claudia

Recommended Posts

I have updated my store to 6.4.9 using the stock code downloaded from the CubeCart home page.  I've come across some issues.

 

1.  My PHP version was downgrade to 7.4.3 from the 8.1.13 I was using.

2.  My administrator for Ian (Havenswift) disappeared

3.  The update to change the alt tag for photos in admin isn't there

4.  Even though I have Venmo unchecked in the PayPal Commerce plugin it was checked after the upgrade and I had to manually uncheck it.

 

I use a custom skin and went thru each file from the Foundation skin with stock 6.4.9 and made the appropriate changes.

When I upgraded the image portion of the code in the content.products ( I merged the files ) I got a white screen and the following error.

Note the extra ) here:  {$LANG.catalogue.click_enlarge}"{if isset($image.image_tags.title))}

When I deleted it, it worked fine

 

  [<strong>Exception</strong>] /home/xxxxxxx/public_html/includes/lib/smarty/sysplugins/smarty_internal_templatecompilerbase.php:32 - Syntax error in template "file:/home/xxxxxxx/public_html/skins/xxxxxxx-1/templates/content.product.php" on line 32 "<li><a href="{$image.source}" class="th"><img src="{$image.small}" data-image-swap="{$image.medium}" data-caption="{$PRODUCT.name}{if !empty($image.description)}: {/if}{$image.description}" class="image-gallery" alt="{if isset($image.image_tags.alt) && !empty($image.image_tags.alt)}{$image.image_tags.alt}{else}{$image.name}{/if} - {$LANG.catalogue.click_enlarge}"{if isset($image.image_tags.title))} title="{$image.image_tags.title}"{/if}></a></li>" - Unexpected ")", expected one of: "}"

Link to comment
Share on other sites

Regarding the template syntax error, an issue has been posted in the Github.

https://github.com/cubecart/v6/issues/3126

3. Check the code in the admin skin file filemanager.index.php, near lines 122-129:

  {if $FILE.type == 1}
  <div>
    <label for="alt">{$LANG.filemanager.alt}</label>
    <span>
      <input type="text" id="alt" name="details[alt]" class="textbox" value="{$FILE.alt}">
    </span>
  </div>
  {/if}

Also in this file, make this change:

Lines 117-119, from:

      <select name="details[move]" id="move" class="textbox">
        <option value="">{$LANG.form.please_select}</option>
      </select>

To;

      <select name="details[move]" id="move" class="textbox">
        <option value="">{$LANG.form.please_select}</option>
{if isset($DIRS)}{foreach from=$DIRS item=dir}        <option value="{$dir.path}"{$dir.selected}>{$dir.path}</option>{/foreach}{/if} {* #3121 *}
      </select>

1. Is this what CubeCart reports in admin, Dashboard, Store Overview tab? Or is this aspect of the server environment being shown somewhere else?

 

  • Like 1
Link to comment
Share on other sites

Is your hosting provider able to determine when, approximately, your specific server environment was changed from PHP8.1 to PHP7.4? And by who/what?

CubeCart would need extraordinary power to overrule server operating system permissions to edit the necessary configuration files. (That said, I do not find any code in CubeCart that would - if it could - change server configuration files.)

 

Link to comment
Share on other sites

The filemanger changes worked.  I must have used and old file

As for the PHP version after I upgraded to 6.4.9 I just happened to look at the store overview in admin to make sure it said 6.4.9.  That's when I noticed the PHP was at 7.4.3. I told Ian about it and he changed it back to 8.1.13

Link to comment
Share on other sites

I think I have all the above sorted out, but now these are popping up in my admin system error log. There's more but you get the idea.  Also I keep getting logged out of admin.

 

            [<strong>Deprecated</strong>] /home/xxxxxx/public_html/classes/session.class.php:676 - strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated

http:///

 

            [<strong>Deprecated</strong>] /home/xxxxxx/public_html/classes/session.class.php:676 - htmlspecialchars(): Passing null to parameter #1 ($string) of type string is deprecated

http:///

 

[<strong>Deprecated</strong>] /home/xxxxxx/public_html/classes/debug.class.php:260 - strstr(): Passing null to parameter #1 ($haystack) of type string is deprecated

http:///

 

            [<strong>Deprecated</strong>] /home/xxxxxx/public_html/classes/cache/file.class.php:224 - preg_match(): Passing null to parameter #2 ($subject) of type string is deprecated

https://109.123.79.170/

 

            [<strong>Deprecated</strong>] /home/xxxxxx/public_html/classes/cache/file.class.php:224 - preg_match(): Passing null to parameter #2 ($subject) of type string is deprecated

https://www.cambargainstore.com/picture-frame-dog-large-fox-terrier-4x6

 

            [<strong>Deprecated</strong>] /home/xxxxxx/public_html/classes/cache/file.class.php:224 - preg_match(): Passing null to parameter #2 ($subject) of type string is deprecated

https://109.123.79.170/ab2g

 

            [<strong>Deprecated</strong>] /home/xxxxx/public_html/classes/db/database.class.php:184 - strtolower(): Passing null to parameter #1 ($string) of type string is deprecated

https://www.cambargainstore.com/admin_ZRmm9l.php?_g=customers

 

            [<strong>Deprecated</strong>] /home/xxxxxx/public_html/classes/cache/file.class.php:224 - preg_match(): Passing null to parameter #2 ($subject) of type string is deprecated

https://www.cambargainstore.com/index.php/web/wp-includes/wlwmanifest.xml

 

[<strong>Deprecated</strong>] /home/xxxxxx/public_html/classes/cache/file.class.php:224 - preg_match(): Passing null to parameter #2 ($subject) of type string is deprecated
https://www.cambargainstore.com/index.php/sito/wp-includes/wlwmanifest.xml

 

            [<strong>Deprecated</strong>] /home/xxxxxx/public_html/classes/cache/file.class.php:224 - preg_match(): Passing null to parameter #2 ($subject) of type string is deprecated

https://www.cambargainstore.com/index.php/wp2/wp-includes/wlwmanifest.xml

 

[<strong>Deprecated</strong>] /home/xxxxxx/public_html/classes/cache/file.class.php:224 - preg_match(): Passing null to parameter #2 ($subject) of type string is deprecated

https://www.cambargainstore.com/index.php/cms/wp-includes/wlwmanifest.xml

 

            [<strong>Deprecated</strong>] /home/xxxxxx/public_html/classes/cache/file.class.php:224 - preg_match(): Passing null to parameter #2 ($subject) of type string is deprecated

https://www.cambargainstore.com/index.php/wp1/wp-includes/wlwmanifest.xml          

 

            Today, 14:20   [<strong>Deprecated</strong>] /home/xxxxxx/public_html/classes/cache/file.class.php:224 - preg_match(): Passing null to parameter #2 ($subject) of type string is deprecated

https://www.cambargainstore.com/index.php/test/wp-includes/wlwmanifest.xml

Link to comment
Share on other sites

This is all due to PHP 8+ and its new, stricter use of arguments on the expected type of those arguments in functions.

CubeCart will find and fix the code that PHP is complaining about.

Turning off debug mode may silence some of these log entries.

 

Link to comment
Share on other sites

That would be any of:

  • your hosting environment has acquired a 'cron' job that cleans up session files on a regular basis
  • your browser disposes of cookies for unknown reasons
  • records in the database table CubeCart_sessions goes missing somehow

As for the cron job, that happened to me when I first installed PHP 7 on a local Linux server. (Installing PHP 8 alongside PHP 7 did not re-add that cron job). The job was to fire off every half-hour at 5 and 35 minutes after the hour, deleting all of PHP's session files. Session files are linked to the cookies recorded in the database.

 

Link to comment
Share on other sites

CC648 (now CC649) has adjusted many, many locations in the code to deal with the now increased strict attitude about certain things.

Running CC647 and older under PHP 8 will have many warnings generated unless silenced.

So, in ini.inc.php, near line 18:

Find:

error_reporting(E_ALL & ~E_NOTICE & ~E_WARNING);

Change to:

error_reporting(E_ALL & ~E_NOTICE & ~E_WARNING & ~E_DEPRECATED & ~E_USER_DEPRECATED);

 

 

Link to comment
Share on other sites

  • 3 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...