Dolphin 7 templates system

MichelSwiss posted 26th of May 2009 in Community Voice. 12 comments.
I was hoping that Dolphin 7 will allow to make a custom template (or to edit the tmpl_uni) more easily than now.
But it seems like it will be a templates folder (even with base and uni subfolders) in each of the numerous modules folders...
Is that not possible to suppress the templates/base folder and to regroup all these modules/templates inside the templates/tmpl_uni/modules ???
 
I understand that each module has to be independent... But IMHO I think that a wrong choice was done.
I think that it will much better to put together all these templates files in the same template folder (no base folder any more):
 
    templates (folder)
            tmpl_uni (folder)
                    css (folder)
                    images (folder)
                    modules (folder)
                            boonex (folder)
                                    ads (folder)
                                            css (folder)
                                    avatar (folder)
                                            css (folder)
                                            images (folder)
                                            avatars_my.html (file)
                                            avatars_site.html (file)
                                            ...
                                    ...               
                    scripts (folder)
                   ...
 
 
The choice is simple:
 
1) the module is splitted in only 2 folders (module itself + module template that will be added in templates/tmpl_xxx/modules/xxx/)
 
or
2) the template is splitted and scattered in as much as 30, 40 or even 50 folders...
 
As for me, I prefere the first option :-)
 
Comments
·Oldest
·Top
Please login to post a comment.
mastermindsro
yes indeed you are right but as aramis said in the forums

http://www.boonex.com/unity/forums/#topic/No-more-base-directory-will-be-nice-.htm

it would be a mistake to make css's for every single module.. the standard style of the template should be applied to the modules which don't have any custom style..

.css files are MADE to customize hundreds of pages on the same time, so it will be ilogical for each module to have it's own css file.. you're right.. but I have an idea..

IDEA: it will see more be nice if somehow (i don't have too much php knowledge) if you add let's say


.SOME-SPECIFIC-PREFIX_custom_module_name

{

...

}

"custom_module_name" will be identical with the module directory name, so if you add that entry in the general style sheet than that module will have the settings you set there.. so we have the possibility to edit each module alone without the need to modify any code outside the template folder.. adding styles dynamical when we add some new modules custom styled from the rest.. if you don't add any custom style to that module than a standard/general style of the template should be applied..
MichelSwiss
The standard style of the template will be applied to the modules, no problem here.
To adjust the content of each module, some files (CSS, Images, as well as other file types...) are indisputably needed.

IMHO the problem is that all the templates files have to be regrouped in a unique template folder and not to be scattered in dozens of different folders...
mastermindsro
yeah you are right my idea was strictly about the style part of modules.. in case you want to edit module's structure (adding images and stuff) we should edit the module from the module directory..
style should be separated from module content..
i agree we need to make it as customizable as possible but we must find a way to separate module content from it's style..
TheSoMeEx
I have to say that Joomla does this very nicely. Now, I hate to be one to call out another CMS as an example ("Well, if you were just more like..." is not my intention). They have their drawbacks, and learning from their strengths is a good thing.

Every piece of Dolphin code, every module, every add-on should have two parts. The part that gets installed in the directory where it needs to be to function as a part of Dolphin, and the part that gets dropped into /templates/[active-template-directory]/module-name.css.

Even see more Joomla does not force these standards, causing a lot of cleaning up on CSS code whenever a new module is installed, either because of css files being spread all over or because of inline (throws up a bit in the back of my throat) styling added into the code itself, rather than a standalone CSS sheet. *cries*

To make it two-part like this as a standard would allow some pretty amazing things, design-wise, and be amazing for Dolphin, IMHO.
MichelSwiss
Thank you TheSoMeEx :-) I see that you well understood that I tried to explain with my poor basic english :-))

Hope that BoonEx will consider our point of view...
MichelSwiss
Honestly, I think that the first thing that will do a Dolphin site owner is to customize his site's look (the only thing that many of BoonEx "customers" will ever do)....



To split a module in 2 folders, one for the functionality and another one for the template, will be very easy to do for a developer.

Having to search and edit dozens of template files will be very difficult for most of site owners who will just customize his/her site...



I think that this is a very good see more idea to regroup all the files of a functionality in a module folder. Why this same idea (to regroup all styles files in a template folder ) will be wrong for the template ???

If it were some technical problem this will be a good reason... but there is none... at least none that I can see...



I call such things BoonEx syndrome: flying to high, searching to far... when the best solution is just under the shoes :-))
AlexT
Very good suggestion. It is worth to discuss it.

Both implementations 1) like you offered and 2) current dolphin 7 implementation have some pros and cons.

Your suggestion is good for template maintainer only. It is not easy to develop templates in this case but only maintain it.

During template development process designer do not know which modules are installed and can not include css, images etc files for modules.

Maintain is a little bit easier, because path among templates directories see more are shorter:
/templates/tmpl_uni/modules/vendor/some_name/css/some.css
vs
/modules/vendor/some_name/templates/tmpl_uni/css/some.css
But you still have to go to different directories to change different css and other files.

But it will make modules development, installation, uninstallation, support, upgrade and so on more complex and difficult. Site owner will have more work too - remove, upload files to different directories every time a little module is installed/removed.

Another thing - main templates files, like header/footer, design boxes and many more standard design elements are still in common template directory, and in 95% cases you do not need to go to far module template directory. Before Dolphin 7 all these html code were located in raw php files and nobody changed it, now it is separated and places into different directory, it is more convenient than before IMHO.

As the summary, this choice will allow easier module development, installation, uninstallations and upgrade procedures. Also I am sure that you as a site maintainer will benefit from it too, as you have many modules and only one template.
MichelSwiss
Hello Alex :-)

Thank you for your answer ;-)

I don't want you to spend too much time with this topic... If only me, I can live with that ;-)
Just one thing. You are right in that I had to choose to use only one template. Because if I have for example a white template and a black one, I will have problems with images, icons, zodiac icons..., that are in common (templates/base) for all templates and that will not match every templates colors... (I changed all these images and icons with PNG24 see more icons that have much cleaner borders than .gif)

At least maybe can you merge templates/base and templates/tmpl_uni ???, for the modules too ???

Thanks again Alex ;-)
TheSoMeEx
Hi Alex! You make some very valid points.

You said:

"During template development process designer do not know which modules are installed and can not include css, images etc files for modules."

That is true. My point is that by using CSS standards for module design and creation, and by offering a separate CSS file to install into the templates directory, then the same problem that is currently (every module has it's own CSS parameters and needs, etc.) will be MORE EASILY solved, see more because the CSS will be in exactly the place it needs to be to find it and modify it.

In addition, with such standards, it would also be easy to note in the CSS code which pieces of the CSS are "new to dolphin," instead of inherited. This could make it very easy for moderate newbies even to change their code.

For example, a new module has a certain type of image for background. This would be noted in the CSS, and it could be changed or not, based on the template maintainer's desire.

You said:

"But it will make modules development, installation, uninstallation, support, upgrade and so on more complex and difficult. Site owner will have more work too - remove, upload files to different directories every time a little module is installed/removed."

Ahhh, one small upload into the CSS directory? Not such a difficult addition, IMO. 10 seconds, tops. Small price to pay for knowing where all of the non-code design changes reside.

As far as Dolphin 7, I cannot speak to that or it's ease. I know that if I continue with Dolphin, I will find a way to style it to my liking. I always have, LOL!

I just read what others have said, and the code in the templates I have looked at, and I see an extreme lack of flexibility in layout and design that will hold Dolphin back. If this software truly does get huge, it will be a problem with people having sites that look (essentially) like everyone else's.

Thanks for making me think this early in the AM! *smiles8
Diddy
Yep, I like the idea since I really like to design layouts :-)
ydrargyros
This new templating system really makes it pretty dificult for me to design new better templates... still haven't figured out how to override the html files!
Work must be done on the new Dolphin till every little presentation bit resides inside a single (if applicable) template file!
amtalex
Jomsocial has a mod installer that does all the work for you maybe dolphin should look into this......
 
 
Below is the legacy version of the Boonex site, maintained for Dolphin.Pro 7.x support.
The new Dolphin solution is powered by UNA Community Management System.
PET:0.073154926300049