从查询字符串中检索值 [英] retrieve value from query string

查看:86
本文介绍了从查询字符串中检索值的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在将openid集成到我的网站中. 我能够从运营商提供商那里检索数据(例如电子邮件)(通过查询字符串). 但是,不同的运营商提供程序以不同的密钥提供数据,例如gmail在openid.ext1.value.alia2密钥下提供数据,而yahoo在某些不同的密钥下提供数据. 我应该如何从查询字符串中检索值.

I am integrating openid in my website. I am able to retrieve data(ex email) from op provider(by query string). But different op provider gives data in different key like gmail gives it under openid.ext1.value.alia2 key and yahoo gives it in under some different key. how should i retrieve value from query string.

推荐答案

您必须检查名称空间.例如,服务器可能返回openid.ns.ax = http://openid.net/srv/ax/1.0,这意味着以openid.ax开头的所有内容都与AX扩展有关".
但是也可能是openid.ns.qwerty = http://openid.net/srv/ax/1.0,然后所有以openid.qwerty开头的内容都将与扩展名相关.

You must check namespaces. For example, the server may return openid.ns.ax = http://openid.net/srv/ax/1.0, and that would mean "everything that starts with openid.ax relates to the AX extension".
But it could be openid.ns.qwerty = http://openid.net/srv/ax/1.0 as well, and then everything that starts with openid.qwerty would be related to the extension.

您的代码必须读取那些名称空间,并使用这些名称空间定义的别名.阅读规范以获取更多信息.

Your code must read those namespaces and use aliases as defined by those. Read specifications for more information.

这篇关于从查询字符串中检索值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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