Zen Cart Logo

Still can't get.

Locked

Views: 2,481

Results 1 to 20 of 21
This thread is locked. New replies are disabled.
31 Oct 2009, 10:10 AM
#1
salib avatar

salib

New Zenner

Join Date:
Oct 2009
Location:
Osaka, Japan
Posts:
44
Plugin Contributions:
0

Still can't get.

  1. I have been reading very carefully KH's book, the Tutorials FAQ and the various discussions concerning how to create custom templates but still do not get it. what else I should read?
  2. When the instructor says " copy the includes/templates/template_default/css directory" does it mean copy the whole includes directory upto the ccs file or simply copy the css file in that directory?
    Thank you.
    Alfred @ completely bewildered.
    :rotflmao:
31 Oct 2009, 10:15 AM
#2
kuroi avatar

kuroi

Totally Zenned

Join Date:
Apr 2006
Location:
London, UK
Posts:
10,475
Plugin Contributions:
11

Re: Still can't get.

If you have created a template called YOUR_TEMPLATE_NAME, it means copy the directory (and all its contents) called "css" in includes/templates/template_default to includes/templates/YOUR_TEMPLATE_NAME to create a new folder includes/templates/YOUR_TEMPLATE_NAME/css

2 Nov 2009, 2:59 AM
#4
salib avatar

salib

New Zenner

Join Date:
Oct 2009
Location:
Osaka, Japan
Posts:
44
Plugin Contributions:
0

Re: Still can't get.

Kuroi, Lat9
Thank you for your kind help.
What I have been trying to do is simply to ad my own header with logo, and have copied the custom folder, which is in the includes/templates/custom directory, and renamed it customwm.
In the customwm folder, I replaced header_bg with my own header_bg and log in the images folder and uploaded into /templates folder under the includes director as follows:
includes/templates/
and the same level in the templates folder:
custom
cumstomwm
CUSTOM_TEMPLATE (Japanese template kindly provided by SR Ward development)
template-defaulte
I have also changed template_info PHP as instructed in the book.

However, my customwm is not overriding the original custom folder. The only way that I could replace the original zen cart header and logo with my own header and logo was to replace them directly in the images folder in the the custom folder.
Why is the files in the customwm folder are not not overriding the original files in the custom folder?

My understanding is that if I modify directly any file located in the custom folder under templates in the include directory, they will be overridden when there is an update of the zen cart, and I will have to re-start all over again.
:unsure:

2 Nov 2009, 3:51 AM
#5
afo avatar

afo

Totally Zenned

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

Re: Still can't get.

salib:

Kuroi, Lat9
Thank you for your kind help.
What I have been trying to do is simply to ad my own header with logo, and have copied the custom folder, which is in the includes/templates/custom directory, and renamed it customwm.
In the customwm folder, I replaced header_bg with my own header_bg and log in the images folder and uploaded into /templates folder under the includes director as follows:
includes/templates/
and the same level in the templates folder:
custom
cumstomwm
CUSTOM_TEMPLATE (Japanese template kindly provided by SR Ward development)
template-defaulte
I have also changed template_info PHP as instructed in the book.

However, my customwm is not overriding the original custom folder. The only way that I could replace the original zen cart header and logo with my own header and logo was to replace them directly in the images folder in the the custom folder.
Why is the files in the customwm folder are not not overriding the original files in the custom folder?

My understanding is that if I modify directly any file located in the custom folder under templates in the include directory, they will be overridden when there is an update of the zen cart, and I will have to re-start all over again.
:unsure:

Yes, if you modify the files that came with Zen Cart, your work will be lost when you update/upgrade.

Anywhere you see a /classic/ folder, you can create a folder for your custom template. You can copy the necessary files from either the /classic/ folder, the /template_default/ folder or the parent folder.

Edit includes/templates/YOUR_TEMPLATE/template_info.php to give your template identifying information so you'll recognize it in the admin under tools->template selection.

2 Nov 2009, 5:52 AM
#6
salib avatar

salib

New Zenner

Join Date:
Oct 2009
Location:
Osaka, Japan
Posts:
44
Plugin Contributions:
0

Re: Still can't get.

Thank you.

:oops:
Please accept my apologies for being a little dumb
Very stupid of me, I must be getting hysteric.
In previous massage I should have written "classic" folder instead "custom" folder.

Yes, I have copied the classic folder (and not the custom folder) in the directory includes/templates/classic.
Please allow to rephrase again what I did:
I copied the the classic folder and renamed it customwm and in this customwm folder, I replaced header_bg with my own header_bg and log in the images folder and uploaded into /templates folder under the includes director as follows:
includes/templates/
and the same level in the templates folder:
classic
cumstomwm
CUSTOM_TEMPLATE (Japanese template kindly provided by SR Ward development)
template-defaulte

I have also changed template_info PHP as instructed in the book.

However, it does not work.
:cry:

2 Nov 2009, 6:02 AM
#7
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: Still can't get.

custom
customwm
CUSTOM_TEMPLATE (Japanese template kindly provided by SR Ward development)
template-default

Are these all the exact folder names? A standard Zen Cart installation will have /template_default/ and /classic/ folders. Those will be overwrittten in an upgrade, but any other names will not. You may have a localization which comes with one or more template folders; what folders came with your Japanese installation? The creators of your localization may have a standard template name which you will need to modify to avoid being overwritten by a new localization version.

There are also other template folders you will need to copy and modify, in /includes/languages/ and possibly in /includes/modules/.

OK, first question already answered:)

2 Nov 2009, 7:45 AM
#8
salib avatar

salib

New Zenner

Join Date:
Oct 2009
Location:
Osaka, Japan
Posts:
44
Plugin Contributions:
0

Re: Still can't get.

Yes, these are the exact names of these folders
Originally, there were only the classic and template_default folders in the templates folder in the includes directory when I installed the full set of zen cart ver 1.3.8a (12.11.2007).

The CUSTOM_TEMPLATE folder was added when I uploaded the Japanese language package, CKD-Zen-Cart-Japanese-Pack1.0-UTF-8, to the server.

After testing the newly installed zen cart, I wanted to add my header and logo and copied the classic folder in the templates folder and renamed it "customwm" and replaced header_bg and the logo in the images folder with my own header and logo hoping that it would override the classic folder, but it does it.
I though that I may have to use tools to select customwm, but when I did that only the header and the logo appear on the main page. I must be missing something important.

I though of copying the whole include directory and add customwm into the templates folder on the same level of classic folder in the templates folder and upload it to the server once again but I am afraid that I may damage the Japanese language template.

Any advice?
Thank you.

2 Nov 2009, 8:40 AM
#9
kdays avatar

kdays

Zen Follower

Join Date:
May 2008
Posts:
239
Plugin Contributions:
0

Re: Still can't get.

When you copied the classic folder and renamed it, did you also modify the file 'template_info.php'?

When you go to Admin > Tools > Template Selection do you see both Classic AND customwm?

2 Nov 2009, 8:54 AM
#10
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: Still can't get.

Did you make /customwm/ folders matching the /classic/ folders in the /includes/languages/ folder?
Do you get the Japanese text output? Have you tried selecting the CUSTOM_TEMPLATE template which came with the Japanese pack? Is that option available?

2 Nov 2009, 10:03 AM
#11
salib avatar

salib

New Zenner

Join Date:
Oct 2009
Location:
Osaka, Japan
Posts:
44
Plugin Contributions:
0

Re: Still can't get.

kdays:

When you copied the classic folder and renamed it, did you also modify the file 'template_info.php'?

When you go to Admin > Tools > Template Selection do you see both Classic AND customwm?

Yes, I did modify the file 'template_info.php and can see both, the classic green and customwm.

regards

2 Nov 2009, 10:09 AM
#12
salib avatar

salib

New Zenner

Join Date:
Oct 2009
Location:
Osaka, Japan
Posts:
44
Plugin Contributions:
0

Re: Still can't get.

kdays:

When you copied the classic folder and renamed it, did you also modify the file 'template_info.php'?

When you go to Admin > Tools > Template Selection do you see both Classic AND customwm?

Yes, Idid modify the file file 'template_info.php' and I can see both Classic AND customwm.

Regards

2 Nov 2009, 10:25 AM
#13
salib avatar

salib

New Zenner

Join Date:
Oct 2009
Location:
Osaka, Japan
Posts:
44
Plugin Contributions:
0

Re: Still can't get.

gjh42:

Did you make /customwm/ folders matching the /classic/ folders in the /includes/languages/ folder?

Sorry, what do you mean by matching the /classic/folders in the /includes/languages/folder?
I haven't touched anything in the /languages/folder. Do I have to modify some files in this directory?

Do you get the Japanese text output? Have you tried selecting the CUSTOM_TEMPLATE template which came with the Japanese pack? Is that option available?[/QUOTE]

Yes, I am getting the Japanese text output.
I thought of selecting CUSTOM_TEMPLATE template but that option was not available.

Best regards

2 Nov 2009, 12:01 PM
#14
salib avatar

salib

New Zenner

Join Date:
Oct 2009
Location:
Osaka, Japan
Posts:
44
Plugin Contributions:
0

Re: Still can't get.

How strange, I have posted the following posts two hours ago but I do not see them anywhere in this thread:
salib Re: Still can't get.
Quote:Originally Posted by gjh42
Did you make /customwm/ folders matching the /classic/ folders in the /includes/languages/ folder?

Sorry, what do you mean by matching the /classic/folders in the /includes/languages/folder?
I haven't touched anything in the /languages/folder. Do I have to modify some files in this directory?

Do you get the Japanese text output? Have you tried selecting the CUSTOM_TEMPLATE template which came with the Japanese pack? Is that option available?[/quote]

Yes, I am getting the Japanese text output.
I thought of selecting CUSTOM_TEMPLATE template but that option was not available.

Best regards
2nd November 2009 07:09 PM
salib Re: Still can't get.
Quote:Originally Posted by kdays
When you copied the classic folder and renamed it, did you also modify the file 'template_info.php'?

When you go to Admin > Tools > Template Selection do you see both Classic AND customwm?

Yes, Idid modify the file file 'template_info.php' and I can see both Classic AND customwm.

Regards

:frusty:

2 Nov 2009, 3:44 PM
#15
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: Still can't get.

The /classic/ template has a template override file /includes/languages/english/classic/header.php which customizes some output.
If you didn't copy that folder & file to /includes/languages/english/customwm/header.php, you won't get the same English output.
You also need to make a copy of /includes/languages/japanese/header.php as
/includes/languages/japanese/customwm/header.php

2 Nov 2009, 3:50 PM
#16
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: Still can't get.

Re the CUSTOM_TEMPLATE folders - Does the Japanese pack have any /classic/ folders? If not, the /CUSTOM_TEMPLATE/ folders are probably the equivalent, and you should be able to make a /customwm/ folder wherever you see a /CUSTOM_TEMPLATE/ folder.

3 Nov 2009, 2:14 AM
#17
salib avatar

salib

New Zenner

Join Date:
Oct 2009
Location:
Osaka, Japan
Posts:
44
Plugin Contributions:
0

Re: Still can't get.

gjh42:

The /classic/ template has a template override file /includes/languages/english/classic/header.php which customizes some output.
If you didn't copy that folder & file to /includes/languages/english/customwm/header.php, you won't get the same English output.
You also need to make a copy of /includes/languages/japanese/header.php as
/includes/languages/japanese/customwm/header.php

Thank you again for your kind help.
I opened the japanese folder and found: classic which contains;_vti_cnf/header.php.
I copied the classic and renamed it template_worldm and opened header/php and modified the tagline to
define('HEADER_SALES_TEXT', '<h1> a wonderful world</h1>') and saved the file. I did the same thing for the includes/langugages/english/classic/header.php. => includes/langugages/english/template_worldm/header.php.
However, when I select my template from Admin>Tools>Template selection, I can only see my logo and header with the Japanese main page, which have not not modofied yet.
The sideboxes do not appear at all.
Alfred
Osaka, Japan
:unsure:

3 Nov 2009, 3:26 AM
#18
salib avatar

salib

New Zenner

Join Date:
Oct 2009
Location:
Osaka, Japan
Posts:
44
Plugin Contributions:
0

Re: Still can't get.

gjh42:

Re the CUSTOM_TEMPLATE folders - Does the Japanese pack have any /classic/ folders? If not, the /CUSTOM_TEMPLATE/ folders are probably the equivalent, and you should be able to make a /customwm/ folder wherever you see a /CUSTOM_TEMPLATE/ folder.

The only classic in Japanese pack is in includes/languages/japanese/classic, which includes the header.php file.
I have copied the classic file and renamed it template_worldm and modified the header.php's the header sales text to define('HEADER_SALES_TEXT', '<h1>a wonderful world。</h1>')

I have made a summary of the includes/templates folders and files and their structure on the server as follows:
In the includes/templates folder there are the following folders:
classic
CUSTOM_TEMPALTE
tempalte_default
template_worldm (my template)

