[dokuwiki] Re: different Stylesheets with Conditional Comments

  • From: Gunther Pilz <dokuwiki@xxxxxxxxxxxxxx>
  • To: dokuwiki@xxxxxxxxxxxxx
  • Date: Sun, 19 Aug 2007 20:39:19 +0200

Hi Anika!

Anika Henke schrieb:
> Gunther Pilz wrote:
>
>> And as I wrote already in reply to Andis mail, by this way I'll get
>> another http request and increase traffic, because IEs then have to load
>> 2 css files, where one isn't needed at all. This is what I want to avoid
>> (if possible).
>
> I do not understand. Even with conditional comments, you should still
> be serving at least *two* css files. Or what would you do with the
> other browsers??
No, there have to be two css files, *but* you can prevent IEs from
loading the standard compliant css file (by CC) which then is only
loaded by the standard compliant browsers.
For example like this:

    <!--[if !IE]> -->
    <link rel="stylesheet" type="text/css"
    href="css/standard_compliant.css" />
    <!--<![endif]-->
    <!--[if IE 7]>
    <link rel="stylesheet" type="text/css" href="css/ie_7.css" />
    <![endif]-->
    <!--[if lte IE 6]>
    <link rel="stylesheet" type="text/css" href="css/ie_6.css" />
    <![endif]-->


>
>>> IE only, so the only styles are template styles, which again points to
>>> you referencing the CSS file directly in the template.
>> That's maybe a reason why there are so few multicolumn layouts for DW.
>
> What has a multi-column layout to do with Conditional Comments??
I think that's really obvious. It's almost impossible to create a modern
multi-column layout (ie. equal height columns with css) *without* doing
heavy adjustments for IE (<= 6).

>
>> layouts for DW. My opinion is that the default layout of DW isn't
>> up-to-date anymore. Most of the users have viewport sizes >= 1.000px,
>> which means that a full width single-column layout isn't very much
>> userfriendly, because line-length is much to great. And putting a
>
>> Almost every effective DW installation I know uses at least a two-column
>> layout, for presenting their users such usefull things like a navigation
>> or other interesting informations beside the main content.
>
> The point of having more than one column in the default template has
> been discussed earlier in this list. 
Sorry - must have missed it.

> The main reason of that discussion why *not* to add a possibility of a
> two-or-more-column layout for me was: Then all template developers
> have to provide all possible layouts!
I can't see the point. What reasons lead you to this conclusion?

>
> I agree that most users like a two-or-more-column layout and that it
> makes more sense in many environments. But I disagree to change the
> default layout. 
Well, you don't have to throw away the old layout, rather then providing
DW with two layouts instead.
The big advantage of having *one* standard 2/multi-column layout would
be, that there would be a guidline for all plugin-developers, who
develop plugins which generate output to the wiki other then main
content. And it would allow a much more comfortable way to layout the
wiki for non HTML/CSS experts, by simply choosing the desired modul and
its position ie. in an admin layout configuration "area".


> There are many two-or-more-column DokuWiki templates out there. And a
> few of them are really good, too.
The term 'many' is relative. In comparison to some other wikis/ cms
systems I would say it's rather a little. With your last sentence I
fully agree.

>
> To come to the original point:
> I am not at all against providing the possibility of adding
> conditional comments.
> But I am not sure it is worth the effort, because:
>
> 1. You should never code your css for a particular browser. Although,
> we all know, that this sounds good in theory, but that IE always
> needed special attendance (if you cared for your users). Even
> DokuWiki's default css is written for two browsers: IE and "the rest".
> 2. There are other workarounds (IE6: "* html", IE7: "*+html").
> Admittedly, conditional comments are more future-proof.
> 3. IE is getting better. (Yes!) In the not-too-far-away future we
> might not need to use any "special attendances" any more ...
>
To point number

   1. I agree to the theory - but these days it's just theory
   2. I don't like to use these css-hacks. You'll never exactly know
      what side effects they will have (now and in the future). And they
      mess up your clearly arranged code.
   3. And again the term 'not-too-far-away future' is relative. Who'll
      exactly know how things change in the future and what does it help
      users today? I'll very much believe that it will take still some
      more years before we'll reach a point where one standard compliant
      css will be enough for your website. I don't wanna wait so long.

Don't get me wrong - I don't want to criticize but to make some
proposals for future developement of DW which are (from my point of
view) reasonable.

Gunther

Other related posts: