我已经在Stack Overflow上看到其他人问同样的问题,但是答案仍然是相同的:“使用name
属性。”
这对我不起作用,这是我的代码:
<form action="index.php">
<input type="radio" name="1">
<input type="radio" name="2">
</form>
我做错了吗?
答案 0 :(得分:0)
with open('line_number.txt', 'rb') as inp:
line = inp.read()
fp = open("list.txt")
for i, line in enumerate(fp):
if i == line - 1: #iterates until the number match
s = i + 1
with open('new.txt', 'w') as outp:
outp.write(s)
outp.close()
print(i)
break
fp.close()
答案 1 :(得分:-1)
两个按钮的名称相同:
<form action="index.php">
<input type="radio" name="one">
<input type="radio" name="one">
</form>