In the CUSTOM_TEMPALTE folder there are the followings:
template folder
inside the template folder there are:
_vti_cnf
english
japanese
tpl_account_edit_default.php
tpl_address_book_default.php
tpl_create_account_success_default.php
tpl_modules_checkout_address_book.php
tpl_module_checkout_new_address.php
tpl_modules_create_account.php
in the above english folder there are:
tpl_account_edit_default.php
tpl_address_book_default.php
tpl_create_account_success_default.php
tpl_modules_checkout_address_book.php
tpl_module_checkout_new_address.php
tpl_modules_create_account.php
inside of the _vti_cnf folder there are:
tpl_account_edit_default.php
tpl_address_book_default.php
tpl_create_account_success_default.php
tpl_modules_checkout_address_book.php
tpl_module_checkout_new_address.php
tpl_modules_create_account.php
in the above english folder there are:
tpl_account_edit_default.php
tpl_address_book_default.php
tpl_create_account_success_default.php
tpl_modules_checkout_address_book.php
tpl_module_checkout_new_address.php
tpl_modules_create_account.php
inside of the japanese folder there are:
tpl_account_edit_default.php
tpl_address_book_default.php
tpl_create_account_success_default.php
tpl_modules_checkout_address_book.php
tpl_module_checkout_new_address.php
tpl_modules_create_account.php
in the above english folder there are:
tpl_account_edit_default.php
tpl_address_book_default.php
tpl_create_account_success_default.php
tpl_modules_checkout_address_book.php
tpl_module_checkout_new_address.php
tpl_modules_create_account.php
As you can see from the above CUSTOM_TEMPALTE, it does not have any classic folder.
Inside template_worldm (my template), I have copied the above classic folder and replace the zen cart header and log with my own header and log keep the same name e.g.: header_bg.jpeg,logo.gif as not to modify files referring to them.
I have also copied folders called common and ccs into this template since I would like to some modification to the stylesheet.css file, although my understanding is that I do not have to copy unmodified files.
The Japanese language package had the following folders:
admin
editor
includes
In the admin folder there are: _vti_cnf/includes/index.php/invoice.php
In the _vti_cnf folder there are index.php/invoice.php
In the includes folder there the languages folder which contains: _vti_cnf/japanese/japanese.php, which, I believe provide the menu in Japane the administration area.
The includes has; classes/functions/languages/modules/templates
the includes/langauge folder has the followings:_vti_cnf/english/japanese/japanese.php
I opened the japanese folder and found: classic which contains;_vti_cnf/header.php.
I copied the classic and renamed it template_worldm and opened header/php and modified the tagline to
define('HEADER_SALES_TEXT', '<h1> a wonderful world</h1>') and saved the file. I did the same thing for the includes/langugages/english/classic/header.php. => includes/langugages/english/template_worldm/header.php.
However, when I select my template from Admin>Tools>Template selection, I can only see my logo and header with the Japanese main page, which have not not modofied yet.
The sideboxes do not appear at all.
What else I should do?
Best regards
Alfred,
Osaka, Japan
:unsure:

3 Nov 2009, 4:04 AM
#19
kdays avatar

kdays

Zen Follower

Join Date:
May 2008
Posts:
239
Plugin Contributions:
0

Re: Still can't get.

Any time that you switch between templates ALL sideboxes are turned off by default. After selecting a new template, you will need to go to Admin > Tools > Layout Box Controller and click on the Reset button (which is at the bottom of the page).

This sets the sideboxes back to their default settings and you will then need to rearrange them the way you want them to appear.

Keep in mind that if you you will need to do this every time you switch between templates, you will need to reset the sideboxes and rearrange them again.

3 Nov 2009, 11:11 PM
#20
salib avatar

salib

New Zenner

Join Date:
Oct 2009
Location:
Osaka, Japan
Posts:
44
Plugin Contributions:
0

Re: Still can't get.

kdays:

Any time that you switch between templates ALL sideboxes are turned off by default. After selecting a new template, you will need to go to Admin > Tools > Layout Box Controller and click on the Reset button (which is at the bottom of the page).

This sets the sideboxes back to their default settings and you will then need to rearrange them the way you want them to appear.

Keep in mind that if you you will need to do this every time you switch between templates, you will need to reset the sideboxes and rearrange them again.

Thank you.
This is fantastic.
Now I can confidently proceed to change the css file.
Many thanks to all of you great people.
Alfred :clap: