X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   include statement for header in 404_en.html (https://forum.x-cart.com/showthread.php?t=60602)

sdstren 08-20-2011 10:22 AM

include statement for header in 404_en.html
 
This should be so simple, but unfortunately, I only know enough to drive myself crazy.

I want to do an include statement for the header and footer in 404_en.html to use the header and footer I've already worked on for the rest of the site.

So, I went and looked at home.tpl to see how the header/footer is called there. It looks like this:

<div id="header">
{include file="customer/head.tpl"}
</div>

So, I cut/pasted this into 404_en.html and changed the path like this:
<div id="header">
{include file="/skin/common_files/customer/head.tpl"};
</div>

Well, that doesn't work. It reads the above as text, so I tried looking it up on w3schools to make it a php statement. Tried enclosing it in <?php tags:

<div id="header">
<?php include("/skin/common_files/customer/head.tpl"); ?>
</div>

The text is not on the screen now, but neither is the header.

Can someone please tell me what I'm doing wrong?
Sorry for my lack of expertise.

I just want to do a simple include and need someone to hold my hand and walk me through it.

cflsystems 08-20-2011 04:22 PM

Re: include statement for header in 404_en.html
 
404_en.html is an html file, what you are trying to do works on smarty template files. The php portion is also completely wrong. Just html code the header and footer instead of trying to go dynamic

sdstren 08-20-2011 07:48 PM

Re: include statement for header in 404_en.html
 
Thanks Steve. That's what I finally ended up doing.


All times are GMT -8. The time now is 02:35 AM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.