Zen Cart Logo
Forums / Templates, Stylesheets, Page Layout / Stupid question re templates

Stupid question re templates

Locked

Views: 923

Results 1 to 7 of 7
This thread is locked. New replies are disabled.
16 Jul 2007, 11:02 PM
#1
idcowden avatar

idcowden

New Zenner

Join Date:
Jul 2007
Posts:
12
Plugin Contributions:
0

Stupid question re templates

This would seem to be an obvious question, easily answered, but I cannot find an answer in the wiki, the docs, the faqs, the knowledgebase or the forum (or my searching is terrible - draw your own conclusions!!).

Here goes...

If I download a template for Zen cart how do I get it to appear in the list in admin/tools/template selection

I am using the latest zen cart. The template I downloaded is the free template from template monster (pithily named TN001) The template is uploaded into includes/templates (so I now have classic,template_default and YOUR_TEMPLATE as well as TN001 folders in that directory). I have tried moving TN001 to YOUR_TEMPLATE and to YOUR_TEMPLATE/templates, but it will not show up in Admin/Tools/Template Selection. The only template that shows up is classic.

Anyone tell me what I'm doing wrong?

Iain

16 Jul 2007, 11:04 PM
#2
Kim avatar

Kim

Obaa-san

Join Date:
Jun 2003
Location:
West Coast, North America
Posts:
26,615
Plugin Contributions:
0

Re: Stupid question re templates

First- before doing anything - search for Template Monster on the forum.

16 Jul 2007, 11:16 PM
#3
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Stupid question re templates

... and then when you go to build your own template, this FAQ may help:
https://www.zen-cart.com/tutorials/index.php?article=142

... along with these:
How do I setup template overrides?
https://www.zen-cart.com/tutorials/index.php?article=36

Template files- what are they and how are they used?
https://www.zen-cart.com/tutorials/index.php?article=232

The override system really simplified
https://www.zen-cart.com/tutorials/index.php?article=143

Understanding the override system
https://www.zen-cart.com/tutorials/index.php?article=230

17 Jul 2007, 3:04 AM
#4
afo avatar

afo

Totally Zenned

Join Date:
Aug 2004
Location:
New York City
Posts:
6,800
Plugin Contributions:
0

Re: Stupid question re templates

Most templates require that files be uploaded to various directories, not just one.

To create a very basic custom template (you can build from there), you need:

  • includes/languages/YOUR_TEMPLATE/english.php
  • includes/languages/english/YOUR_TEMPLATE/index.php
  • includes/languages/english/YOUR_TEMPLATE/header.php (to change the logo)
  • includes/templates/YOUR_TEMPLATE/template_info.php
  • includes/templates/YOUR_TEMPLATE/common/tpl_header.php
  • includes/templates/YOUR_TEMPLATE/common/tpl_footer.php
  • includes/templates/YOUR_TEMPLATE/images/logo.gif
  • includes/templates/YOUR_TEMPLATE/css/stylesheet.css

Any where you see a /classic/ folder, you can create a folder for your custom template. Copy the files you need from /classic/, /template_default/ or the parent directory.

Edit includes/templates/YOUR_TEMPLATE/template_info.php to give your template identifying info (you'll understand when you open the file).

Always use a text editor like Notepad or Crimson Editor to edit php files.

Once you've built your template, go into your admin under tools->template selection and select it from the pull down menu.

17 Jul 2007, 11:26 AM
#5
idcowden avatar

idcowden

New Zenner

Join Date:
Jul 2007
Posts:
12
Plugin Contributions:
0

Re: Stupid question re templates

Thanks for your help guys.

I'm gathering the following;-

  1. Template monster templates are worse then useless. Shooting yourself repeatedy in the foot is preferable.

  2. Zen tempates don't work the same way as most templates (most templateable php software allows you to drop a new template in a directory and then select it). Haven't really found an explanation for the template selection tool yet.

Iain

17 Jul 2007, 11:39 AM
#6
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Stupid question re templates

idcowden:

(most templateable php software allows you to drop a new template in a directory and then select it).That is indeed how a Zen Cart template can work.

  • upload the files to your site
  • open your admin area
  • go to Tools->Template Select
  • click Edit, choose your new template. Click save.
  • go to the storefront and refresh your browser
  • poof it's new.
  • customize the placement of your sideboxes to suit your tastes via the Layout Boxes Controller in Admin->Tools menu.

If a given template hasn't been designed properly, there may be glitches in that process.

22 Oct 2008, 11:47 AM
#7
tharina avatar

tharina

New Zenner

Join Date:
Oct 2008
Posts:
49
Plugin Contributions:
0

Re: Stupid question re templates

just something I struggled with aswell being totally new....
and realised if you copy the downloaded template folder and changed the name to YOUR_TEMPLATE_NAME in includes/template
AND
changed the $template_name = 'YOUR_TEMPLATE_NAME';
in the template_info.php
update your admin tool
and then it should be in your dropdown box of the template picker