I'm using RPXNow.com and it's like this openID sign in thing. But I need help. It gives you a code for the sign in widget. EZ, but then when it sends the request and the token_url and auth_info I don't get it.
Extra Info:
1) Add the sign-in interface to your website
The sign-in interface can be displayed in a "popup" overlay on top of your page, or embedded as an iframe. Choose the option below that best fits your needs.
Popup Instructions
Embed Instructions
Add the following javascript code to the bottom of each page where you'd like users to sign in:
<script src="https://rpxnow.com/openid/v2/widget"
type="text/javascript"></script>
<script type="text/javascript">
RPXNOW.overlay = true;
RPXNOW.language_preference = 'en';
</script>
Copy the following signin/signup link to your pages:
<a class="rpxnow" onclick="return false;"
href="https://hdivx-login.rpxnow.com/openid/v2/signin?token_url=your_token_url">
Sign In
</a>
Any link with the class rpxnow that is on a page with the RPX javascript will popup the sign-in interface. Set the token_url parameter in the link to the URL on your website which will handle the RPX response, and make sure it is properly URL-escaped. See step 2 below for more about the token_url. The onclick and href attributes make sure RPX works properly for users with javascript disabled. The href is also used by the popup widget to configure itself.
Also, you may configure which providers show up in your widget and in what order from the Providers page.
2) Receive the RPX token, and get the authentication information
After a successful authentication, RPX redirects the user back to the token_url at your website as specified in step 1. Write some code to handle requests to your token_url, and extract the token POST parameter.
Make the auth_info API call
HTTP POST to
https://rpxnow.com/api/v2/auth_info with the following required parameters:
apiKey 6e66a8f57b886310b349ac40c155f0623969a768
token Use the token sent to your token_url
RPX will respond with a JSON formatted response including the identifier of the user.
{
"profile": {
"displayName": "brian",
"preferredUsername": "brian",
"url": "http:\/\/brian.myopenid.com\/",
"providerName": "Other",
"identifier": "http:\/\/brian.myopenid.com\/"
},
"stat": "ok"
}
Use the identifier as the unique key to sign the user in to your website. If it's easier for you to parse XML, pass the optional format parameter to auth_info with a value of xml. You'll get a response like this:
<?xml version='1.0' encoding='UTF-8'?>
<rsp stat='ok'>
<profile>
<displayName>
brian
</displayName>
<identifier>
http://brian.myopenid.com/
</identifier>
<preferredUsername>
brian
</preferredUsername>
<providerName>
Other
</providerName>
<url>
http://brian.myopenid.com/
</url>
</profile>
</rsp>