Page 1 of 1

Left and right margins

Posted: 19 Feb 2010, 12:00
by Amrit
First of all, thank you Jan for creating Phoca. :)

Now, what I wonder.

I have lets say one gallery with 4 images in each row and another gallery with 6 images in each row.

In my design, I need the images to fill the space on each row, but as far as I can see, I can't set left and right margins on the first and last image of each row.
I'm not even shure the images are constructed in rows, because the rendered code seems to me like the images are layed out in a floating way, so that each row is simply just filled.
Is there a way of setting amount of images in each row and then to set the left and right margin of first and last image?

I don't know of anyone else needs this feature, but I do. :)

Thanks for any answer.

Cheers
Amrit

Re: Left and right margins

Posted: 22 Feb 2010, 20:04
by Jan
Hi, yes, the boxes are float boxes, search this forum, there are different guides to change it.

E.g. you can set fixed width in parameters and set centering for the box, or change css to left or right, etc.
(fixed width / width of boxes = number of displayed boxes in row)

Jan

https://www.phoca.cz/documents/2-phoca-g ... -menu-item

Re: Left and right margins

Posted: 23 Feb 2010, 17:29
by Amrit
Hi Jan.

Yes, I know all the things you wrote, and they are quite useful for doing layouts.

But what I need is, if possible, to have each row generate code like this:

-------------------------------------
|img1| |img2| |img3| |img4|
-------------------------------------
Image 1 = left-margin: 0;
Image 2 & 3 = centered, (margin: 0 5px;
Image 4 = right-margin 0;

At times I need the whole gallery to strech over the whole page, and to fit it in my design I need to be, if possible, to set the margins o the first and last image of each row.

If it can't be done it can't and that ok.
Mostly asking because I want to know if it is possible or not.

Thanks again for your hard work.
Amrit

Re: Left and right margins

Posted: 26 Feb 2010, 14:08
by Jan
Hi, no, such needs to be customized in the php code (and will be difficult) the better way is to "play" with margin, padding of boxes, with size of images, etc. so you can exactly then set the number of images displayed on the row.

Jan