PHP Classes

File: web/SSO/vendor/openid/php-openid/examples/server/lib/render/idpXrds.php

Recommend this page to a friend!
  Classes of william amed   Raptor 2   web/SSO/vendor/openid/php-openid/examples/server/lib/render/idpXrds.php   Download  
File: web/SSO/vendor/openid/php-openid/examples/server/lib/render/idpXrds.php
Role: Auxiliary script
Content type: text/plain
Description: Auxiliary script
Class: Raptor 2
Framework that takes routes from annotations
Author: By
Last change:
Date: 8 years ago
Size: 611 bytes
 

Contents

Class file image Download
<?php

require_once "lib/session.php";
require_once
"lib/render.php";

require_once
"Auth/OpenID/Discover.php";

define('idp_xrds_pat', '<?xml version="1.0" encoding="UTF-8"?>
<xrds:XRDS
    xmlns:xrds="xri://$xrds"
    xmlns="xri://$xrd*($v*2.0)">
  <XRD>
    <Service priority="0">
      <Type>%s</Type>
      <URI>%s</URI>
    </Service>
  </XRD>
</xrds:XRDS>
'
);

function
idpXrds_render()
{
   
$headers = array('Content-type: application/xrds+xml');

   
$body = sprintf(idp_xrds_pat,
                   
Auth_OpenID_TYPE_2_0_IDP,
                   
buildURL());

    return array(
$headers, $body);
}

?>