[Tutor] How to Create Webpage with Python

Chris “Kwpolska” Warrick kwpolska at gmail.com
Thu Jul 10 19:24:20 CEST 2014


On Thu, Jul 10, 2014 at 6:40 PM, Alex Kleider <akleider at sonic.net> wrote:
> If all you want is to check how your 'site' looks perhaps it'd be much
> simpler to simply point your browser to your parent html file rather than
> set up a server machine to serve it:
> file:///home/yourusername/yoursubdirectory/index.html
> It'll look exactly the same as it would if you were running it on a server.
> (or am I missing something?)

JavaScript may not work.  The same might also happen with links and
resources using the // scheme (//example.com/ instead of
http://example.com/)

For local testing, use

    python -m SimpleHTTPServer

or, if you’re on Python 3,

    python3 -m http.server

-- 
Chris “Kwpolska” Warrick <http://chriswarrick.com/>
PGP: 5EAAEA16
stop html mail | always bottom-post | only UTF-8 makes sense


More information about the Tutor mailing list