Centering modules

202 views
Skip to first unread message

hkgsg9

unread,
Dec 26, 2012, 9:14:34 PM12/26/12
to gantry-framework...@googlegroups.com
I am wondering if anyone here would know how to center a module in "content-top-a".
every time I place a in there it always goes to the left side of the page.

Thanks

Grant Preston

unread,
Dec 27, 2012, 5:24:27 AM12/27/12
to gantry-framework...@googlegroups.com
You should always include more info when seeking help.

How many modules do you have published in content-top positions? Are you using a custom HTML module and does the content fill all of the content-top positions? If you are using a custom HTML module you may want to try wrapping the content in a div tag like so:

<div style="margin-right: auto; margin-left: auto;">
Your content
</div>

If the module is not a custom HTML module you can create the CSS in your template-custom.css file by adding your own class...

.custom-center {margin-right: auto; margin-left: auto;}

and then call that class in the module's module class suffix box found in the advance panel on the right of your module...

custom-center

Hopefully that helps. Keep in mind that the content-top positions are glued to your main body section and do not extend over the sidebars. The main-top positions would be used if you wanted to extend across sidebars.

Next time you have an issue please provide all possible relevant information. Including a link to site or screen shot of issue and describe in full detail what you are expecting to happen.

Best,

Grant
--
You received this message because you are subscribed to the Google
Groups "Gantry Framework for Joomla Users" group.
To post to this group, send email to
gantry-framework...@googlegroups.com
To unsubscribe from this group, send email to
gantry-framework-for-j...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/gantry-framework-for-joomla-users?hl=en
 
Gantry Framework Homepage: http://www.gantry-framework.org

Nikola Hamwi

unread,
Dec 27, 2012, 6:25:29 AM12/27/12
to gantry-framework...@googlegroups.com
Turn-on the "fixed position" feature in the layout settings in Gantry, and then put you module in the desired position (it'll take that position even if the modules on the left do not exist)

Take a look at the bottom of this page:

Regards,

Grant Preston

unread,
Dec 27, 2012, 8:29:36 AM12/27/12
to gantry-framework...@googlegroups.com
I think your talking about Force Positions under the Layouts tab NOT Fixed Position which could be confusing since there is a Fixed under Advanced.


--

Devine

unread,
Mar 12, 2013, 9:47:46 AM3/12/13
to gantry-framework...@googlegroups.com
Hello,

i have similar problem. I created new module position with this tutorial and named it "extra1". Everything is working fine instead i can't get this module in the center of the page like other default module positions are. As you can see from my scrshoot1.png, i made two identical modules and put it in different positions ( upper is "Utility-a" and bottom is "Extra1-a"). Both modules have the same layout settings as you can see from scrshoot2.png. 

 Is there any code that i missed and i also need to put somewhere?


Tnx for help, A



On Thursday, December 27, 2012 11:24:27 AM UTC+1, WebTread wrote:
You should always include more info when seeking help.

How many modules do you have published in content-top positions? Are you using a custom HTML module and does the content fill all of the content-top positions? If you are using a custom HTML module you may want to try wrapping the content in a div tag like so:

<div style="margin-right: auto; margin-left: auto;">
Your content
</div>

If the module is not a custom HTML module you can create the CSS in your template-custom.css file by adding your own class...

.custom-center {margin-right: auto; margin-left: auto;}

and then call that class in the module's module class suffix box found in the advance panel on the right of your module...

custom-center

Hopefully that helps. Keep in mind that the content-top positions are glued to your main body section and do not extend over the sidebars. The main-top positions would be used if you wanted to extend across sidebars.

Next time you have an issue please provide all possible relevant information. Including a link to site or screen shot of issue and describe in full detail what you are expecting to happen.

Best,

Grant

On Dec 26, 2012, at 7:14 PM, hkgsg9 <hkg...@gmail.com> wrote:

I am wondering if anyone here would know how to center a module in "content-top-a".
every time I place a in there it always goes to the left side of the page.

Thanks

--
You received this message because you are subscribed to the Google
Groups "Gantry Framework for Joomla Users" group.
To post to this group, send email to

To unsubscribe from this group, send email to
scrshoot1.png
scrshoot2.png

Grant Preston

unread,
Mar 12, 2013, 6:56:53 PM3/12/13
to gantry-framework...@googlegroups.com
First of all you don't need to Force Position in your situation so I would set those to off. Both modules should automatically be in the center unless they have some code in them that is floating them to the left.

In the lower module you might try wrapping the content with something like this <div style="text-align: center;">Your Content</div> If that doesn't work then try changing that div set up to the basic <center>Your Content</center>

If neither of those work I'd have to actually see what is going on as to why you have an issue.


--
--
You received this message because you are subscribed to the Google
Groups "Gantry Framework for Joomla Users" group.
To post to this group, send email to

To unsubscribe from this group, send email to

For more options, visit this group at
http://groups.google.com/group/gantry-framework-for-joomla-users?hl=en
 
Gantry Framework Homepage: http://www.gantry-framework.org
 
---
You received this message because you are subscribed to the Google Groups "Gantry Framework for Joomla Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gantry-framework-for-j...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Reply all
Reply to author
Forward
0 new messages