如何获取当前Web的URL?

gslin 2005-01-24 10:38:56
如何获取当前Web的URL?
...全文
290 8 打赏 收藏 转发到动态 举报
写回复
用AI写文章
8 条回复
切换为时间正序
请发表友善的回复…
发表回复
zengxianfeng 2005-01-24
  • 打赏
  • 举报
回复
JS有属性可找到URL,你查查资料!
ylj718 2005-01-24
  • 打赏
  • 举报
回复
用一个隐藏的域:域名为,query_string_decoded
用法:
Returns the same as Query_String, but decodes the string. For example,
if a URL references a view name that contains characters that are not
allowed in a URL, the name is encoded. This CGI variable decodes that
string. Path_Info_Decoded is available to Domino applications only.
desertwolf81 2005-01-24
  • 打赏
  • 举报
回复
window.location.pathname
carlunbu 2005-01-24
  • 打赏
  • 举报
回复
哦,对对对,query_string_decoded是获取参数的。sorry,差点耽误了楼主。
kingchang2000 2005-01-24
  • 打赏
  • 举报
回复
query_string_decoded是获取url中“?”以后的数据,怎么能获取当前页面的整个url呢?
推荐使用js:location.href就可以获取了。onload事件,如果但前是editdocument的情况,那么就赋一个值进去。
carlunbu 2005-01-24
  • 打赏
  • 举报
回复
创建一个域,域名取如下两种选择:
query_string_decoded,得到解码后的url
query_string,是没解码的url
kcw 2005-01-24
  • 打赏
  • 举报
回复
alert(window.location.href);
ntwo1980 2005-01-24
  • 打赏
  • 举报
回复
你可以在帮助中查找CGI变量列表。
表示当前表单URL的CGI变量是Path_Info_Decoded

536

社区成员

发帖
与我相关
我的任务
社区描述
企业开发 Exchange Server
社区管理员
  • 消息协作社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