Page 2 of 2 FirstFirst 12
Results 11 to 15 of 15
  1. #11
    Join Date
    Feb 2010
    Location
    Australia
    Posts
    77
    Plugin Contributions
    0

    Default Re: how do I set up a demo site for upgrading?

    Quote Originally Posted by DrByte View Post
    You've got something wrong somewhere.
    Zen Cart will pull from template_default if it can't find the requested templates or images in your active template's folder.
    So, if you've set your store to use a template named "CUSTOM" then it'll first look under /includes/templates/CUSTOM/ for the expected file. If it doesn't find it there then it'll jump to /includes/templates/template_default/ since that's the master location. THIS IS THE REASON why you ONLY need your customized files copied to your custom folder, instead of duplicating the entire set of template files.

    The only reason it would look in the "classic" folder would be if you had set the "classic" template as your active template via Admin->Tools->Template Selection. In that case it'll look in the classic folder first, and then if it doesn't find an expected file, it'll look in template_default.
    That's just how the override system works.

    So ... if you were hoping for it to use a file from CUSTOM but it's not, then you don't have CUSTOM active, or you haven't got the expected file under your CUSTOM folder.

    And, if you've got CUSTOM enabled in your Admin area but on your storefront it's using classic, then you've got your admin pointing to some different database in the configure.php files.
    Thanks for the help dr byte

    i agree with what you say but my problem is different

    1st website(running good)
    set to run of classic template in the admin. as such is and calling the images from classic directory and is all running well


    2nd website(not running good, testing before taking live)
    set to run of CUSTOM template in the admin. it is running CUSTOM template with problems.
    example is the header images are not displaying. this is due to them being called from either the wrong spot or the wrong name being called for


    EXAMPLE

    in tpl_header.php under common in the template there is this code. this is in both the files in both the websites

    <?php echo '<a href="' . HTTP_SERVER . DIR_WS_CATALOG . '">' . zen_image($template->get_template_dir(HEADER_LOGO_IMAGE, DIR_WS_TEMPLATE, $current_page_base,'images'). '/' . HEADER_LOGO_IMAGE, HEADER_ALT_TEXT) . '</a>'; ?>
    </td>

    RESULTS
    1st website
    the above code causes the website to source the image from
    <img src="includes/templates/classic/images/header_03.jpg"
    this is the correct name of the image in the correct location

    2nd website
    the above code causes the website to source the image from
    <img src="includes/templates/CUSTOM/images/logo.gif"
    this is the correct CUSTOM directory, but the wrong image, it should search for header_03.jpg . im trying to understand why it calls the wrong name

    this is for the first image of the header, the header is made up of four images


    EXAMPLE 2
    i dont have the code on me for the second header image

    RESULTS
    1st website
    the code calls for the website to source the image from
    <img src="includes/templates/classic/images/header_04.jpg"
    again the right image at the write place

    2nd website
    the code calls for the website to source
    <img src="includes/templates/template_default/images/HEADER_LOGO_IMAGE2"
    this is not an image???? and not in the right "CUSTOM" directory???

    My two other problem header images are the same as example 2(not an image and wrong directory)

    there is more similar problems, but if i figure the problem with these i can figure the others out


    OK i hope to have provided lots of info to get help lol
    thanks by the way

  2. #12
    Join Date
    Jan 2004
    Posts
    66,391
    Blog Entries
    7
    Plugin Contributions
    81

    Default Re: how do I set up a demo site for upgrading?

    So, you've not set up your custom language files properly.
    Your /includes/languages/english/classic/header.php specifies header_03.jpg as the HEADER_LOGO_IMAGE
    But when you use CUSTOM, you're getting logo.gif, which is the default, which comes from the master file at /includes/languages/english/header.php (which you should not edit).
    The correct fix is to COPY the /includes/languages/english/header.php file TO /includes/languages/english/custom/header.php and specify the desired image there.
    (or you could copy FROM your /includes/languages/english/classic/ folder to your CUSTOM folder, if all you're really trying to do is convert "classic" into your own template.)
    Same goes with ALL the language files you're customizing.
    Your second case is likely resolved similarly.
    .

    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.

  3. #13
    Join Date
    Feb 2010
    Location
    Australia
    Posts
    77
    Plugin Contributions
    0

    Default Re: how do I set up a demo site for upgrading?

    thanks thats exactly what i thought, a languages define,
    your a wealth of knowledge DrByte, will try to do as you say. still learning about zencart but came a long way in the last few days
    thanks again

  4. #14
    Join Date
    Feb 2010
    Location
    Australia
    Posts
    77
    Plugin Contributions
    0

    Default Re: how do I set up a demo site for upgrading?

    Nearly finished upgrading the site. last problem is the home page where i have a fading banner. this is the code from the index.php where error is. ### i added to show where the debug is saying call to undefined function


    if ($banner->RecordCount() > 0) {
    ?>
    <div id="bannerSix" class="banners"><?php //echo zen_display_banner('static', $banner); ?></div>

    <div style="border:#ffffff solid 1px; width:591px; height:443px;" id="imageContainer">
    <!--<img style="display: none; opacity: -0.01;" src="images/banners/think_anim.gif" alt="">
    <img style="display: none; opacity:-0.01;" src="images/banner.jpg" alt="">-->
    <?php
    /*for($x = 1; $x <= $banner->RecordCount(); $x++) {
    ### echo zen_display_banner_custom('static', $banner);
    }*/
    while (!$banner->EOF) {
    echo zen_display_banner_custom('static', $banner);
    $banner->MoveNext();
    }
    ?>

    <!--<img style="display: none; opacity:-0.01;" src="images/banners/big-book-ad.gif">-->

    <!--<img style="display: none; opacity: -0.01;" src="images/4.jpg" alt="">
    <img style="display: none; opacity: -0.01;" src="images/5.jpg" alt=""> -->
    </div>

    the banner is supposed to be able to be added in the admin banners. if i change the coding such that the hidden codes arent hidden(the ones that specify specific banner images such as 4.jpg) then the banner works with the images but does not go on to the rest of index codes and footer codes. this means everything after the banned wont load
    thanks in advance

  5. #15
    Join Date
    Feb 2010
    Location
    Australia
    Posts
    77
    Plugin Contributions
    0

    Default Re: how do I set up a demo site for upgrading?

    i dont understand why but that code works in the old website, not fully in the new one

 

 
Page 2 of 2 FirstFirst 12

Similar Threads

  1. Demo site for new releases?
    By soki in forum Upgrading to 1.5.x
    Replies: 7
    Last Post: 2 Oct 2011, 01:37 PM
  2. Demo site for new template
    By juneloweelyn in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 12 Jun 2011, 04:09 AM
  3. Replies: 7
    Last Post: 11 Jan 2010, 11:18 PM
  4. How to set a demo site of Zen-cart templates?
    By waterlin in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 13 Mar 2009, 01:42 PM
  5. CAPTCHA for Zen Cart Demo Site?
    By normaljoe in forum All Other Contributions/Addons
    Replies: 0
    Last Post: 3 Jul 2008, 10:35 PM

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