Jump to content

PHP 7.4 & TEXT: Trying to access array offset on value of type null


Recommended Posts

Not sure how to find what is causing my issue here, I'm running smarty which gives me this error if I switch PHP version to 7.4 (was on 7.3) : -

 

Quote

ERRNO: 8
TEXT: Trying to access array offset on value of type null
LOCATION: /home/mywebsite/public_html/smarty_templates_c/6c6d4758b747deced9729a6e51ecf350702d314f_0.file.cart.tpl.php, line 365, at May 27, 2020, 11:32 am
Showing backtrace:
content_5ecd2ac2aa0d30_10801785(Object:Smarty_Internal_Template) # line  123, file: /home/mywebsite/public_html/include/smarty/sysplugins/smarty_template_resource_base.php
Smarty_Template_Resource_Base.getRenderedTemplateCode(Object:Smarty_Internal_Template) # line  114, file: /home/mywebsite/public_html/include/smarty/sysplugins/smarty_template_compiled.php
Smarty_Template_Compiled.render(Object:Smarty_Internal_Template) # line  216, file: /home/mywebsite/public_html/include/smarty/sysplugins/smarty_internal_template.php
Smarty_Internal_Template.render(false, "1") # line  232, file: /home/mywebsite/public_html/include/smarty/sysplugins/smarty_internal_templatebase.php
Smarty_Internal_TemplateBase._execute(Object:Smarty_Internal_Template, null, null, null, "1") # line  134, file: /home/mywebsite/public_html/include/smarty/sysplugins/smarty_internal_templatebase.php
Smarty_Internal_TemplateBase.display("pages/cart.tpl") # line  106, file: /home/mywebsite/public_html/cart/index.php

The line the error refers to is this : -

 

<p class="cart_del_info_box_text"><i class="fa fa-exclamation-triangle" aria-hidden="true"></i> <span class="cart_del_info_box_message"><?php echo $_smarty_tpl->tpl_vars['cart']->value->mDelivery['cartdeliverymessage'];?>

 

How do I go about finding which file has the actual problem? Thanks for any pointers.

Thanks, fixed that issue now the payment page has a whole load of similar errors!

<input <?php if (isset($_smarty_tpl->tpl_vars['cart']->value->mErrors['BillingFirstName'])) {?>class="error"<?php }?> type="text" name="BillingFirstName" tabindex="8" maxlength="25" value="<?php echo $_smarty_tpl->tpl_vars['cart']->value->mVars['BillingFirstName'];?>

 

Stuck on this one TBH!

 

 

This thread is more than a year old. Please don't revive it unless you have something important to add.

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.   Restore formatting

  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...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.