The Joomla! Forum ™



Forum rules


Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.



Post new topic Reply to topic  [ 4 posts ] 
Author Message
 Post subject: Sigplus custom CSS
PostPosted: Mon Apr 23, 2012 9:25 am 
User avatar
Joomla! Explorer
Joomla! Explorer

Joined: Wed Jan 02, 2008 12:38 am
Posts: 268
I'm quite happy with Sigplus, but have a problem: how to align it with my own css.
I need one column with images left of the text, and one to the right of the text. By default, I can either align the plugin left or right. But not both at the same time. It's either or. That goes for just about any other similar gallery plugin.

Is there any way to this?


Top
 Profile  
 
 Post subject: Re: Sigplus custom CSS
PostPosted: Sat Apr 28, 2012 4:13 pm 
Joomla! Enthusiast
Joomla! Enthusiast

Joined: Tue Apr 13, 2010 8:59 am
Posts: 153
I am afraid this question has little to do with sigplus per se. It must be my fault but I have difficulty imagining how to align anything both to the left and the right at the same time; any object can be anchored to the left or to the right of a container element, or perhaps to some position in between, but definitely not both left and right. You might also want to look into how the CSS properties float and clear work, in case you want one element left-aligned and another element right-aligned in the vicinity of each other (approximately the same "line"). You might also want to look into absolute positioning in CSS.


Top
 Profile  
 
 Post subject: Re: Sigplus custom CSS
PostPosted: Sat Apr 28, 2012 11:41 pm 
User avatar
Joomla! Explorer
Joomla! Explorer

Joined: Wed Jan 02, 2008 12:38 am
Posts: 268
It's quite easy to do with css. You create a left column or a float left element, and likewise a right column or a float right element. My problem is that this doesn't seem to work in sigplus. It ignores any other css than its own. {gallery} isn't valid css, so I can't create something like {gallery class="left_float"}.

I hope others have a solution for this.


Top
 Profile  
 
 Post subject: Re: Sigplus custom CSS
PostPosted: Sun Apr 29, 2012 8:00 am 
Joomla! Enthusiast
Joomla! Enthusiast

Joined: Tue Apr 13, 2010 8:59 am
Posts: 153
I am sure you have already considered this but in case not, take into account that sigplus CSS rules are marked as !important, giving these rules much higher precedence than normal rules:
Code:
div.sigplus-gallery ul > li {
margin:0 !important;
border:0 none transparent !important;
padding:0 !important;
}
The reason for high precedence is because many templates have rules of their own that would interfere with sigplus (e.g. formatting rules for lists, spacing, etc.), and often these rules have an article or page section identifier in them, e.g.
Code:
#myid .blog
elevating rule precedence. Since most sigplus rules are not specific to a particular gallery and sigplus cannot know in advance what #myid the template will employ, the only way to enforce precedence over template rules is to use !important. The downside is that custom rules you introduce must not only have relatively higher precedence but also employ !important to be considered.

In addition, sigplus galleries are always annotated with the class
Code:
sigplus-gallery
and sigplus galleries that are left-aligned and float have
Code:
sigplus-gallery sigplus-left sigplus-float
You might want to attach additional CSS content to these rules if you are intent on changing their appearance. Moreover, the attribute id lets you assign a unique identifier to the gallery, again easing reference to a particular one. True, sigplus 1.3.x/1.4.x does not support the attribute class in the activation tag.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 



Who is online

Users browsing this forum: No registered users and 7 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group