Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

A couple of basic questions about template


steevithak

Recommended Posts

I've just installed v2.3.3.3 and need to significantly customize the appearance. I've have a couple of questions about templates. I've got plenty of experience designing templates for Wordpress, Drupal, and Jooma, but I don't grok the OSC template system yet. The only documentation I can find for it is a couple of paragraphs in this document (which is suspicious since it includes "old" in the title but I couldn't find the "new version):

 

http://library.oscommerce.com/public/sites/Library/pdf/oscom23-old.pdf

 

From reading this, it appears the "template" is just a header and footer php file located in the includes directory. Is that really all we've got to work with when customizing the appearance?

 

Also, the location of those two files suggests any customization I make to the template would be overwritten when the next update occurs. Shouldn't there be a directory somewhere that's protected from overwrites during the update process and where multiple templates can reside?

 

How do one select which template is used? I can't seem to find anything in the admin that displays a list of available templates or allows me to choose which one is selected?

 

Sorry these are really basic questions! I really have looked for documentation but just can't find any.

 

-Steve

Link to comment
Share on other sites

Well, osC doesn't really have templating/skinning like many of the other applications and frameworks you mentioned. It has a user interface and a CSS file and that's about it. Themeroller can be used to make relatively small changes, but if you want a major overhaul, you will end up rewriting much of the user interface. To my understanding, that's what template vendors are really doing -- rewriting much of osC, or at least the user interface. Sorry, it just wasn't designed to slap new skins on. I don't know if version 3 will be easier to deal with than 2.3, which is far ahead of 2.2.

Link to comment
Share on other sites

Link to comment
Share on other sites

Bummer, but thanks for the info. That means once you've customize the appearance, you won't be able to install upgrades to the next version, right? The upgrade would wipe out all your changes and you'd have to start over. That's pretty much how it worked in an ancient version of OS commerce I once used. I was hoping by now they'd developed a more modern approach that allowed developers to customize the appearance.

 

Well, osC doesn't really have templating/skinning like many of the other applications and frameworks you mentioned. It has a user interface and a CSS file and that's about it. Themeroller can be used to make relatively small changes, but if you want a major overhaul, you will end up rewriting much of the user interface. To my understanding, that's what template vendors are really doing -- rewriting much of osC, or at least the user interface. Sorry, it just wasn't designed to slap new skins on. I don't know if version 3 will be easier to deal with than 2.3, which is far ahead of 2.2.

Link to comment
Share on other sites

If you go changing the user interface PHP code (not just the CSS files) to customize the appearance, you do run the risk that a future upgrade will want to change the same place(s) in the code and will be unable to do so. The same hazard exists with any add-on. It's just something you'll have to decide whether it's worth it in order to get the look and feel you desire. If the changes are small in number, you can document them for yourself and when it comes time to upgrade, first try the "standard" upgrade. If it fails because of your changes, back them out, do the upgrade, and manually re-insert your changes. Or, take your customized code and manually make the upgrade changes.

 

I've never seen a good, clean way to allow arbitrary code changes (at least in the user interface) while guaranteeing that upgrades will always work, at least not without a huge performance penalty.

Link to comment
Share on other sites

Sorry to butt in but I have to put my 2 cents in. It's amazing that over the years osC has yet to develop a simplified themeing solution, that many other open source projects, to include shopping carts, have had for a long time now. The only themeing that was going great, from what I recall, was STS, for those who remember. I also am still trying to figure out as to why they chose 960 grid? To me that's way to much extra nonsense code. But anyways, back to work I go.

Link to comment
Share on other sites

I've never seen a good, clean way to allow arbitrary code changes (at least in the user interface) while guaranteeing that upgrades will always work, at least not without a huge performance penalty.

 

Other CMS' get around this by providing a theme system that alleviates the need to make arbitrary code changes to the CMS itself. With systems like Drupal, Joomla, or Wordpress, all the site-specific PHP, HTML, and CSS changes are isolated in a special theme directory that is protected from being overwritten during an upgrade. It's actually a pretty standard thing these days. That's why upgrading a complex wordpress site with dozens of modules and a theme full of custom PHP is a safe and simple one-click operation. OSCommerce is the only software I've used in years that requires you to hack the core code in ways that make the site non-upgradeable just to change the appearance.

Link to comment
Share on other sites

Sorry to butt in but I have to put my 2 cents in. It's amazing that over the years osC has yet to develop a simplified themeing solution, that many other open source projects, to include shopping carts, have had for a long time now. The only themeing that was going great, from what I recall, was STS, for those who remember. I also am still trying to figure out as to why they chose 960 grid? To me that's way to much extra nonsense code. But anyways, back to work I go.

Other CMS' get around this by providing a theme system that alleviates the need to make arbitrary code changes to the CMS itself. With systems like Drupal, Joomla, or Wordpress, all the site-specific PHP, HTML, and CSS changes are isolated in a special theme directory that is protected from being overwritten during an upgrade. It's actually a pretty standard thing these days. That's why upgrading a complex wordpress site with dozens of modules and a theme full of custom PHP is a safe and simple one-click operation. OSCommerce is the only software I've used in years that requires you to hack the core code in ways that make the site non-upgradeable just to change the appearance.

 

Well if the both of of you got together and developed a template system that works with oscommerce maybe you could propose your ideas to the development team and see what they say. If it works and is good enough then maybe it could be included in the next release. As oscommerce is community based, this would be good for everyone.

REMEMBER BACKUP, BACKUP AND BACKUP

Link to comment
Share on other sites

1. Good templates change an absolute minimum of core files.

 

2. As @@14steve14 mentions - if you don't like how osCommerce is built in certain area, recode it. If you code is good enough it can be rolled into the core easily.

 

3. Wordpress is a blog and is a lot less complicated than an ecommerce shop.

 

4. 2.4 brings with it a basic but functional template system. If you want to see a 2.4 template in action go template.me.uk/penny24/

It is possible that some basic templating system might be included in a future release of the 2.3.x series

 

5. Anyone who thinks STS was a viable system is crackers.

Link to comment
Share on other sites

I probably wouldn't dig deep in, unless it was well payed or you could further edit your first template to sell to others.

No way is OSC hard to template, maybe just not as quick as blogs. With experience, an OSC site can be totally "re-skinned" within a week.

Start off with the main CSS stylesheet and compare to the actual running site frontend using Dragonfly or Firebug and see what can be styled.

Luckily very many of the tables already have their own style ids/classes and with css3 you can go a long way.

Link to comment
Share on other sites

Other CMS' get around this by providing a theme system that alleviates the need to make arbitrary code changes to the CMS itself. With systems like Drupal, Joomla, or Wordpress, all the site-specific PHP, HTML, and CSS changes are isolated in a special theme directory that is protected from being overwritten during an upgrade.

 

Well, it's possible to largely isolate the user interface/GUI (theme) from the core functions, but that doesn't mean that a future update won't want to touch the theme files. Say, you add new functionality to the core product (e.g., a new data field for admin). To use that, you would have to update the theme. You can make it so there's no harm done by failing to update a theme (use default values, etc.), but either the core developers become responsible for getting the new feature used (by obsoleting many existing themes) or users have to wait for theme developers to get around to updating their themes to add the new feature. It's a matter of shifting responsibility for updates, not perfectly isolating core from theme.

Link to comment
Share on other sites

Its still a better solution than mixing them together. As an example updating a modified oscommerce shop today requires manually editing all the updated files, if the presentation (template) was separated from the core code it would only be to upload and overwrite updated core files and then modify some of your template files if needed. This is strictly not correct, since you might have modified core files too, but should still be quite a bit faster and easier to do.

Link to comment
Share on other sites

And the problem remains that many changes to core functionality require that the template be updated to use the changes. Who is going to be responsible for keeping them in synch?

 

Agreed that core functionality and user interface (theme) should be separated as much as possible, so as to avoid unnecessary changes to one when the other one changes, but still, there's no way to absolutely isolate one from the other. Imagine a 2.3.3.4 core with a 2.2 MS1 theme! Maybe it would actually function, more or less, but every new core feature added since MS1 would be missing. Even if all the sizes, positioning, color, font, etc. are shoved off into CSS, something is still needed to output the new text or the new input field.

Link to comment
Share on other sites

GUI and core are 2 different things.

Core should be prepared for a GUI.

GUI should be able to interact with the core.

Conclusion , use a template framework and base your core to it.

In 2.4 is chosen for Bootstrap, but the core code is plain html5.

The problem is with the html5 classes used in the core.

In my opinion this shouldn't be done.Let the template add the class to the element.

For advanced usage of a template , one could build-in an Admin interface, where can decide what/when or where to use a specific class of the selected theme/template.

This list of these optional classes should be provided by the theme/template builder, by the rules of the core maker(s).

(I'm actually at a point where i investigate the cons and pro's of this dilemma)

 

There was a guy here using the TWIG template system ( i use it as well but not for Oscommerce).

At the end , this will be the required solution.To bad for what reason ever, this guy was banned from Oscommerce forum.I don't know the state of this banning, nor do i know why)

Link to comment
Share on other sites

5. Anyone who thinks STS was a viable system is crackers.

 

With all respect , yes it was.Because there wasn't any other solution available.

I can remember many topics created , when there was a user who bought a template, did not got his shop working properly , and was referred back to the template builder.

And these people where actually rejected somehow , just because they bought a template for oscommerce.

Just because oscommerce did not offered a template system.

And just because of that , some guy decided to create STS.

 

So , if not want to be rejected, not so many choices left... no?

It gave opportunity to even buy non-ready oscommerce templates and adapt these to oscommerce with the STS.

Link to comment
Share on other sites

Payed templates basically expect you have no store or basic oscommerce and can just migrate the database (or point to the current one). The problem is with addons. On the other hand, during a discussion about ecommerce solutions I recently had a look at other platforms and although some have click-to-install templates and supported addons, the number of addons is miniscule in comparison to OSC.

And my experience with WordPress payed templates is that I usually have requirements for features that are neither in the basic core, nor an existing addon, so I have to dig into the core code anyways. Thus making updates to the template a little troublesome.

Link to comment
Share on other sites

I can remember many topics created , when there was a user who bought a template, did not got his shop working properly , and was referred back to the template builder.

 

And they still will be until Template Makers stop supplying a full install of osCommerce under the name "template"...

 

Template is not a full build, it is a few changed files, not more not less.

Link to comment
Share on other sites

I have always believed that this forum is for the support to those who have downloaded a standard install of oscommerce from this site. If people install something other than an install from this site, they should have support from the site that they downloaded the files from. A lot of template makers offer no support to their free templates, and these are the ones that usually have problems.

 

Also how can someone on this support forum know and understand the code from someoene elses template. In most cases these templates are very poorly coded and are lucky to work on their own, let alone when other addons have been added. The template suppliers also very rarely update their files as the core code has been upgraded, thereby leaving people with outdated and often insecure code.

REMEMBER BACKUP, BACKUP AND BACKUP

Link to comment
Share on other sites

Hi,

 

For anyone wanting to redesign there shop I would say instead of paying a lot of money for a template make your own.

 

There is a great oscommerce design book available for about £10 which will give you the confidence and ability to redesign your own store in a matter of days easy to read easy to understand and by using the oscommerce coding standards you can be confident future updates etc.. will not be a problem.

 

You will find all the support you need for specific issues or ideas on the forum simply because we understand the coding and understand what you are talking about

 

Just have to recommend this have been designing shops now for about 10 years and still refer back to the book occasionally for some golden snippets of info.

 

The book is available from an oscommerce partner so can be found --> here

 

There is another excellent option for members who may not have the time or confidence to build there own template and that is the mini template system which can be found --> here

 

Both ways are good and with excellent support

 

Just a word of advice from my experience we should not be blinded from a beautiful work of art -- template which is often built based on the ego of the designer and not on the functionality of the shopping cart ( To look at a work of art I tend to go to a museum) :) .

 

