通过网址填充输入框,而无需编辑接收方页面 [英] Fill an input-box by url without editing the receiver page

查看:74
本文介绍了通过网址填充输入框,而无需编辑接收方页面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想用URL填充我没有任何访问权限的输入框(因此,我无法添加任何javascripts).就像是:

I want to fill an input-box which I don't have any access on it ( so I can't add any javascripts ) with url. Something like :

http://google.com/#id_searchfield=text

我提到Google是为了让您知道收件人页面不受我的控制.

I mentioned google so that you know that the receiver page is not under my control.

有可能吗?

  • 如果不可能,是否有办法用另一个域上的另一个页面而不是url来做到这一点?(某些代码或..)

我看过这些,但是所有这些都需要在接收者页面上访问:

I have seen these but all of them needs access on the receiver page :

如何我是通过url参数预填充html表单输入字段的吗?

postMessage()API

postMessage() Api

本地存储

推荐答案

要通过URL发送数据,您需要找到要填充的对象的名称,因此对于Google,您需要转到
https://www.google.nl/?q=CongratzYouFoundIt
要添加空格,请用%20代替,因此
https://www.google.nl/?q=Congratz%20You%20Found%20It%20Again
其他特殊字符可与HTML特殊字符一起使用

to send data via an URL you need to find the name of the object you want to fill, so in case of google, you need to go to
https://www.google.nl/?q=CongratzYouFoundIt
To add spaces replace them with %20, so
https://www.google.nl/?q=Congratz%20You%20Found%20It%20Again
Other special chars are aviable with HTML special Chars

这篇关于通过网址填充输入框,而无需编辑接收方页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