emiliano Posted February 25, 2003 Share Posted February 25, 2003 Hello everybody.. i just can't imagine why people is asking for Template Structure Implementation... i find quite simple to modify the pages layout with dreamweaver mx (great to see the code)... As the people is asking for this implementation the code team put it in the workboard http://www.oscommerce.com/community/workboard,48 in MS3... I know that from MS1 to MS3 or even MS2 many water will pass under the brigde, i think that there are many things to do before a template structure.. and i hope that this template structure is not like a cms where people(clients) could change the site preview from their browser, because this is going to create a large quantity of files that will became in a ?slower? system... may be i don't understand what a Template Structure Implementation is and i'm just saying stupids things! :D please understand that i love OSC, i help many people to get their sites live altough i'm quite new in the community... this message is not to create a problem, this is just my opinion and i want to share with the rest of the community, so don't think that i'm like "waiting" that guy who hinds behind a fake name... just my 0.02 argentinian pesos.. (about 0,00625 us dollars) sorry but as english is not my native language some parts could be difficult to understand/read. emiliano patagonia, argentina Link to comment Share on other sites More sharing options...
seCret steVe Posted February 25, 2003 Share Posted February 25, 2003 Some people in the cumminty do sites for companys and sometimes companys would like to modify things on there own....although without the knowledge and know they can screw things up. It is in the best interest ot setup a template based structur....keeping the code away from the template. But that is my personal opinion. We all have our own opinions. As well as not everyone can afford Dreamweaver MX or any other expensive editing software out there. As well not all editing software shows the format so well that Dreamweaver does. And yes dreamweaver is a great peice of software but there are those that dont have access to it. So they resort to lower means of resource. So i have asked my self this a million times as well...is it better to have a templated accessable board or to do the hard coding. And i come up with having a templated board. It would also be kewl to have a css online editor that is kind of like TopStyle from http://www.bradsoft.com Although im just one person with one idea....and maybe im saying the wrong things....but we will soon find out what the whole templating system is Not much more that i can say edit: i think that is more of what the site looks like and not as a CMS system. Actually osCommerce is a CMS system except for e-commerce. It controls the site and what is on the site so thus it is a Content Management System for E-Commerce....for short CMS-EC (sorry im just thinking of starting a new trend/phrase....lets try to implement that into the world) Link to comment Share on other sites More sharing options...
emiliano Posted February 25, 2003 Author Share Posted February 25, 2003 hi steve... i found a problem with the workboard.. until a thing it's in the "open" status it's kind of hard to imagine what "the hell" that thing is going to do because of slappy description.. osc team don't bother about this.. just keep on with this amazing thing.. as an free lance ?web designer? the whole idea of the template structure is kind of not necesary for me.. but ok.. there many things in the world that are not necesary for me.. but there still there when i open my eyes every day!!! cheers emiliano patagonia, argentina Link to comment Share on other sites More sharing options...
Harald Ponce de Leon Posted February 25, 2003 Share Posted February 25, 2003 i find quite simple to modify the pages layout with dreamweaver mx (great to see the code)... So, if you have 10 pages, you will need to make the same updates to each of the 10 pages? The template structure implementation will fix that so that only one change is required that will affect all 10 pages (parent->child relationship). , osCommerce Link to comment Share on other sites More sharing options...
Acronym B.O.Y. Posted February 25, 2003 Share Posted February 25, 2003 I think Harald got the main part. If you have the same code on 10 different files (and osC has numerous files) thats 10 different files you must hunt down and change, whereas a template system means you change it in one and it changes all of them. Say you have a heavily customized shop and you do make yet another change, but you don't have a template system. You make changes to 10 files, it looks fine on your development machine, so you upload the 10 changed files to your server only to forget that you have globals turned off on your server and now your site is broken. Now you must go and edit those 10 files (hurry, your site is down!) on your computer to compesnate (faster, your site is down, thats lost sales!) for the fact that globals is off (you are taking too long). You now need to reupload the 10 different files to 10 different locations (ftp was never this slow before, you need to move faster!) on your site and hope that things are fine wihtin 15 minutes. Now if you had a template system, all you woudl have to do is change one file in one location. That would make changes 10 times faster and efficient. Not to mention, any core functions and stuff that the osC team changes would have a lot less commits to keep track of. Instead of them having to change 10 files, they can change one and commit that one file to CVS and that's it. Also, for those who don't know PHP, it keeps the code away from them. the font page of my blog's code is as follows: <p class="postheader"> <?php the_date() ?> <?php the_time() ?> -- <?php the_title(); ?> <?php permalink_anchor(); ?> </p> <?php the_content(); ?> <?php trackback_rdf() ?> <p class="postfooter"> <a href="<?php permalink_single() ?>" title="direct link">direct link</a><br /> <a href="<?php comments_link() ?>" title="comments">c</a> (<?php comments_number() ?>) <a href="<?php trackback_link() ?>" title="trackbacks">t</a> (<?php trackback_number() ?>) <a href="<?php pingback_link() ?>" title="pingbacks">p</a> (<?php trackback_number() ?>) </p> <?php include("b2comments.php") ?> <?php include("b2trackback.php") ?> <?php include("b2pingbacks.php") ?> Why? Becuase I use b2, its so simple, some who doesn't even know HTML can figure out how to edit things. Of course those who know html and php very well can go and change the functions themselves as well as create their own (take a look at the much improved archives "hack" by dodo). tbannist points out this fact as well: Lets say I already have a functioning order system, complete with logs and admin panel. I want to integrate osCommerce into my exisitng system, so that I can suplement my other sales software with a catalog of items. Now, instead of editing one database interface file, I have to edit every file that references every table I already have. Paul_C mentioned Smarty as a possible solution. Link to comment Share on other sites More sharing options...
Acronym B.O.Y. Posted February 25, 2003 Share Posted February 25, 2003 I forgot one other thing. Modularity. The more modular software becomes, the easier it becomes to drop in or out certain functions. Hopefully all contributions will become modular in this fashion, allowing for automated installation of mods. Certain open source projects have already achieved this. Link to comment Share on other sites More sharing options...
mattice Posted February 25, 2003 Share Posted February 25, 2003 Paul_C mentioned Smarty as a possible solution. Smarty (or any other template ENGINE) is not a good solution IMHO. The idea is to get the HTML seperated from the PHP, not to force users to learn a completely new 'language" (as Smarty does). Mattice "Politics is the art of preventing people from taking part in affairs which properly concern them" Link to comment Share on other sites More sharing options...
Acronym B.O.Y. Posted February 25, 2003 Share Posted February 25, 2003 I agree, Smarty does force someone to learn a new language. I still think a b2 (cafelog) -like solution is best. But a template engine would be a very nice thing to have. Link to comment Share on other sites More sharing options...
Harald Ponce de Leon Posted February 25, 2003 Share Posted February 25, 2003 Why? Becuase I use b2, its so simple, some who doesn't even know HTML can figure out how to edit things. I don't like that system of doing things (from your posted example) - I believe functions should return data instead of echoing them out directly. The new checkout procedure updates to the shipping/payment/order total modules changed a few functions of returning only raw data, not html mixed with data. ..but, there is more than one way to skin a cat ;) , osCommerce Link to comment Share on other sites More sharing options...
Harald Ponce de Leon Posted February 25, 2003 Share Posted February 25, 2003 Smarty (or any other template ENGINE) is not a good solution IMHO.The idea is to get the HTML seperated from the PHP, not to force users to learn a completely new 'language" (as Smarty does). Right - internally we've talked about implementing a basic template engine for the emails/newsletters, which can later be further enhanced to deal with loops and, something I find important, caching (compiling php pages) to be implemented throughout the catalog. , osCommerce Link to comment Share on other sites More sharing options...
seCret steVe Posted February 25, 2003 Share Posted February 25, 2003 the system should be separted from php and html....i think it would best that way Link to comment Share on other sites More sharing options...
emiliano Posted February 25, 2003 Author Share Posted February 25, 2003 i get the point.. :D altough as i said before I found quite simple to edit osc layout.. (hey that's a pro not a con...) cheers emiliano patagonia, argentina Link to comment Share on other sites More sharing options...
Guest Posted February 26, 2003 Share Posted February 26, 2003 i get the point.. :D altough as i said before I found quite simple to edit osc layout.. (hey that's a pro not a con...) cheers emiliano but how much are you editing it.... some of us are like to totally edit the layout of the site, which would mean changes to the code in index.php and allt he other different page files. how much fun do you think it is to make the same changes across 10-20 different files? not very. that's why I love to use PHP for my websites so much.... because using includes, I only have to make 1 layout file, then just include (kind of like importing or loading) a different body for each page. So if I wanted to change something on my website, I change 1 file, rather than 20. I personally am looking forward to a template system, because I am just getting started with setting up OSC and am not really looking forward to editing all those files (even for as simple a change as the table width... :roll: ) :( . Link to comment Share on other sites More sharing options...
emiliano Posted February 26, 2003 Author Share Posted February 26, 2003 as soon as i get a server to test my site you could see it and then you could say if my site is modified or not.. cheers emiliano ps: now i'm getting a litlle desesperate to get the template structure implementation! patagonia, argentina Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.