【发布时间】:2010-09-04 04:07:46
【问题描述】:
我正在搞乱一个 Tornado 网络应用程序,我需要一些帮助。我有多个同名复选框,我想发布所选复选框的值。
<input id=DB_BASED_ID name="activity" value=DB_BASED_ID type="checkbox"/>
<input id=DB_BASED_ID name="activity" value=DB_BASED_ID type="checkbox"/>
<input id=DB_BASED_ID name="activity" value=DB_BASED_ID type="checkbox"/>
<input id=DB_BASED_ID name="activity" value=DB_BASED_ID type="checkbox"/>
我可以使用 javascript pre-POST 获取每个值,但在 python (tornado) 端获取此列表时遇到问题。我只得到最高的选定值。
在 python 端它看起来像:
...
def post(self):
email = self.get_argument("email")
activity = self.get_argument("activity")
【问题讨论】:
标签: python forms post checkbox tornado