Hello all,
We're having a little trouble with our (minor) CSS modifications of the default Monobook skin. The goal is to reduce the page's size to 90% and center it horizontally (so there's a small margin or gap on each side).
While this works fine in Firefox, we just can't get it to work in IE6; the sidebar is stuck at the window's left side, and the tabs at the top are misaligned as well.
Speaking of tabs: There's a tiny (1px) gap between inactive tabs and the content area in IE (in the default skin, not related to our modifications), which becomes very visible when changing the page's background color. Unfortunately, we have not been able to fix this either.
Does anyone have some experience with such issues? I'd greatly appreciate some tips!
Thanks,
F.
Have you checked the IE-only CSS files? They could be overriding some of your modifications.
Frederik Dohr a écrit :
Hello all,
We're having a little trouble with our (minor) CSS modifications of the default Monobook skin. The goal is to reduce the page's size to 90% and center it horizontally (so there's a small margin or gap on each side).
for the 90% : in main.css change this :
/* scale back up to a sane default */ #globalWrapper { font-size: 127%; width: 90%; margin: 0 auto; padding: 0; }
for the tabs : in monobook.php, add a wrapper <div id="p-cactions-wrapper"> inside p-cactions (and its </div> at the end)
<div id="p-cactions" class="portlet"> <div id="p-cactions-wrapper"> <h5><?php $this->msg('views') ?></h5> <div class="pBody"> <ul> <?php foreach($this->data['content_actions'] as $key => $tab) { ?> <li id="ca-<?php echo Sanitizer::escapeId($key) ?>"<?php if($tab['class']) { ?> class="<?php echo htmlspecialchars($tab['class']) ?>"<?php } ?>><a href="<?php echo htmlspecialchars($tab['href']) ?>"<?php echo $skin->tooltipAndAccesskey('ca-'.$key) ?>><?php echo htmlspecialchars($tab['text']) ?></a></li> <?php } ?> </ul> </div> </div> </div>
then in main.css
#p-cactions { position: absolute; top: 1.3em; /*left: 11.5em;*/ margin: 0 auto;/*auto is for left-right centering*/ white-space: nowrap; width: 90%;/*76%;*/ line-height: 1.1em; overflow: visible; background: none; border-collapse: collapse; padding-left: 0;/*1em;*/ list-style: none; font-size: 95%; }
and
#p-cactions-wrapper { margin-left: 12.2em; }
you'll have to do the same for the logo and the personnal tools blocks, moreover there might be a cleaner way to do this (without changing php code)
While this works fine in Firefox, we just can't get it to work in IE6; the sidebar is stuck at the window's left side, and the tabs at the top are misaligned as well.
Speaking of tabs: There's a tiny (1px) gap between inactive tabs and the content area in IE (in the default skin, not related to our modifications), which becomes very visible when changing the page's background color. Unfortunately, we have not been able to fix this either.
Does anyone have some experience with such issues?
Yes
I'd greatly appreciate some tips!
I think (it was months ago) I had to change the skins/monobook/IE##Fixes.css file for each version ## of IE (at least for the 1px issue : it's because IE doesn't understand margin and padding properties the same way as other browsers do)
using those dedicated css, you can correct all IE bugs
e.g. for IE60Fixes.css : change
#p-cactions li a { display: inline-block !important; vertical-align: top; padding-bottom: 1px;//this is the pixel you were missing border: solid #aaa; border-width: 1px 1px 0; }
#p-cactions li.selected a { border-color: #fabd23; padding-bottom: 0.17em !important;//!important is to ignore (for the selected tab) the pixel you added above }
Thanks for the quick responses!
Have you checked the IE-only CSS files? They could be overriding some of your modifications.
I hadn't before, but have looked into that now; that proves to be quite tricky though... (Simply increasing CSS specificity didn't help, unfortunately.)
for the 90% : in main.css change this :
/* scale back up to a sane default */ #globalWrapper { font-size: 127%; width: 90%; margin: 0 auto; padding: 0; }
That's what I'd done before (except for the padding and font-size).
for the tabs : in monobook.php [...]
I was afraid that I might have to hack the skin... But this looks interesting; I'll give it a try!
there might be a cleaner way to do this (without changing php code)
None that I can think of, unfortunately...
using those dedicated css, you can correct all IE bugs
Good to know - I'll do that. Too bad there's no [[MediaWiki:Monobook_IE60Fixes.css]]...
Thanks again, to both of you!
-- F.
Frederik Dohr wrote :
/* scale back up to a sane default */ #globalWrapper { font-size: 127%; width: 90%; margin: 0 auto; padding: 0; }
That's what I'd done before (except for the padding and font-size).
NB : the #globalWrapper is already in default main.css (that's why there is padding and font-size, I didn't add them) ;-)
the #globalWrapper is already in default main.css (that's why there is padding and font-size, I didn't add them) ;-)
Oh, I was using [[MediaWiki:Monobook]] for my modifications, so I had a clean canvas to work with (sort of... ).
-- F.
Frederik Dohr wrote:
I was afraid that I might have to hack the skin... But this looks interesting; I'll give it a try!
I found that the monobook skin relies too much on absolute positioning to make even minor mods easy. I completely re-jigged monobook.php to use relative positioning by just rearranging the order of the various <div>s on the page. That way, changing one <div> automatically bumps the adjacent <div>s.
My motivation in this was the fact that the skin has problems with font size changes initiated by the user thru <ctrl><+> after making a few minor changes to the skin.
Mike
I found that the monobook skin relies too much on absolute positioning to make even minor mods easy. I completely re-jigged monobook.php to use relative positioning by just rearranging the order of the various
<div>s on the page. That way, changing one <div> automatically bumps the adjacent <div>s.
Sounds interesting! Is your wiki publicly accessible, and could you share those modifications?
-- F.
Frederik Dohr wrote:
Sounds interesting! Is your wiki publicly accessible, and could you share those modifications?
I fibbed just a bit - I only did this for the right side of the page. The left side (all those navigation and toolboxes) are still using some absolute position stuff, but that stuff is well behaved and I only made significant changes to the right side.
The wiki is at http://en.kayakwiki.org
I uploaded the main.css and the skin file (KwSkin.php renamed as .hph) to my pool wiki:
http://pool.kayakwiki.org/index.php/Image:Main.css http://pool.kayakwiki.org/index.php/Image:KwSkin.hph
A few changes need to be made to the IE*fixes.css to match but they are straightforward. If you need them, I can upload them too.
Mike
Good Afternoon Wiki Fans:
Is there a configuration option to limit language choices for users to a single language ?
--Hiram
A configuration option, I don't know
but you can change the Language/Names.php and comment all the unwanted language
-- Marc
Hiram Clawson a écrit :
Good Afternoon Wiki Fans:
Is there a configuration option to limit language choices for users to a single language ?
--Hiram
MediaWiki-l mailing list MediaWiki-l@lists.wikimedia.org http://lists.wikimedia.org/mailman/listinfo/mediawiki-l
Or you can move the files corresponding to the languages you don't want users to have access to out of Languages/Messages, or delete the files entirely. I did this on a wiki to save disk space (really small quota).
~ brian "Always follow your heart, you may not end up where you were headed, but you will always end up where you were meant to be."
"Dont let nobody tell you your life is over! Be every color that you are!" -- Alyson & Amanda Michalka, "Into the Rush"
-----Original Message----- From: mediawiki-l-bounces@lists.wikimedia.org [mailto:mediawiki-l-bounces@lists.wikimedia.org] On Behalf Of Marc Despland Sent: Thursday, July 05, 2007 1:20 am To: MediaWiki announcements and site admin list Subject: Re: [Mediawiki-l] limit language choice ?
A configuration option, I don't know
but you can change the Language/Names.php and comment all the unwanted language
-- Marc
Hiram Clawson a écrit :
Good Afternoon Wiki Fans:
Is there a configuration option to limit language choices for users to a single language ?
--Hiram
MediaWiki-l mailing list MediaWiki-l@lists.wikimedia.org http://lists.wikimedia.org/mailman/listinfo/mediawiki-l
_______________________________________________ MediaWiki-l mailing list MediaWiki-l@lists.wikimedia.org http://lists.wikimedia.org/mailman/listinfo/mediawiki-l
Thanks Mike, that really helps! I'll allocate some weekend time for looking into this...
-- F.
----- Original Message ----- From: Michael Daly Date: 2007-07-04 23:33
Frederik Dohr wrote:
Sounds interesting! Is your wiki publicly accessible, and could you share those modifications?
I fibbed just a bit - I only did this for the right side of the page. The left side (all those navigation and toolboxes) are still using some absolute position stuff, but that stuff is well behaved and I only made significant changes to the right side.
The wiki is at http://en.kayakwiki.org
I uploaded the main.css and the skin file (KwSkin.php renamed as .hph) to my pool wiki:
http://pool.kayakwiki.org/index.php/Image:Main.css http://pool.kayakwiki.org/index.php/Image:KwSkin.hph
A few changes need to be made to the IE*fixes.css to match but they are straightforward. If you need them, I can upload them too.
Mike
MediaWiki-l mailing list MediaWiki-l@lists.wikimedia.org http://lists.wikimedia.org/mailman/listinfo/mediawiki-l
mediawiki-l@lists.wikimedia.org