Results 1 to 10 of 1673

Hybrid View

  1. #1
    Join Date
    Sep 2008
    Location
    Cleethorpes
    Posts
    1,229
    Plugin Contributions
    6

    Default Re: ZCA Bootstrap Template

    Quote Originally Posted by Nick1973 View Post
    Still got issues with the sitemap page:

    [24-Jan-2020 10:18:43 UTC] PHP Fatal error: Cannot redeclare class zen_SiteMapTree in /home/MYSITE/public_html/includes/classes/site_map.php on line 19


    [24-Jan-2020 10:18:43 UTC] Request URI: /index.php?main_page=site_map, IP address: 00.00.000.000
    --> PHP Fatal error: Cannot redeclare class zen_SiteMapTree in /home/MYSITE/public_html/includes/classes/site_map.php on line 19.

    Tried replacing includes/classes/site_map.php with the original from a fresh download and I am still getting the same error
    Interesting:

    On line 20 of includes/classes/site_map.php we have this:

    PHP Code:
    class zen_SiteMapTree {   var $root_category_id 0,       $max_level 0,       $data = array(),       $root_start_string '',       $root_end_string '',       $parent_start_string '',       $parent_end_string '',       $parent_group_start_string "\n<ul>",       $parent_group_end_string "</ul>\n",       $child_start_string '<li>',       $child_end_string "</li>\n",       $spacer_string '',       $spacer_multiplier 1
    If I change
    PHP Code:
    var $root_category_id 0
    to
    PHP Code:
    var $root_category_id = -0
    the sitemap displays correctly
    Nick Smith - Venture Design and Print
    https://venturedesignandprint.co.uk

  2. #2
    Join Date
    Sep 2008
    Location
    Cleethorpes
    Posts
    1,229
    Plugin Contributions
    6

    Default Re: ZCA Bootstrap Template

    Quote Originally Posted by Nick1973 View Post

    Interesting:

    On line 20 of includes/classes/site_map.php we have this:

    PHP Code:
    class zen_SiteMapTree {   var $root_category_id 0,       $max_level 0,       $data = array(),       $root_start_string '',       $root_end_string '',       $parent_start_string '',       $parent_end_string '',       $parent_group_start_string "\n<ul>",       $parent_group_end_string "</ul>\n",       $child_start_string '<li>',       $child_end_string "</li>\n",       $spacer_string '',       $spacer_multiplier 1
    If I change
    PHP Code:
    var $root_category_id 0
    to
    PHP Code:
    var $root_category_id = -0
    the sitemap displays correctly
    Strange, that solutions works here:

    https://ventureengravings.uk/index.p..._page=site_map

    but not here:

    https://venturegraphicdesign.uk/inde..._page=site_map

    HELP!!!!
    Nick Smith - Venture Design and Print
    https://venturedesignandprint.co.uk

  3. #3
    Join Date
    Jan 2010
    Posts
    49
    Plugin Contributions
    0

    Default Re: ZCA Bootstrap Template

    I recently ran into a roadblock installing an Order Total module (Shipping Insurance - ot_insurance - 3.3.0 from Numinix - 2.3.2 from the addons is similar) on ZC 1.5.6c PHP 7.1.29 on XAMPP. The checkbox for the customer to select/deselect insurance is NOT visible. It is present in the HTML:
    Code:
    <!--bof discount coupon card-->
    <div id="discountCoupon-card" class="card mb-3">
    <h4 id="discountCoupon-card-header" class="card-header">
    Shipping Insurance</h4> 
    
    <div id="discountCoupon-card-body" class="card-body p-3">
    
    <p>Click here to add optional insurance to your order:</p>
    <div id="discountCoupon-gvBal"></div>
    
    <label class="inputLabel" for="opt_insurance">$7.10</label>
    <input class="custom-control-input" type="checkbox" name="opt_insurance" value="1" id="opt_insurance" /><input type="hidden" name="insurance" value="1" /></div>  
    </div>
    <!--eof discount coupon card-->
    I've chased this enough to be quite sure that it has to do with the template and its interactions with Order Total modules (probably also payment and shipping). Shipping is just an example module. I'm not sure how many others, if any, have checkboxes for customer selection.

    I'm not sure what to do to get the checkbox to appear. Suggestions?

  4. #4
    Join Date
    Jan 2004
    Posts
    66,443
    Plugin Contributions
    279

    Default Re: ZCA Bootstrap Template

    Maybe try this:
    Code:
    <div class="custom-control custom-checkbox">
    <input class="custom-control-input" type="checkbox" name="formfieldnamehere" value="1" id="nameTheInputIdHere">
    <label class="custom-control-label" for="nameTheInputIdHere" title="help msg here">Text In Browser Here</label>      
    </div>
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  5. #5
    Join Date
    Jan 2010
    Posts
    49
    Plugin Contributions
    0

    Default Re: ZCA Bootstrap Template

    Quote Originally Posted by DrByte View Post
    Maybe try this:
    Code:
    <div class="custom-control custom-checkbox">
    <input class="custom-control-input" type="checkbox" name="formfieldnamehere" value="1" id="nameTheInputIdHere">
    <label class="custom-control-label" for="nameTheInputIdHere" title="help msg here">Text In Browser Here</label>      
    </div>
    Thanks. I added code to includes/templates/CUSTOM/templates/tpl_checkout_payment_default.php to do this for checkboxes.

    From:
    Code:
    <!--bof discount coupon card-->
    <div id="discountCoupon-card" class="card mb-3">
    <h4 id="discountCoupon-card-header" class="card-header">
    <?php echo $selection[$i]['module']; ?></h4> 
    
    <div id="discountCoupon-card-body" class="card-body p-3">
    
    <?php echo $selection[$i]['redeem_instructions']; ?>
    
    <div id="discountCoupon-gvBal"><?php echo (isset($selection[$i]['checkbox'])) ? $selection[$i]['checkbox'] : ''; ?></div>
    
    <label class="inputLabel"<?php echo ($selection[$i]['fields'][$j]['tag']) ? ' for="'.$selection[$i]['fields'][$j]['tag'].'"': ''; ?>><?php echo $selection[$i]['fields'][$j]['title']; ?></label>
    <?php echo $selection[$i]['fields'][$j]['field']; ?>
    </div>  
    </div>
    <!--eof discount coupon card-->
    To:
    Code:
    <!--bof discount coupon card-->
    <div id="discountCoupon-card" class="card mb-3">
      <h4 id="discountCoupon-card-header" class="card-header"><?php echo $selection[$i]['module']; ?></h4> 
      <div id="discountCoupon-card-body" class="card-body p-3">
        <?php
            echo $selection[$i]['redeem_instructions'];
            if (strpos($selection[$i]['fields'][$j]['field'], 'type="checkbox"') === false) {   // filter out checkboxes
              if (isset($selection[$i]['checkbox'])) {
    ?> 
        <div id="discountCoupon-gvBal"><?php echo $selection[$i]['checkbox']; ?></div>
    <?php
              }
    ?> 
        <label class="inputLabel"<?php echo isset($selection[$i]['fields'][$j]['tag']) ? ' for="'.$selection[$i]['fields'][$j]['tag'].'"': ''; ?>><?php echo $selection[$i]['fields'][$j]['title']; ?></label>
        <?php
              echo $selection[$i]['fields'][$j]['field'];
            } else {                        // process checkboxes
    ?> 
        <div class="custom-control custom-checkbox">
          <?php echo $selection[$i]['fields'][$j]['field']; ?> 
          <label class="custom-control-label"<?php echo isset($selection[$i]['fields'][$j]['tag']) ? ' for="'.$selection[$i]['fields'][$j]['tag'].'"': ''; ?>><?php echo $selection[$i]['fields'][$j]['title']; ?></label>
        </div>
    <?php
            }
    ?> 
      </div>
    </div>
    <!--eof discount coupon card-->
    It made more sense to me to do this rather than modifying the Order Total add-on since it's specific to the current template.

 

 

Similar Threads

  1. v155 Clone a Template [Support Thread]
    By lat9 in forum Addon Admin Tools
    Replies: 107
    Last Post: 11 Nov 2024, 08:28 PM
  2. v150 aBagon Template Support Thread
    By VJef in forum Addon Templates
    Replies: 54
    Last Post: 5 Sep 2020, 08:44 PM
  3. v155 ZCA Bootstrap Template 1.0 (BETA)
    By rbarbour in forum Addon Templates
    Replies: 74
    Last Post: 25 Apr 2018, 07:05 PM
  4. TB Sempre Template Support Thread
    By brandonturpin in forum Addon Templates
    Replies: 48
    Last Post: 19 Mar 2015, 06:33 PM
  5. Wallet Template - Support Thread
    By zami in forum Addon Templates
    Replies: 45
    Last Post: 25 Mar 2010, 10:15 PM

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