Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
试图建立一个网页。
我希望能够从 HTML 表单中获取一些用户输入,在该输入上运行 python 函数,然后将一些输出返回给用户。
示例:用户在 HTML 表单中输入“2”,python 函数将其加倍并在网页上返回“4”(我的实际函数使用矩阵代数,所以我不太可能在 jQuery 中完成所有操作)。
我正在使用cherrypy,但我对其他模块持开放态度。我不知道如何去做,因为大多数cherrypy示例只是打印一个字符串而没有实际调用任何python函数。