detail-view pictures are not in the centre

Phoca Gallery - image gallery extension
kloiner
Phoca Newbie
Phoca Newbie
Posts: 3
Joined: 17 Aug 2010, 13:06

detail-view pictures are not in the centre

Post by kloiner »

Hi all,

I just installed phoca gallery on a joomla-installation.

Everything worked fine, I just have one problem. The pictures in the detail-view are not in the centre. It seems to be aligned on the left side.

I already searched the internet, but I couldn't find any useful answer. I know it is something with my template and I have to to some changement with align:centre. I only don't know where to do it in my template.

My internet-site: www.kleinkindgruppe-zwergenstuebchen.de it is for a day-care!

Thanks for you support.

Kind regards
kloiner
webansvarlig
Phoca Enthusiast
Phoca Enthusiast
Posts: 53
Joined: 01 Feb 2008, 03:09

Re: detail-view pictures are not in the centre

Post by webansvarlig »

Hello! I tried your site. It seem to work allright. When clicking on a photo in expands to center.
kloiner
Phoca Newbie
Phoca Newbie
Posts: 3
Joined: 17 Aug 2010, 13:06

Re: detail-view pictures are not in the centre

Post by kloiner »

Hello webansvarlig,

thanks for your fast response.

But this is crazy, I just tried to open my site under firefox, IE7 and under Safari (Mac OS) but in each browser the pictures (in detailview) are on the left side.

Please try again. Go on my site www.kleinkindgruppezwergenstuebchen.de and oben "Fotogaleri". There you will see three categories, just take one and open one picture.

Thank you for your support.

Kind regards

kloiner
imperialWicket
Phoca Enthusiast
Phoca Enthusiast
Posts: 78
Joined: 28 Feb 2010, 15:39

Re: detail-view pictures are not in the centre

Post by imperialWicket »

It looks like your template is styling all td, tr elements with text-align left. Remove that from your template.css file and these should be centered. If this change causes undesirable results elsewhere, some more in-depth css troubleshooting is necessary.
carsten888
Phoca Member
Phoca Member
Posts: 35
Joined: 22 Oct 2008, 12:11
Location: Tilburg, Holland
Contact:

Re: detail-view pictures are not in the centre

Post by carsten888 »

same problem here. Just want the image in de detailed window centered.

template.css line 20

Code: Select all

caption, th, td {
font-weight:normal;
text-align:left;
}
so I tried to override that with css:

Code: Select all

body #phocagallery table tr td{
	text-align: center;
} 
but that does not work! I'm flabegasted, because this should really do the trick. I checked the css is loaded, and it is loaded last (which should override the previous css).

Code: Select all

td{
	text-align: center;
} 
even this does not even show up in Firebug. The css in the stylesheet does, so it is loaded correctly for sure, but when clicking on 'inspect element' in Firebug the styles for the body are loaded, but not for that td. Driving me nuts!

I suspect that maybe the output is recreated with javascript.
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49297
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: detail-view pictures are not in the centre

Post by Jan »

Hi, in Phoca Gallery the pure Phoca Gallery code is not created by javascript ... maybe some other code (template or extension)

try to use other methods, like adding attribute to td (td align="center") but I think this will not help, can I see the site where this occurs.

Mostly e.g. switching off some of loaded template or javascript with help of firefox web development toolbar or other methods (firebug) can display which part can be in conflict.

Jan
If you find Phoca extensions useful, please support the project
carsten888
Phoca Member
Phoca Member
Posts: 35
Joined: 22 Oct 2008, 12:11
Location: Tilburg, Holland
Contact:

Re: detail-view pictures are not in the centre

Post by carsten888 »

td align="center"
thats already there.

after a loooong struggle I got a fix:

in template/system/css/template.css
add

Code: Select all

#phocagallery table #image-box{
	margin: 0 auto;
}
this code can also be added to the elements style properties in the template. (maybe include that in a next release?)
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49297
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: detail-view pictures are not in the centre

Post by Jan »

Ok, thank for this info, I will add it into the next release.

Jan
If you find Phoca extensions useful, please support the project
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49297
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: detail-view pictures are not in the centre

Post by Jan »

Added into PhocaGallery 2.7.5 into phocagallery.css file.

Jan
If you find Phoca extensions useful, please support the project
carsten888
Phoca Member
Phoca Member
Posts: 35
Joined: 22 Oct 2008, 12:11
Location: Tilburg, Holland
Contact:

Re: detail-view pictures are not in the centre

Post by carsten888 »

Added into PhocaGallery 2.7.5 into phocagallery.css file.
did you double check if it works when that code is there. On my site the template.css is loaded AFTER the phocagallery.css, which will override it. So best to add this in the style property of the div#image-box in the actual element.
Post Reply