填充网站表单字段
假设我有一份已提交的表格,其中包含我面前的所有数据,但我想获取所有这些数据并在另一个网站上预先填充表格,这是可能的还是我在寻求奇迹?
基本上我遇到了这个问题,我必须每晚进行站点并从一个站点获取信息并将其复制并粘贴到另一个站点上的表格中,噩梦。
理想的情况是,我可以有一个抓取按钮,从我的表单中抓取所有数据并以某种方式存储它,然后我可以访问其他网站并几乎将复制粘贴到字段中。
或者他们是否可以将数据直接从我的表单发送到他们的系统以进行付款?
有什么想法或帮助让我的生活更轻松吗???
Say if i have a filed out form with all the data infront of me, but i want to take all that data and pre populate a form on another website is this possible or am i asking for miracles?
Basically i have this issue where i have to site every night and take information from one site and the copy and peaste it into a form on another site, nightmare.
Ideal situation i could have a grab button that grabs all the data from my form and stores it somehow then i could access the other website and almost do a copy paste into the fields.
Or would their be a way to actually just send the data straight from my form to theirs systems to make a payment??
Any ideas or help to make my life easier???
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
我过去也曾做过类似的事情。虽然我没有研究 JQuery 解决方案,但我能够通过使用 http://www.autohotkey 获得所需的结果.com/ 创建一个脚本来复制信息,用 Tab 键切换到下一个窗口,粘贴,用 Tab 键返回,再次复制,冲洗并重复。
I've had to perform something similar in the past. Although I didn't look into a JQuery solution, I was able to achieve the desired results by using http://www.autohotkey.com/ to create a script that would copy the information, tab over to the next window, paste, tab back, copy again, rinse and repeat.
根据网站的不同,您可能能够直接发布到他们的页面,这基本上是跳过他们的表单,或者如果他们不挑剔数据是否从其中读取,您可能能够在查询字符串中传递他们的输入字段参数get 或 post 变量。与填写表格不太一样,但它可以根据网站的不同而起作用。
据我所知,使用 Javascript 填写表单是不可能的。如果是的话,我很想知道该怎么做。我想填充在加载了不同站点的 Iframe 中加载的页面上的字段。我做了很多研究,但我无法找到一种方法来做到这一点。
但是,如果您这样做是出于个人原因,只是为了更快地填写内容,那么您可以使用浏览器内置的自动填充功能,或者您可以使用 firefox 的 Imacros 插件(https://addons.mozilla.org/en-US/firefox/addon/3863/) 为您填写表格。
Depending upon the website you may be able to post directly to their page, which is basically skipping their form, or you may be able to pass their input field parameters in the query string if they are not being picky about whether the data is read from the get or post variables. Not quite the same as filling out the form, but it could work depending upon the site.
As far as filling out a form using Javascript as far as I know this is not possible. I would love to know how to do so if it is though. I wanted to populate the fields on a page loaded in an Iframe that had a different site loaded. I did a lot of research, but I could not figure out a way to do it.
But if you are doing this for personal reasons, just to make filling out things quicker, then you can use the built in auto-fill of the browser, or you could record a macro using Imacros plugin for firefox (https://addons.mozilla.org/en-US/firefox/addon/3863/) to fill in forms for you.
我知道如何编写一个可以做到这一点的 .NET 应用程序。我确信其他应用程序语言也可以做同样的事情。我不知道任何 javascript 方面的东西(例如 jQuery)可以做到这一点。
Robodude 可能是使用自动热键的最佳解决方案。对于这样的任务来说它非常强大。
I know how to write a .NET application that would do that. I'm sure other app languages could do the same. I don't know about anything javascript wise (jQuery for instance) that could do this.
Robodude has probably the best solution in using autohotkey. It's pretty powerful for tasks like this.