Results 1 to 3 of 3
  1. #1
    Join Date
    Apr 2007
    Posts
    36
    Plugin Contributions
    0

    Default Error with tpl_header.php file. FILE ATTACHED PLEASE SOMEONE SPOT ERROR

    Hi,

    Ive been trying to edit my tpl_header.php file from my template section and it all seems to have gone wrong now. This was working perfect prior to me adding a line of text which has somehow stopped the customised header isplaying on front end of website. I have attached the source code of the file, can anyone see any errors within it.

    [FONT='Verdana','sans-serif']I opened up the file tpl_header.php and inserted some text on the page, anyway to cut a long story hort i made a minor change to the file whch has now resulted in it not displaying on the front end of my website. I started to panic and decided to download a version of zen and resort the tpl_header.php back to a standard file. As you can see from the homepage www.canvas101.co.uk [/FONT]

    [FONT='Verdana','sans-serif']I have attached the code of the tpl_header.php that I want displaying. It did work perfectly untill i started messing with it. Please could someone have a look for me as I have not a lot of experiene with php.[/FONT]

    [FONT='Verdana','sans-serif']Any help would be greatly appreciated[/FONT]

    [FONT='Verdana','sans-serif']<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">[/FONT]
    [FONT='Verdana','sans-serif']<?php[/FONT]
    [FONT='Verdana','sans-serif']/**[/FONT]
    [FONT='Verdana','sans-serif']* Common Template - tpl_header.php[/FONT]
    [FONT='Verdana','sans-serif']*[/FONT]
    [FONT='Verdana','sans-serif']* this file can be copied to /templates/your_template_dir/pagename<br /><html><head>[/FONT]
    [FONT='Verdana','sans-serif']<meta http-equiv="Content-Type" content="text/html; charset=unicode">[/FONT]
    [FONT='Verdana','sans-serif']<meta content="MSHTML 6.00.6000.16643" name="GENERATOR"></head>[/FONT]
    [FONT='Verdana','sans-serif']<body>[/FONT]
    [FONT='Verdana','sans-serif']* example: to override the privacy page<br >[/FONT]
    [FONT='Verdana','sans-serif']* make a directory /templates/my_template/privacy<br >[/FONT]
    [FONT='Verdana','sans-serif']* copy /templates/templates_defaults/common/tpl_footer.php to /templates/my_template/privacy/tpl_header.php<br >[/FONT]
    [FONT='Verdana','sans-serif']* to override the global settings and turn off the footer un-comment the following line:<br >[/FONT]
    [FONT='Verdana','sans-serif']* <br >[/FONT]
    [FONT='Verdana','sans-serif']* $flag_disable_header =[/FONT]

    [FONT='Verdana','sans-serif']true;<br >[/FONT]
    [FONT='Verdana','sans-serif']* * @package templateSystem * @copyright Copyright [/FONT]
    [FONT='Verdana','sans-serif']2003-2006 Zen Cart Development Team * @copyright Portions Copyright 2003 [/FONT]
    [FONT='Verdana','sans-serif']osCommerce * @license [/FONT][FONT='Verdana','sans-serif']http://www.zen-cart.com/license/2_0.txt GNU Public License [/FONT]
    [FONT='Verdana','sans-serif']V2.0 * @version $Id: tpl_header.php 4813 2006-10-23 02:13:53Z drbyte $ */ ?&gt; <?php[/FONT]
    [FONT='Verdana','sans-serif']// Display all header alerts via messageStack:[/FONT]
    [FONT='Verdana','sans-serif']if ($messageStack->size('header') &gt; 0) { echo [/FONT]
    [FONT='Verdana','sans-serif']$messageStack-&gt;output('header'); } if (isset($_GET['error_message']) [/FONT]
    [FONT='Verdana','sans-serif']&amp;&amp; zen_not_null($_GET['error_message'])) { echo [/FONT]
    [FONT='Verdana','sans-serif']htmlspecialchars(urldecode($_GET['error_message'])); } if [/FONT]
    [FONT='Verdana','sans-serif'](isset($_GET['info_message']) &amp;&amp; zen_not_null($_GET['info_message'])) { [/FONT]
    [FONT='Verdana','sans-serif']echo htmlspecialchars($_GET['info_message']); } else { } ?&gt; <?php echo HEADER_TITLE_CHECKOUT; ?><?php }?>[/FONT]
    [FONT='Verdana','sans-serif']<div id="headerWrapper">[/FONT]
    [FONT='Verdana','sans-serif']<div id="navMainSearch"><?php require(DIR_WS_MODULES . 'sideboxes/search_header.php'); ?></div><?php if ($_SESSION['customer_id']) { ?><?php echo HEADER_TITLE_LOGOFF; ?><?php[/FONT]
    [FONT='Verdana','sans-serif']} else {[/FONT]
    [FONT='Verdana','sans-serif']if (STORE_STATUS == '0') {[/FONT]
    [FONT='Verdana','sans-serif']?><?php echo HEADER_TITLE_LOGIN; ?><?php } } ?><?php echo HEADER_TITLE_CART_CONTENTS; ?> [/FONT]
    [FONT='Verdana','sans-serif']<br><?php echo HEADER_TITLE_CHECKOUT; ?>[/FONT]
    [FONT='Verdana','sans-serif']<div class="forward search_header"><?php require(DIR_WS_MODULES . 'sideboxes/search_header.php'); ?></div>[/FONT]
    [FONT='Verdana','sans-serif']<div class="spacer_1"></div><!-- <div id="topdiv">[/FONT]
    [FONT='Verdana','sans-serif']<div id="bannerdiv"><img id="BannerImg" alt="Canvas Prints & Canvas Printing by Canvas101" src="<?php echo DIR_WS_TEMPLATES . $template_dir; ?>/images/design/banner6.jpg" /></div>[/FONT]
    [FONT='Verdana','sans-serif']</div>[/FONT]
    [FONT='Verdana','sans-serif']-->[/FONT]
    [FONT='Verdana','sans-serif']<div id="topdiv">[/FONT]
    [FONT='Verdana','sans-serif']<div id="bannerdiv"><img [/FONT]
    [FONT='Verdana','sans-serif']src="[/FONT][FONT='Verdana','sans-serif']http://www.canvas101.co.uk/includes/templates/jsweb/images/design/banner1.jpg" [/FONT]
    [FONT='Verdana','sans-serif']name=PictureBox></div></div>[/FONT]
    [FONT='Verdana','sans-serif']<ul>[/FONT]
    [FONT='Verdana','sans-serif']<li><a title="Canvas101 Home" href="<?php echo zen_href_link(FILENAME_DEFAULT, [/FONT]
    [FONT='Verdana','sans-serif']'', 'NONSSL'); ? >">home</a> [/FONT]
    [FONT='Verdana','sans-serif']<li><a title="Information about Canvas101 and Canvas Printing" [/FONT]
    [FONT='Verdana','sans-serif']href="./index.php?main_page=page&amp;id=1&amp;chapter=0">about us</a> [/FONT]
    [FONT='Verdana','sans-serif']<li><a title="Gallery of Canvas Printing images" href="<?php echo zen_href_link(FILENAME_PRODUCTS_ALL, '', 'NONSSL'); ? [/FONT]
    [FONT='Verdana','sans-serif']>" >gallery</a> [/FONT]
    [FONT='Verdana','sans-serif']<li><a title="Canvas Printing Services" [/FONT]
    [FONT='Verdana','sans-serif']href="./index.php?main_page=page&amp;id=2&amp;chapter=0">services</a> [/FONT]
    [FONT='Verdana','sans-serif']<li><a title="Canvas Print Sizes and Prices" [/FONT]
    [FONT='Verdana','sans-serif']href="./index.php?main_page=page&amp;id=3&amp;chapter=0">sizes/prices</a> [/FONT]
    [FONT='Verdana','sans-serif']<li><a title="Materials available for Canvas Prints" [/FONT]
    [FONT='Verdana','sans-serif']href="./index.php?main_page=page&amp;id=4&amp;chapter=0">material</a> [/FONT]
    [FONT='Verdana','sans-serif']<li><a title="Frequently asked questions about canvas printing" [/FONT]
    [FONT='Verdana','sans-serif']href="./index.php?main_page=page&amp;id=5&amp;chapter=0">faq</a> [/FONT]
    [FONT='Verdana','sans-serif']<li><a title="Feedback Form" [/FONT]
    [FONT='Verdana','sans-serif']href="./index.php?main_page=page&amp;id=6&amp;chapter=0">feedback</a> [/FONT]
    [FONT='Verdana','sans-serif']<li><a title="Contacting Canvas101" href="<?php echo zen_href_link(FILENAME_CONTACT_US, [/FONT]
    [FONT='Verdana','sans-serif']'', 'NONSSL'); ? >">contacts</a> [/FONT]
    [FONT='Verdana','sans-serif']</li></ul>[/FONT]
    [FONT='Verdana','sans-serif']<p>[/FONT]
    [FONT='Verdana','sans-serif']<br class="clearBoth" ><!--eof-branding display--><!--eof-header logo and navigation display--><!--bof-optional categories tabs navigation display--><?php require($template->get_template_dir('tpl_modules_categories_tabs.php',DIR_WS_TEMPLATE, [/FONT]
    [FONT='Verdana','sans-serif']$current_page_base,'templates'). '/tpl_modules_categories_tabs.php'); ?&gt; <!--eof-optional categories tabs navigation display--><!--bof-header ezpage links--><?php if (EZPAGES_STATUS_HEADER == '1' or (EZPAGES_STATUS_HEADER == '2' and (strstr(EXCLUDE_ADMIN_IP_FOR_MAINTENANCE, $_SERVER['REMOTE_ADDR'])))) { ?><?php require($template->get_template_dir('tpl_ezpages_bar_header.php',DIR_WS_TEMPLATE, [/FONT]
    [FONT='Verdana','sans-serif']$current_page_base,'templates'). '/tpl_ezpages_bar_header.php'); ?&gt; <?php } ?><!--eof-header ezpage links--></p>[/FONT]
    [FONT='Verdana','sans-serif']</div><?php } ?></body></html>[/FONT]


  2. #2
    Join Date
    Jan 2004
    Posts
    59,767
    Blog Entries
    4
    Plugin Contributions
    133

    Default Re: Error with tpl_header.php file. FILE ATTACHED PLEASE SOMEONE SPOT ERROR

    Moderator comment on forum etiquette and getting faster answers:

    Posting the same issue in multiple places only frustrates the volunteers answering questions. Please keep your discussion to one thread per issue.
    http://www.zen-cart.com/forum/showthread.php?t=98627

    Also, if you're going to post file contents, don't add font tags all over ... what you posted above is going to cause everyone who looks at it to skip your post and move on to something that won't take an hour to sort out all the added markup you threw in for no reason.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donations always welcome: www.zen-cart.com/donate

    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. #3
    Join Date
    Apr 2007
    Posts
    36
    Plugin Contributions
    0

    Default Re: Error with tpl_header.php file. FILE ATTACHED PLEASE SOMEONE SPOT ERROR

    Please accept my apologies I am new to zen forums and was unaware of this. I will abide by all the rules in future. Once again Im sorry for any rules broken.

    Many Thanks

 

 

Similar Threads

  1. Error: File Not Found - (Zip file)
    By Dreameffects in forum General Questions
    Replies: 3
    Last Post: 7 May 2008, 02:45 AM
  2. ipn_main_handler file missing error but file present
    By Bryony in forum Built-in Shipping and Payment Modules
    Replies: 7
    Last Post: 11 Dec 2007, 02:08 AM
  3. Pal Pal payment w/o order form or file attached
    By texrah in forum PayPal Express Checkout support
    Replies: 1
    Last Post: 12 Nov 2007, 09:50 PM
  4. Cannot get the attached SWF file to run in FF nor IE7
    By Goshawk in forum General Questions
    Replies: 2
    Last Post: 30 Dec 2006, 06:20 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
  •