SimpleHTTPServer, external CSS, and Google Chrome

Discussion in 'Python' started by Justin Ezequiel, Sep 17, 2010.

  1. I am running "python -m SimpleHTTPServer 80" on Windows XP Pro SP 3
    (Python 2.5.4)

    browsing http://localhost/ using IE8 and FireFox 3.6, I get blue text
    on red background
    on Google Chrome 6.0 however, I get blue text on white background
    placing index.htm and styles.css (see below) under IIS, I get blue
    text on red background for all browsers,
    including Google Chrome 6.0.

    I get exactly the same results when browsing from another machine.
    what's wrong? what do I need to change in SimpleHTTPServer?

    index.htm
    --------------
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
    "http://www.w3.org/TR/html4/strict.dtd">
    <html>
    <head>
    <title>your title</title>
    <meta http-equiv="Content-Type" content="text/
    html;charset=ISO-8859-1">
    <link rel="stylesheet" href="styles.css" type="text/css">
    <style type="text/css">
    body {
    color: blue;
    }
    </style>
    </head>
    <body><p>foo bar</p>
    </body>
    </html>
    --------------

    styles.css
    --------------
    body {
    background-color: red;
    }
    --------------
     
    Justin Ezequiel, Sep 17, 2010
    #1
    1. Advertising

  2. Justin Ezequiel

    MrJean1 Guest

    FWIW,

    There is a blue text on a red background in all 4 browsers Google
    Chrome 6.0.472.59, Safari 5.0.1 (7533.17.8), FireFox 3.6.9 and IE
    6.0.2900.5512.... with Python 2.7 serving that page on my Windows XP
    SP 3 machine.

    /Jean

    On Sep 16, 11:59 pm, Justin Ezequiel <>
    wrote:
    > I am running "python -m SimpleHTTPServer 80" on Windows XP Pro SP 3
    > (Python 2.5.4)
    >
    > browsinghttp://localhost/using IE8 and FireFox 3.6, I get blue text
    > on red background
    > on Google Chrome 6.0 however, I get blue text on white background
    > placing index.htm and styles.css (see below) under IIS, I get blue
    > text on red background for all browsers,
    > including Google Chrome 6.0.
    >
    > I get exactly the same results when browsing from another machine.
    > what's wrong? what do I need to change in SimpleHTTPServer?
    >
    > index.htm
    > --------------
    > <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
    >    "http://www.w3.org/TR/html4/strict.dtd">
    > <html>
    > <head>
    > <title>your title</title>
    > <meta http-equiv="Content-Type" content="text/
    > html;charset=ISO-8859-1">
    > <link rel="stylesheet" href="styles.css" type="text/css">
    > <style type="text/css">
    > body {
    >     color: blue;}
    >
    > </style>
    > </head>
    > <body><p>foo bar</p>
    > </body>
    > </html>
    > --------------
    >
    > styles.css
    > --------------
    > body {
    >     background-color: red;}
    >
    > --------------
     
    MrJean1, Sep 17, 2010
    #2
    1. Advertising

  3. On Sep 18, 2:54 am, MrJean1 <> wrote:
    > FWIW,
    >
    > There is a blue text on a red background in all 4 browsers Google
    > Chrome 6.0.472.59, Safari 5.0.1 (7533.17.8), FireFox 3.6.9 and IE
    > 6.0.2900.5512.... with Python 2.7 serving that page on my Windows XP
    > SP 3 machine.
    >
    > /Jean
    >


    Hmm.
    Will download and install newer python versions to re-check then.
    Thanks.
     
    Justin Ezequiel, Sep 20, 2010
    #3
  4. Justin Ezequiel, Sep 20, 2010
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Roedy Green

    Google's new Chrome browser

    Roedy Green, Sep 2, 2008, in forum: Java
    Replies:
    32
    Views:
    1,219
    Lasse Reichstein Nielsen
    Sep 6, 2008
  2. cwdjrxyz
    Replies:
    7
    Views:
    513
    ddg_linux
    Sep 3, 2008
  3. cwdjrxyz
    Replies:
    0
    Views:
    557
    cwdjrxyz
    Sep 11, 2008
  4. Simon Laub
    Replies:
    9
    Views:
    5,302
    GTalbot
    Sep 9, 2009
  5. Anton
    Replies:
    2
    Views:
    755
    Raghupathi K
    Sep 14, 2009
Loading...

Share This Page