Forums / Templates, Stylesheets, Page Layout / Changing the name of a template.

Changing the name of a template.

Started by petleyj on 1 Apr 2013, 2:39 AM · Views: 823

Results 1 to 8 of 8
1 Apr 2013, 2:39 AM
#1
petleyj avatar

petleyj

Zen Follower

Join Date:
Jul 2009
Location:
Norwich, UK
Posts:
122
Plugin Contributions:
0

Changing the name of a template.

Hi Guys.

I am re-developing my site and would like to know how to change the name of a template. We're using a /bootstrap template and wish to change the name. However upon changing the template fold name, it overrides to template_default

How can I change the name and ensure it doesn't get overridden nor affected.

Live demo via http://naughtynightsuk.co.uk/zencart

Any help would be appreciated.

James

FMUK Consulting - Web Design & Development | Graphics | Marketing | Apps - http://www.FMUKConsulting.co.uk

1 Apr 2013, 3:12 AM
#2
gjh42 avatar

gjh42

Black Belt

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

Re: Changing the name of a template.

You also need to change the name in /includes/templates/your_template/template_info.php, so that the admin files have a unique handle to identify the new template with in the template selector.

1 Apr 2013, 3:48 AM
#3
petleyj avatar

petleyj

Zen Follower

Join Date:
Jul 2009
Location:
Norwich, UK
Posts:
122
Plugin Contributions:
0

Re: Changing the name of a template.

gjh42:

You also need to change the name in /includes/templates/your_template/template_info.php, so that the admin files have a unique handle to identify the new template with in the template selector.

Hi GJH42, does as you have said but it comes up in colours again. Pic below.

Also the link now contains an adult product due to testing. NSFW.

FMUK Consulting - Web Design & Development | Graphics | Marketing | Apps - http://www.FMUKConsulting.co.uk

1 Apr 2013, 8:22 AM
#4
schoolboy avatar

schoolboy

Totally Zenned

Join Date:
Jun 2005
Location:
Cumbria, UK
Posts:
10,327
Plugin Contributions:
0

Re: Changing the name of a template.

PetleyJ:

Hi GJH42, does as you have said but it comes up in colours again. Pic below.

Also the link now contains an adult product due to testing. NSFW.

If you chnge the name of the template folder, then (as Glenn says) you need to change the template_info.php file as well...

But that's just step one.

STEP TWO

You now need to go through ALL your:

languages
modules

...folders and RE-NAME all the old custom template sub-folders to the new template name as well.

(Drill right down through every sub-folder... there are several custom-named folders at various directory levels. You must find ALL of them).

STEP THREE

In your Admin Panel, under TOOLS, go to Template Selector and select the NEW template. This makes database changes.

STEP FOUR

Go to TOOLS, Layout Boxes Controller and scroll down the page. Click the RESET button. You may have to re-organise sideboxes the way you had them before.

20 years a Zencart User

1 Apr 2013, 8:28 AM
#5
schoolboy avatar

schoolboy

Totally Zenned

Join Date:
Jun 2005
Location:
Cumbria, UK
Posts:
10,327
Plugin Contributions:
0

Re: Changing the name of a template.

BEAR IN MIND that SOME custom templates make reference to files using hard-coded paths in the PHP. I know Picaflor Azul's ALL BUSINESS template does this, for example...

... so if you change the NAME of your template (template folders), then such hard-coded calls will go nowhere and you may end up with php errors (or a blank screen).

SO - BEFORE you change the name of the template (preferably), use TOOLS >>> Webmaster Toolkit to find instances of your template's OLD NAME (original name) in a-href paths.

20 years a Zencart User

1 Apr 2013, 9:16 AM
#6
schoolboy avatar

schoolboy

Totally Zenned

Join Date:
Jun 2005
Location:
Cumbria, UK
Posts:
10,327
Plugin Contributions:
0

Re: Changing the name of a template.

But to be honest... I don't know why this is bothering you.

Your visitors dont care (or know) what "template" you are using.

Just leave it alone and focus on what matters.

20 years a Zencart User

1 Apr 2013, 10:48 AM
#7
petleyj avatar

petleyj

Zen Follower

Join Date:
Jul 2009
Location:
Norwich, UK
Posts:
122
Plugin Contributions:
0

Re: Changing the name of a template.

Thanks for the reply Schoolboy.

Will do as you have said.

Reason being as it's going to make finding the folders easier.

James

FMUK Consulting - Web Design & Development | Graphics | Marketing | Apps - http://www.FMUKConsulting.co.uk

1 Apr 2013, 5:45 PM
#8
schoolboy avatar

schoolboy

Totally Zenned

Join Date:
Jun 2005
Location:
Cumbria, UK
Posts:
10,327
Plugin Contributions:
0

Re: Changing the name of a template.

PetleyJ:

Reason being as it's going to make finding the folders easier.

What's so difficult about it at the present time? A foldername is a foldername...

20 years a Zencart User