Changing parser output MIME type

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

    Changing parser output MIME type

    Is there a way that without need of creating any "wrapper" script, PHP
    can parse .css files with scripts embedded and pass them to clients
    with proper MIME type (text/css instead of text/html)?

  • Oli Filth

    #2
    Re: Changing parser output MIME type

    m_roguski@yahoo .com said the following on 27/03/2006 16:48:[color=blue]
    > Is there a way that without need of creating any "wrapper" script, PHP
    > can parse .css files with scripts embedded and pass them to clients
    > with proper MIME type (text/css instead of text/html)?
    >[/color]

    See the PHP manual for header().

    --
    Oli

    Comment

    • m_roguski@yahoo.com

      #3
      Re: Changing parser output MIME type

      Did I just write _without_ a wrapper?

      Comment

      • Jerry Stuckle

        #4
        Re: Changing parser output MIME type

        m_roguski@yahoo .com wrote:[color=blue]
        > Is there a way that without need of creating any "wrapper" script, PHP
        > can parse .css files with scripts embedded and pass them to clients
        > with proper MIME type (text/css instead of text/html)?
        >[/color]

        Not without a wrapper, no. You can only send one MIME type per file - and
        you're already sending text/html for your main file.


        When you do a link, img, etc., the browser must make a second request for the
        new file. And that one will have its own MIME type.
        --
        =============== ===
        Remove the "x" from my email address
        Jerry Stuckle
        JDS Computer Training Corp.
        jstucklex@attgl obal.net
        =============== ===

        Comment

        • Oli Filth

          #5
          Re: Changing parser output MIME type

          m_roguski@yahoo .com said the following on 27/03/2006 16:56:[color=blue]
          > Did I just write _without_ a wrapper?
          >[/color]

          Yes.

          So?

          --
          Oli

          Comment

          Working...