[Solved] placement of module - I've tried everything!

Phoca Gallery modules - modules for Phoca Gallery extension
jmrcrp
Phoca Newbie
Phoca Newbie
Posts: 6
Joined: 14 Mar 2010, 02:02

[Solved] placement of module - I've tried everything!

Post by jmrcrp »

I'm sorry to bother you, Jan, I know you get this question a lot. But I just can't seem to find the solution. Here is what the module looks like:

Image

As you can see, the module above it is aligned correctly, but the Phoca Random Image Module is too far to the left. It's not just that the picture itself is in the wrong place, the entire module is wrong.

I have tried several ways to edit the .css of my site template, but nothing worked. I used Firebug to find the exact code for the module, and it says it is

Code: Select all

<div style="height: 158px; width: 120px; float: left;" class="phocagallery-box-file">
So I opened the file mod_phocagallery_image/assets/phocagallery_module_image.css and found what I thought was the correct section, lines 14-24:

Code: Select all

#phocagallery-module-ri .phocagallery-box-file {
	position:relative;
	width:120px;
	height:140px;
	border:1px solid #E8E8E8;
	padding:5px;
	background:#fcfcfc;
	margin:5px;
	text-align:center;
	overflow:visible;
}
I tried adding a line "float:right;" under the "position" line, but that did not help.

I have tried to edit the .css of my site template, but that didn't help, either. The lines in the template.css file that seem to control this are:

Code: Select all

#leftcolumn ,#rightcolumn {
	margin: 0;
	width: 200px;
	float: left;
	padding: 0 0 10px 0;
	text-align: left;
}
but when I tried to change that to "float: right;" it moved the entire left column over to the right side of the page.

What I don't understand is why the one module shows up correctly (the one above the Phoca Gallery module) but this one doesn't.

I hope you or someone can help me. I'm not very good at editing .css since I don't really understand it very well. I just try changing one thing at a time and see what it does.

One more thing, I'm sorry to say that I did try it using one of the default Joomla templates, and it shows up correctly there. So I guess the problem is in my template. I just don't know where to change it so that your module displays correctly.

Thanks for your time. I love Phoca Gallery and I appreciate all that you do.
Last edited by jmrcrp on 06 Apr 2010, 18:44, edited 1 time in total.
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48402
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: placement of module - I've tried everything!

Post by Jan »

Hi, it is a big problem, for now you need to try remove/add code in your template css - step by step to remove different blocks of css and find the piece of code which is in conflict with the module position. I think there is no other way like this (or changing the template :-( )

Jan
If you find Phoca extensions useful, please support the project
jmrcrp
Phoca Newbie
Phoca Newbie
Posts: 6
Joined: 14 Mar 2010, 02:02

Re: placement of module - I've tried everything!

Post by jmrcrp »

Thank you for the reply, Jan. I will attempt to play around with the site template and hope I find something that works. If I do, I'll post it here. I really don't want to change to a different template, as this one is perfect for this site.

One idea I thought of - if I separate out the "left" and "right" sections of my site template CSS, and make each one a separate set of code, then I could set it so the "right" section is "float: right" couldn't I?

Thanks again. :)
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48402
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: placement of module - I've tried everything!

Post by Jan »

Hi, I think the problem will be e.g. in width not in the float :-( :idea:
If you find Phoca extensions useful, please support the project
jmrcrp
Phoca Newbie
Phoca Newbie
Posts: 6
Joined: 14 Mar 2010, 02:02

Re: placement of module - I've tried everything!

Post by jmrcrp »

With some help from the tech support at SiteGround (where the template came from) I was able to solve the problem. In the file - modules/mod_phocagallery_image/assets/phocagallery_module_image.css lines 8-15:

Code: Select all

#phocagallery-module-ri{
	    position:relative;
		float:right;
		padding-right:100px;
	text-align:right;
	margin-left: auto;
	margin-right: auto;
}


I changed line 11 to "padding-right:0px;" and now the module is centered.

I hope this helps anyone else who might be having this problem. :)
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48402
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: [Solved] placement of module - I've tried everything!

Post by Jan »

Great to hear it, thank you for this info.

Jan
If you find Phoca extensions useful, please support the project
Post Reply