Results 1 to 4 of 4

Hybrid View

  1. #1
    Join Date
    Jan 2012
    Posts
    89
    Plugin Contributions
    0

    Default Illegal String offset 'tag' in tpl_checkout_stacked.php addon

    Did an Apache upgrade on my server which upgraded my PHP to version 5.6, now getting the below error.

    10-Feb-2019 21:12:41 America/New_York] PHP Warning: Illegal string offset 'tag' in /home/XXXXXX/public_html/includes/templates/ayd_responsive/templates/tpl_checkout_stacked.php on line 109

    below is line 109

    <label class="inputLabel"<?php echo ($field['tag']) ? ' for="'.$field['field']['tag'].'"': ''; ?>><?php echo $field['title']; ?></label>

    Any idea how to fix this, I know I am due for ZC upgrade but if anyone could suggest a fix to this I would appreciate it.
    Last edited by Coins2012; 11 Feb 2019 at 03:42 AM.

  2. #2
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,683
    Plugin Contributions
    123

    Default Re: ZC1.50 Illegal String offset 'tag'

    Code:
    <?php
    if (!empty($field['tag'])) { 
       echo '<label class="inputLabel"' . ' for="'.$field['field']['tag']. '>'; 
    } else {
       echo '<label class="inputLabel">'; 
    }
    echo $field['title']; 
    ?></label>
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  3. #3
    Join Date
    Jan 2012
    Posts
    89
    Plugin Contributions
    0

    Default Re: ZC1.50 Illegal String offset 'tag'

    Quote Originally Posted by swguy View Post
    Code:
    <?php
    if (!empty($field['tag'])) { 
       echo '<label class="inputLabel"' . ' for="'.$field['field']['tag']. '>'; 
    } else {
       echo '<label class="inputLabel">'; 
    }
    echo $field['title']; 
    ?></label>
    Thank you but I am new to this, do I replace line 190 with the code you provided?

  4. #4
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,683
    Plugin Contributions
    123

    Default Re: ZC1.50 Illegal String offset 'tag'

    You remove line 109 (the one you posted) and add in my code in its place. Then test carefully.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

 

 

Similar Threads

  1. v155 PHP Warning: Illegal string offset 'id' in
    By diptimoy in forum General Questions
    Replies: 1
    Last Post: 9 Feb 2019, 12:47 PM
  2. v151 Illegal string offset 'id' in moneyorder.php
    By d0ugparker in forum General Questions
    Replies: 1
    Last Post: 3 Aug 2017, 05:07 AM
  3. Illegal string offset 'id' in order.php
    By marcopolo in forum General Questions
    Replies: 16
    Last Post: 25 Jul 2015, 04:31 PM
  4. v153 Illegal string offset 'id' in order.php
    By jeking in forum General Questions
    Replies: 0
    Last Post: 5 Sep 2014, 07:32 PM
  5. v151 PHP Warning: Illegal string offset 'id'
    By Nettric in forum Bug Reports
    Replies: 3
    Last Post: 30 May 2014, 06:53 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR