Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Creating osCommerce Templates


vinces

Recommended Posts

Posted

Hello

 

I have Better Template System (BTS) installed in my osCommerce store and I want to create a very graphical template in Fireworks, but I am not sure on how to do this. First of all, after I create the template, how would I add the BTS variables (not sure what they're called, the code that shows parts of the store) into the template. I also have Dreamweaver, but not sure if that can help because everything made in Fireworks is a graphic file. I am completely lost. Can anyone please help? Thanks.

David Amherst

Posted

Have you downloaded the contribution and read the readme ?

 

:)

 

Hello

 

I have Better Template System (BTS) installed in my osCommerce store and I want to create a very graphical template in Fireworks, but I am not sure on how to do this. First of all, after I create the template, how would I add the BTS variables (not sure what they're called, the code that shows parts of the store) into the template. I also have Dreamweaver, but not sure if that can help because everything made in Fireworks is a graphic file. I am completely lost. Can anyone please help? Thanks.

Posted

BTSv1.4 Released under the GNU General Public License!

Download: http://www.oscommerce.com/community/contributions,1263

Support: http://www.oscommerce.com/forums/index.php?showtopic=71930 (same as v1.2 and v1.3)

 

2004/11/24

BACKUP BEFORE YOU START!

A lot of files are overwritten by this contribution, on a "fresh osC2.2 MS2 install" this is no problem of course,

but be carefull that you don't overwrite any files that are already modified (i.e. by another contribution or by you)!

If you can't overwrite some files you will have to edit the files yourself to make it work (doing file compares and/or reading changes.txt might help).

 

/*********************************************************/

IMPORTANT:

Install only on a standard osC2.2MS2 shop (no other osC versions supported, it won't work!!!).

I don't recommend to use this on a modified osC shop (maybe better use the STS then).

/*********************************************************/

 

To take advantage of the BTS you need at least have some basic knowledge of PHP, CSS, HTML and osC.

(and the basics of PHP are really are very easy/fun to learn)

 

*********************************************

* Notes about v1.4 *

*********************************************

 

Installation itself stayed exactly the same.

The main difference with the previous version is that if you create a new templates directory you don't need to copy all templates to your new templates directory, but only the ones youv'e editted. If the BTS finds the file in your templates directory it will be used, but if you haven't copied (or created) a template file yet, the BTS will fallback to the available template in the "fallback" directory.#

So if you create a new template dir called "myNewTemplateDir" (and set it as default in admin), and add a new main_tpl.php file to it, it will be used. Any missing files from this new templates directory won't result in an error because any missing files will be automaticly loaded from the fallback templates directory.

 

Note: as soon as you add a new stylesheet to your new templates directory you will also need to make sure your CSS background images will be available. So you might need to copy your templates/fallback/images/ directory and it's contents to your new templates dir.

 

*********************************************

* a) New BTSv1.3 install: *

*********************************************

 

/* Begin installation: */

 

1) Download osC2.2MS2, install it, and check if everything works fine.

 

2) Download the BTSv1.3 (you probably already did), no additional files needed.

If there will be any future updates/fixes by me, they will probably called BTSv1.3a BTSv1.3b etc..

 

3) Upload the contents of the included "catalog/" dir to your own osC "catalog/" overwriting any "old" files.

So open the zip file, go to the catalog directory,

and copy everything in it to you shop's catalog(or wathever you named it) directory.

 

4) insert the contents of "BTS.sql" (incuded in the zip file) into your osC database (i.e. using phpAdmin).

 

Sorry, but if you don't understand the above, maybe you better don't use the contrib at all :-)

 

/* End installation */

 

*********************************************

* B) Update from previous BTS versions: *

*********************************************

 

Changes to BTSv1.2 are small, mainly small bug fixes.

If your reviews and popups are working fine you probably don't need to update at all.

Don't have time to desrcibe the changes, do a file compare if you need it.

Read changes.txt

 

updating form older versions:

read the old docs, or start from scratch

 

 

Some features:

 

1) change the main looks of your shop by editting only some template files and the stylsheet

(mainly "main_page.tlp.php" for the main looks and "box.tpl.php" for all "small info boxes")

 

2) easyly (automaticly) create individual smal box tempates if you like

For example take "box.tpl.php" and save it as "shopping_cart.tpl.php"

(in the "templates/.../boxes/" directory)

No further installation needed, edit "shopping_cart.tpl.php" to see it work.

(box.tpl.php still controls all other small infoboxes)

 

3) All small infoboxes have their own css id assigned,

so even without separate templates you can make individual boxes look different through the stylesheet.

 

4) Switch templates through admin

(admin::configuration::my store 'Default Template Directory' and 'Template Switching' Allowed)

and/or switch by URL.

"Secretly" work on a new template and show it to everyone you like without the need of a separate install,

and without bothering your coctumers.

When you decide it's ready, switch in admin, to show it to the world.

 

5) Use any php code in the templates you like (that's one of the main differences to the STS I think)

 

6) dynamic meta tags and page titles ("includes/meta_tags.php")

 

7) A lot more I suppose....

 

One last note (is somebody still reading this?):

The incuded template is not ment to be used as it is!!!

It is not designed for great looks either.

It's only an example, you can use it to start creating your own template,

it might save you some time crawling through the many tables the standard osC template uses.

 

 

I found one called install.txt here it is.

 

TJ

 

 

 

 

There is no readme

Posted

I guess I didn't download a full version. There were no TXT files at all. But this still doesn't answer my question??? :(

David Amherst

Posted

Looks like you edit the .tpl (template files)

 

never used that before so i can't be sure...

 

 

 

I guess I didn't download a full version. There were no TXT files at all. But this still doesn't answer my question??? :(

Posted

Well if someone could tell me what to do with STS I coul do that instead. But editing the TPL files doesn't answer my question. I know what file need to be edited, but how would I do that if I create the template in Fireworks. If it is a graphic, you can't put text on top of it. And I don't imagine I could put the images inside of the TPL files. If I were to break the template into a lot of smaller graphics, how would I call them from within the template file. Would I just insert them, or use code. I am not a complete newbie, I've been using osCommerce forever but just started with BTS or STS. Anyone?

David Amherst

Posted

I think sts may be better suited to your needs, as the code is pulled in using tags., like $content - $categories

 

I read thru the BTS tpl files and it is quite heavy reading.

 

STS is much simpler, in my opinion, because you simply call teh items you want, where you want.

 

Probably make a difference what your template looks like and how many files you want to edit.

 

TJ

 

 

 

Well if someone could tell me what to do with STS I coul do that instead. But editing the TPL files doesn't answer my question. I know what file need to be edited, but how would I do that if I create the template in Fireworks. If it is a graphic, you can't put text on top of it. And I don't imagine I could put the images inside of the TPL files. If I were to break the template into a lot of smaller graphics, how would I call them from within the template file. Would I just insert them, or use code. I am not a complete newbie, I've been using osCommerce forever but just started with BTS or STS. Anyone?

  • 3 weeks later...
Posted
I think sts may be better suited to your needs, as the code is pulled in using tags., like $content - $categories

 

I read thru the BTS tpl files and it is quite heavy reading.

 

STS is much simpler, in my opinion, because you simply call teh items you want, where you want.

 

Probably make a difference what your template looks like and how many files you want to edit.

 

TJ

How do you edit how the $content looks? because thats what ive been trying to figure out. The $content variable just puts everything on the page, with its own template....how do you edit that?

Posted
How do you edit how the $content looks? because thats what ive been trying to figure out. The $content variable just puts everything on the page, with its own template....how do you edit that?

In your actual php files, as each of them generates $content, or try to reduce the $content generated to the minimim, and put the graphics/layout stuff as much as possible in your tpl and css files.

KEEP CALM AND CARRY ON

I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support).

So if you are still here ? What are you waiting for ?!

 

Find the most frequent unique errors to fix:

grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt

Posted

where are the TPL files located? btw im using the sts contribution so im actually using a html template.

Posted

I only just saw this thread and it looks like you are now going with a template system however I thought I would jump in and try to answer you fireworks questions. If you build the site in fireworks, you would then have to slice it up and export it to dreamweaver. Be sure when you get to the export menu to save as HTML and Images and have slices set to export slices. This process will break your site into tables for you and create the html file that you need. Once that is done, you can go to Dreamweaver, open the file and develop the files as templates. It will have imported your graphics in the tables exactly as they were in fireworks so if you want to be able to put text in that particular box, I would suggest that you remove the image and then put it back in as a background image.

 

Hope this helps.

 

Sarah

Posted

hi sarah,

if it didn't help him, it helped me.

I'm not a graphics type, but it's good to know how this works, and I can see now that using fireworks and dreamweaver for this kind of stuff would really work wel !

 

Thanks

Carine

KEEP CALM AND CARRY ON

I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support).

So if you are still here ? What are you waiting for ?!

 

Find the most frequent unique errors to fix:

grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt

Posted

Genu,

I've seen other customer implementation where the file is in the include directory, check there first, other possibility is include/templates ...

 

HTH

KEEP CALM AND CARRY ON

I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support).

So if you are still here ? What are you waiting for ?!

 

Find the most frequent unique errors to fix:

grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt

Posted
hi sarah,

if it didn't help him, it helped me.

I'm not a graphics type, but it's good to know how this works, and I can see now that using fireworks and dreamweaver for this kind of stuff would really work wel !

 

Thanks

Carine

 

Too bad Dreamweaver and Fireworks are Open Source and Free, or are they? wink wink

If it was easy, anyone could do it!

Posted

hey bruyndoncx, i dont have an includes/templates directiory. help plz

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...