Zen Cart Logo
Forums / Templates, Stylesheets, Page Layout / Template overrides in languages/english/modules/shipping ?

Template overrides in languages/english/modules/shipping ?

Locked

Views: 3,139

Results 1 to 15 of 15
This thread is locked. New replies are disabled.
16 Aug 2006, 8:07 AM
#1
imac avatar

imac

New Zenner

Join Date:
Mar 2006
Location:
Durham, UK
Posts:
78
Plugin Contributions:
0

Template overrides in languages/english/modules/shipping ?

There's a classic folder in there so I tried creating a /my_template/ override, but it doesn't seem to work. Is it supposed to?

16 Aug 2006, 8:20 AM
#2
drbyte avatar

drbyte

Sensei

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

Re: Template overrides in languages/english/modules/shipping ?

This pattern should work:

/includes/languages/english/modules/shipping/silvercity/rates.php

where silvercity is your active/selected template name
and rates.php is the name of the shipping module file you're trying to override

17 Aug 2006, 4:31 AM
#3
imac avatar

imac

New Zenner

Join Date:
Mar 2006
Location:
Durham, UK
Posts:
78
Plugin Contributions:
0

Re: Template overrides in languages/english/modules/shipping ?

DrByte:

This pattern should work:

/includes/languages/modules/shipping/silvercity/rates.php

where silvercity is your active/selected template name
and rates.php is the name of the shipping module file you're trying to override

Thanks Doc. Tried that and it still isn't working.

Similar pathnames can get a bit confusing so I'm wondering if I'm doing something really stupid here? Just to be sure I started again with a copy of flat.php, put copies in the following folders and put the path in one of the defines so I could see in admin which file was being used.

None of the following worked for me:
/includes/languages/modules/shipping/silvercity/flat.php
/includes/languages/english/modules/shipping/silvercity/flat.php

I even tried:
/includes/languages/english/silvercity/modules/shipping/flat.php

But the only one I can get to show is the base file in:
/includes/languages/english/modules/shipping/flat.php :cry:

17 Aug 2006, 4:59 AM
#4
drbyte avatar

drbyte

Sensei

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

Re: Template overrides in languages/english/modules/shipping ?

is your site set to the "silvercity" template ?

Works fine for me on a fresh install... as long as the proper template is selected

17 Aug 2006, 11:49 AM
#5
imac avatar

imac

New Zenner

Join Date:
Mar 2006
Location:
Durham, UK
Posts:
78
Plugin Contributions:
0

Re: Template overrides in languages/english/modules/shipping ?

DrByte:

is your site set to the "silvercity" template ?
Certainly is. I've been working on the stylesheet so I know that area of the templating system is working OK. I've even tried copying and pasting the directory name again just in case there was any confusion with the exact name, but it's still not happening for me.
DrByte:

Works fine for me on a fresh install... as long as the proper template is selected
Apart from the template, mine's fresh too. Oh well. Nothing to do but forget about it and hope something pops up later. Thanks for the help anyway. :smile:

17 Aug 2006, 1:35 PM
#6
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Template overrides in languages/english/modules/shipping ?

Have you an URL to your site? I cannot reproduce this issue and maybe seeing your site will spark a bell ...

17 Aug 2006, 3:12 PM
#7
imac avatar

imac

New Zenner

Join Date:
Mar 2006
Location:
Durham, UK
Posts:
78
Plugin Contributions:
0

Re: Template overrides in languages/english/modules/shipping ?

Ajeh:

