@import

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • gimme_this_gimme_that@yahoo.com

    @import

    I've seen this include at several sites.

    Is this documented somewhere?

    Briefly - how does it work?

    Thanks.
  • Thomas 'PointedEars' Lahn

    #2
    Re: @import

    gimme_this_gimm e_that@yahoo.co m wrote:
    I've seen this include at several sites.
    Which include? Do not assume people can read the Subject header.

    Which sites? In which context within the code?
    Is this documented somewhere?
    Maybe, maybe not.
    Briefly - how does it work?
    I don't know. The `@' prefix is used in Microsoft JScript, followed by the
    keywords `cc_on', `debug', `if', `position' aso. Maybe `@import' is just
    another one of those.

    RTFM, STFW.


    PointedEars
    --
    Anyone who slaps a 'this page is best viewed with Browser X' label on
    a Web page appears to be yearning for the bad old days, before the Web,
    when you had very little chance of reading a document written on another
    computer, another word processor, or another network. -- Tim Berners-Lee

    Comment

    • gimme_this_gimme_that@yahoo.com

      #3
      Re: @import

      I was checking out the code at wikipedia.com.

      Search for anything - like HTML and the source has code like this:

      /*]]>*/
      </style> <script type="text/javascript" src="/w/index.php?title =-
      &amp;action=raw &amp;gen=js&amp ;useskin=monobo ok"><!-- site js --></
      script>
      <style type="text/css">/*<![CDATA[*/
      @import "/w/index.php?
      title=MediaWiki :Common.css&use msgcache=yes&ac tion=raw&ctype= text/
      css&smaxage=267 8400";
      @import "/w/index.php?
      title=MediaWiki :Monobook.css&u semsgcache=yes& action=raw&ctyp e=text/
      css&smaxage=267 8400";
      @import "/w/index.php?title =-&action=raw&gen =css&maxage=267 8400";
      /*]]>*/</style>

      Comment

      • Thomas 'PointedEars' Lahn

        #4
        Re: @import

        gimme_this_gimm e_that@yahoo.co m wrote:
        I was checking out the code at wikipedia.com.
        >
        Search for anything - like HTML and the source has code like this:
        >
        /*]]>*/
        </style> <script type="text/javascript" src="/w/index.php?title =-
        &amp;action=raw &amp;gen=js&amp ;useskin=monobo ok"><!-- site js --></
        script>
        The `script' element ends here.
        <style type="text/css">/*<![CDATA[*/
        @import "/w/index.php?
        title=MediaWiki :Common.css&use msgcache=yes&ac tion=raw&ctype= text/
        css&smaxage=267 8400";
        @import "/w/index.php?
        title=MediaWiki :Monobook.css&u semsgcache=yes& action=raw&ctyp e=text/
        css&smaxage=267 8400";
        @import "/w/index.php?title =-&action=raw&gen =css&maxage=267 8400";
        /*]]>*/</style>
        On a closer look you will recognize that the @import declarations are part
        of the stylesheet, not of the script. This is specified here:




        PointedEars
        --
        realism: HTML 4.01 Strict
        evangelism: XHTML 1.0 Strict
        madness: XHTML 1.1 as application/xhtml+xml
        -- Bjoern Hoehrmann

        Comment

        • Prisoner at War

          #5
          Re: @import

          On Apr 20, 2:33 pm, "gimme_this_gim me_t...@yahoo.c om"
          <gimme_this_gim me_t...@yahoo.c omwrote:
          I've seen this include at several sites.
          >
          Is this documented somewhere?
          >
          Briefly - how does it work?
          >
          Thanks.

          I just found out about it myself...it's a way for one CSS file to
          "dial in" another...in the CSS-module school of thought, you would
          have different CSS files linked by one "master" CSS file...makes any
          debugging easier, among other reasons....

          Comment

          Working...