简体   繁体   English

Raspberry Pi-HTML表单未提交

[英]Raspberry Pi - HTML forms not submitting

I have a Raspberry Pi that is effectively being used as a kiosk display. 我有一个Raspberry Pi,可以有效地用作信息亭显示。 It auto starts Chromium and goes to a webpage which displays some data. 它会自动启动Chromium,并转到显示一些数据的网页。 There is a form on this page and a barcode reader attached to the Pi which, when a barcode is scanned dumps the contents of the barcode into the textbox and simulates a carriage return (enter). 此页面上有一个表格,Pi附带有条形码读取器,当扫描条形码时,条形码读取器会将条形码的内容转储到文本框中并模拟回车(输入)。

This works in console on the Pi and on other machines which have no problem with the webpage however, on the Pi it will generally dump the contents of the barcode and won't submit the form - if you attach the keyboard and hit enter nothing happens; 这可以在Pi上的控制台以及网页上没有问题的其他机器上的控制台中工作,但是,在Pi上,它通常会转储条形码的内容,并且不会提交表格-如果您连接键盘并按Enter键,则不会发生任何事情; change the focus onto the button and hit enter - nothing happens! 将焦点更改到按钮上,然后按Enter键-什么也没发生!

Pi上的表格

My HTML code for the form: 我的表单HTML代码:

 <table class="footer"> <tr class='grey'> <td> <?php echo date( "d/m/Y - H:i:s", time()); ?> </td> <td> <form action='board_update.php' id="id" method='post'><input type='text' name='id' autofocus='autofocus'/><input type="submit " value="Submit " /></form></td> </tr> </table> 

The page has a meta tag which causes it to refresh at 5 minute intervals (which it does). 该页面具有一个meta标签,使它每隔5分钟刷新一次(确实如此)。

I'm wondering what the problem is? 我想知道问题是什么? The form or the Pi? 形式还是Pi?

It appears that after much troubleshooting and replicating the setup on another Pi, that it is indeed the Raspberry Pi at fault. 经过大量的故障排除并在另一台Pi上复制了设置之后,看来确实是Raspberry Pi出了问题。 Something is either wrong with the OS or hardware but I've replaced the entire set up and so far, so good. 操作系统或硬件出了点问题,但是到目前为止,我已经替换了整个设置,一切都很好。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM