Page 1 of 1

Override-Templates

Posted: 20 Apr 2010, 11:09
by enigmartin
Hi,

I have always problems with overrides the Phoca Gallery.
The templates for the output are very confusing and it is always difficult because what suit their needs.

Why are there so many <center> and <div> or in other templates once <fieldset>.

This can be simplified yet so it's much easier at the end by Joomla overrides not to overwrite or so.

I've attached 2 examples that implement this as simple as possible.
There, the individual items with ltr or rtl be realized with float.
Columns can then wrap with clear.
For example, if 3 columns are needed after every 3rd Element <div class=""phoca-clear> </ div> spent.

Forgive me the bad english, it was translated with Google Translate

Examples: http://www.genesis-nova.de/files/items.zip

Re: Override-Templates

Posted: 22 Apr 2010, 22:58
by Jan
Hi, in Phoca Gallery version 2.7.0 some center tags were removed. But some not, because of IE browsers - sometimes e.g. horizontal and vertical centering doesn't work (in IE browsers) so hacks for such browsers needs to be done. Phoca Gallery should be displayed for people (important for SEO) this is why some code is difficult - it is because the output should be the same in all used browsers.

Anyway thank you for the files.

Jan

Re: Override-Templates

Posted: 27 Apr 2010, 13:27
by enigmartin
Why do you use the vertical align?
If you have an image with a specific width and height, you can give them an padding or margin.

The vertical align works only in table-cells, there you can use display: table-cell and them give them vertical-align: middle and text-align: center.
If you need a div center, you can give them margin: 0 auto, for ie6 you can give the parent element text-align: center and you must give the child text-align: left, so the text is aligned left or you let it center.

Do you know waht I mean.

If i have any time, can I look at the new code, modify it and send it to you. Wich Browsers do you conside?
I have IE6, IE7, IE8, Firefox, Safari and Opera to test Pages.

Sorry for my english. Do you speak a little bit german?

Re: Override-Templates

Posted: 27 Apr 2010, 22:51
by Jan
Hi, vertical align styling doesn't work in some of the IE browsers, this is why this must be hacked.

The vertical align and horizontal align is used (very very complicated system to work in most used browser so it will work in all IEs and will not cause any other problem in standard browsers)

Because of the following features:

- images can have different size (vertical, horizontal - can be easily set in parameters)
- background shadow can be different size ( + different margin, padding to images)
- no table desing is used but float boxes are used, etc.

the vertical centering needs to be used.

Jan