Buyers on the web want a good quick secure cart with an Intuitive shopping experience clean and with whatever extra functionalities the individual cart needs that is the first goal a nice crisp clean design appropriate to the products being sold is the 2nd goal.

 

All this can be found here for the majority of users.

 

For someone who needs that bit more there is enough professional help available through the Commercial Support Enquiries

 

Regards

Joli

To improve is to change; to be perfect is to change often.

 

Link to comment
Share on other sites

And they still will be until Template Makers stop supplying a full install of osCommerce under the name "template"...

 

Template is not a full build, it is a few changed files, not more not less.

 

I would like to see some of these templates where there is a minimum change needed to give the same result.

It would be a good resource.

Link to comment
Share on other sites

Hi Henry,

 

Built with a inspiration from of a penny template and a good --> book depends of course on your taste not mine but well a bit different from standard

 

Have maybe about 10 x examples all with minimum change to the core but that is overkill here you set your own boundaries not OSC .

 

Here link

 

Remember please not my personal taste like it cleaner / less myself but just an example

 

Mainly just css changes took x 2 days

 

Regards

Joli

To improve is to change; to be perfect is to change often.

 

Link to comment
Share on other sites

I would like to see some of these templates where there is a minimum change needed to give the same result.

It would be a good resource.

 

Depends how you mean by "same result"...

 

Show the sort of template you like, and let's see if we can come up

with something similar with minimal core file changes.

 

Would be an interesting experiment, no?

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...