.css extension

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • dp

    .css extension

    I recently changed a .css file to .asp to insert some server side code to
    write different css elements based upon some data base criteria. IE and
    Opera appear to process the .asp file and use the adjusted css. Mozilla and
    Firefox ignore it completely and display the pages with no css.

    I couldn't find anything stating I couldn't use server side scripting to
    write a css file. Is there anything in the spec that prohibits it?

    The HTML I'm using is
    <link rel="stylesheet " type="text/css" href="css.asp">
    __
    dp


  • Darin McGrew

    #2
    Re: .css extension

    dp <noreplyhere@ho tmail.com> wrote:[color=blue]
    > I recently changed a .css file to .asp to insert some server side code to
    > write different css elements based upon some data base criteria. IE and
    > Opera appear to process the .asp file and use the adjusted css. Mozilla and
    > Firefox ignore it completely and display the pages with no css.
    >
    > I couldn't find anything stating I couldn't use server side scripting to
    > write a css file. Is there anything in the spec that prohibits it?[/color]

    The style sheet is probably being sent with an incorrect Content-Type
    header. See http://css.nu/faq/ciwas-aFAQ.html#QA05
    --
    Darin McGrew, mcgrew@stanford alumni.org, http://www.rahul.net/mcgrew/
    Web Design Group, darin@htmlhelp. com, http://www.HTMLHelp.com/

    "It said 'Insert disk #3', but only two will fit..."

    Comment

    • Chris Sharman

      #3
      Re: .css extension

      Darin McGrew wrote:
      [color=blue]
      > dp <noreplyhere@ho tmail.com> wrote:[color=green]
      >>I recently changed a .css file to .asp to insert some server side code to
      >>write different css elements based upon some data base criteria. IE and
      >>Opera appear to process the .asp file and use the adjusted css. Mozilla and
      >>Firefox ignore it completely and display the pages with no css.[/color]
      >
      > The style sheet is probably being sent with an incorrect Content-Type
      > header. See http://css.nu/faq/ciwas-aFAQ.html#QA05[/color]

      I expect so. The mozilla Tools > Web Development > Javascript Console
      would confirm it.

      Chris

      Comment

      • bonfils

        #4
        Re: .css extension

        "dp" <noreplyhere@ho tmail.com> wrote in message
        news:c0r%c.8807 $ZC7.5342@newss vr19.news.prodi gy.com...[color=blue]
        > I recently changed a .css file to .asp to insert some server side code to
        > write different css elements based upon some data base criteria. IE and
        > Opera appear to process the .asp file and use the adjusted css. Mozilla[/color]
        and[color=blue]
        > Firefox ignore it completely and display the pages with no css.
        >
        > I couldn't find anything stating I couldn't use server side scripting to
        > write a css file. Is there anything in the spec that prohibits it?
        >
        > The HTML I'm using is
        > <link rel="stylesheet " type="text/css" href="css.asp">[/color]

        On the project I'm currently working on, the style sheets are all .asp
        files.
        We set the content type in the first line of these .asp files with this
        code:

        <%Response.Cont entType="text/css";%>

        That seems to work fine with Mozilla.

        --
        bonfils


        Comment

        • dp

          #5
          Re: .css extension

          bonfils wrote:[color=blue]
          > "dp" <noreplyhere@ho tmail.com> wrote in message
          > news:c0r%c.8807 $ZC7.5342@newss vr19.news.prodi gy.com...[color=green]
          >> I recently changed a .css file to .asp to insert some server side
          >> code to write different css elements based upon some data base
          >> criteria. IE and Opera appear to process the .asp file and use the
          >> adjusted css. Mozilla and Firefox ignore it completely and display
          >> the pages with no css.
          >>
          >> I couldn't find anything stating I couldn't use server side
          >> scripting to write a css file. Is there anything in the spec that
          >> prohibits it?
          >>
          >> The HTML I'm using is
          >> <link rel="stylesheet " type="text/css" href="css.asp">[/color]
          >
          > On the project I'm currently working on, the style sheets are all .asp
          > files.
          > We set the content type in the first line of these .asp files with
          > this code:
          >
          > <%Response.Cont entType="text/css";%>
          >
          > That seems to work fine with Mozilla.
          >
          > --
          > bonfils[/color]

          Haf to remove the semi-colon, but that did the trick. Many thanks!
          __
          dp


          Comment

          • Evertjan.

            #6
            Re: .css extension

            dp wrote on 09 sep 2004 in comp.infosystem s.www.authoring.stylesheets:[color=blue][color=green]
            >> <%Response.Cont entType="text/css";%>
            >>
            >> That seems to work fine with Mozilla.[/color]
            >
            > Haf to remove the semi-colon, but that did the trick. Many thanks!
            >[/color]

            Only if the IIS ASP server defaults to vbscript,
            not necessary [removing the ;] if the default is set to jscript

            --
            Evertjan.
            The Netherlands.
            (Please change the x'es to dots in my emailaddress,
            but let us keep the discussions in the newsgroup)

            Comment

            Working...