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)
-   -   What files can add content to the very left and right column (https://forum.x-cart.com/showthread.php?t=13037)

azo313 03-26-2005 09:03 PM

What files can add content to the very left and right column
 
There are so many TPL files I have no idea which does what.

I am wondering which TPL file(s) to edit to add content to the very left and right columsn at the bottom. For example, under the "help" box on the left, and under the "authentication" box on the right.

Is there any type of instruction list that tells what files can change what portions of the site?

Also, how can I edit what links show up in the "Help" box on the left. How can I edit the content in the existing links, and more importantly, add new links (of new pages) in there?

Thanks!

Bella Forma 03-27-2005 12:42 AM

skin1/customer/home.tpl is your starting point that's where you will find the layout.

To find out what templates are being called from a particular page your viewing you can use webmaster mode, if you haven't discovered it yet have a look in the manual it is described in there.

Regarding the links in the help box have a look in skin1/help.tpl (which is called from skin1/customer/home.tpl)

Hope that helps... have fun!

MythNReality 03-27-2005 11:27 PM

Adding another box on the right/left
 
I have the same question...I know the Home.tpl, but the question is how to add it? What's the code for it? Are there any other files that I need to add or modify to get it work?
I do have some JavaScript knowledge, but not sure how these files are associated with one and another to make it work.

I actually, need at least two more boxes: one on the righ hand side, I would like to include a picture and text underneath it. the other on the left hand side that contains other static pages (e.g. photo album, size reference chart etc..).

One more question: I would like to add the greeting customer by first name inside the minicart...will I be able to do it? and how?

Can anyone help with more details?



:wink:
http://www.PetAdorn.com
p.s. I just purchased the X-cart this month.

Alphatim 03-28-2005 01:06 AM

Hello Myth,

Maybe is better if you start to understand the template engine that x-cart uses: Smarty

You have to know a bit of html, if so, keep reading.

As you can see, inside your "customer/home.tpl" you have:
Code:

{include file="customer/menu_cart.tpl"}
You see a smarty function (include) that tells to smarty include the template file named "menu_cart.tpl". Ok, let's open this tpl that is located at "customer/".

Once is open you can see at the top:
Code:

{include file="customer/main/minicart.tpl"}
Oh! Another include! Once again, let's follow the path and open the "minicart.tpl". Voilц║, you are inside your "minicart.tpl", now you only have to insert the welcome msg:
Code:

{if ($active_modules.Greet_Visitor ne "") and ($smarty.cookies.GreetingCookie ne "")}
{$lng.lbl_welcome_back}, {$smarty.cookies.GreetingCookie|replace:"\'":"'"}
{/if}

I didn't invent this peace of code, I just copy from customer/main/welcome.tpl. How did I found this tpl? Like Bella Forma said:
Quote:

To find out what templates are being called from a particular page your viewing you can use webmaster mode, if you haven't discovered it yet have a look in the manual it is described in there.

Everything you need is inside the template files; you only have to search and copy/past/add/modify a bit. It is easier to achieve your needs if you start to understand how smarty works and how x-cart works with smarty. Hope this helps you a bit.

Best regards.

MythNReality 03-28-2005 11:58 AM

Thank you \:D/ Alphatim
It works!!!


All times are GMT -8. The time now is 10:20 AM.

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