Aaron Swartz rewriting Reddit on the idea of creating web.py

Source: Internet
Author: User

How do should things work? The first principle is that code should was clear and simple. If you want the output some text, you call Web.output. If you want-get form input, you call web.input. There ' s nothing particularly hard to remember.

The second principle is this web.py should fit your code, not the other--a-around. Every function in web.py are completely independent, you can use whichever ones. You can put your files wherever your like, and web.py'll happily follow along. If you want a piece of code to being run as a web app, you call Web.run, and you don't put your code in the magical where so Web.py can run you.

The third principle is this web.py should, by default, does the right thing by the Web. This means distinguishing between GET and POST properly. It means simple, canonical URLs which synonyms redirect to. It means readable HTML with the proper HTTP headers.

Aaron Swartz rewriting Reddit on the idea of creating web.py

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.