Have you an URL to your site? I cannot reproduce this issue and maybe seeing your site will spark a bell ...
Thanks for the offer Linda but I'm running on localhost at the moment 'till we've got some of the other more crucial issues resolved. This one's curious (aren't they all :smile: ) but I can easily work round it by editing the core file. Just wanted to keep to the rigours of the template system is all.

17 Aug 2006, 5:55 PM
#8
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: Template overrides in languages/english/modules/shipping ?

Basic(stupid) question...

Do you have a folder at /includes/templates/silvercity/ ??

And the edited template_info.php file in that folder?

17 Aug 2006, 6:13 PM
#9
imac avatar

imac

New Zenner

Join Date:
Mar 2006
Location:
Durham, UK
Posts:
78
Plugin Contributions:
0

Re: Template overrides in languages/english/modules/shipping ?

kobra:

Basic(stupid) question...
Not at all. It's a stupid problem, so anything that jogs the grey-cells out of whatever tramline they're currently on is much appreciated :smile:

kobra:

Do you have a folder at /includes/templates/silvercity/ ??
Certainly do. That's where I've been editing the stylesheet.
kobra:

And the edited template_info.php file in that folder?
Could I resist the opportunity to put my name on the template? :smile:

17 Aug 2006, 6:49 PM
#10
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Template overrides in languages/english/modules/shipping ?

Check that if you view source and see your stylesheets coming from:

includes/templates/silvercity

That you are spelling silvercity exactly that way in the
/includes/languages/english/modules/shipping/silvercity

Meaning if you see
includes/templates/SilverCity

You should be using:
/includes/languages/english/modules/shipping/SilverCity

17 Aug 2006, 8:31 PM
#11
imac avatar

imac

New Zenner

Join Date:
Mar 2006
Location:
Durham, UK
Posts:
78
Plugin Contributions:
0

Re: Template overrides in languages/english/modules/shipping ?

Ajeh:

Check that if you view source and see your stylesheets coming from:
includes/templates/silvercity
That you are spelling silvercity exactly that way in the
/includes/languages/english/modules/shipping/silvercity
Yes I am. I made doubly sure of that by pasting rather than typing the directory names.
Ajeh:

You should be using:
/includes/languages/english/modules/shipping/SilverCity
Now I am really getting confused.
That path is where I found the classic folder to begin with and first tried the override.
But the Doc says:
DrByte:

This pattern should work:
/includes/languages/modules/shipping/silvercity/rates.php
Which one of those 2 paths should it be? Or should both work?

17 Aug 2006, 8:34 PM
#12
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Template overrides in languages/english/modules/shipping ?

/includes/languages/english/modules/shipping/silvercity/flat.php

You have to specify which language directory as well ...

18 Aug 2006, 6:01 AM
#13
imac avatar

imac

New Zenner

Join Date:
Mar 2006
Location:
Durham, UK
Posts:
78
Plugin Contributions:
0

Re: Template overrides in languages/english/modules/shipping ?

Ajeh:

You have to specify which language directory as well ...
Thanks Linda. That clears that one up. So the good Doc has been leading me down the garden path again has he? :yes: That's the medical profession for ya!

So I've copied this file to:
/includes/languages/english/modules/shipping/silvercity/flat.php

Which is where I put it in the first place - hence the title of the thread (any chance of any of the admins editing it for me and putting the slash back in the english? :)

Anyway... So then I edit one of the defines to say something like 'SilverCity Override'

Then I look in Admin -> Modules -> Shipping to see if it's showing those defines instead of the template_default ones... And am a bit surprised to discover that it isn't.

Now, my slip in the title of this thread proves that none of us are immune to finger trouble. So I start again from scratch, double-checking every step, over and over again till I'm so cabbaged I can't see for looking. But it still doesn't work.

So I hit the forum to see if anyone else has this problem. And from what you're all saying it would appear it's only me. So it has to be some stupidity on my part.

In my experience if you make a deliberate attempt to ignore gremlins like these then you can be sure they'll jump up and slap you right in the face just exactly when your not looking :yes:

Meanwhile, there are much more pressing concerns which are preventing us going live. See you on the bugs threads? :smile:

18 Aug 2006, 6:20 AM
#14
drbyte avatar

drbyte

Sensei

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

Re: Template overrides in languages/english/modules/shipping ?

Hmmm ... a typo eh? That's 2 today ... :lamo:

Question ... does the proper "override" name appear in the checkout-shipping page? You only talked about it showing wrongly in the admin...

18 Aug 2006, 3:11 PM
#15
imac avatar

imac

New Zenner

Join Date:
Mar 2006
Location:
Durham, UK
Posts:
78
Plugin Contributions:
0

Re: Template overrides in languages/english/modules/shipping ?

DrByte:

Hmmm ... a typo eh? That's 2 today ... :lamo:
Nasty little critters. Get everywhere :)
DrByte:

Question ... does the proper "override" name appear in the checkout-shipping page? You only talked about it showing wrongly in the admin...
No two ways about it Doc... you're a genius :thumbsup: I didn't get that far. Just freaked out when it didn't appear in admin. I knew I was being stupid about something - and you've put your finger right on it. I should have remembered that admin is completely separate and doesn't really need to connect to the template system.
What a dodo :oops:
Thanks for all the help guys. Something tells me I ought to start thinking about getting the coffees in :cheers: