diff options
author | Cash Costello <cash.costello@gmail.com> | 2011-12-11 06:38:23 -0500 |
---|---|---|
committer | Cash Costello <cash.costello@gmail.com> | 2011-12-11 06:38:23 -0500 |
commit | d9bf22a0e29c2a70049443a0ae8521a2c0492c8b (patch) | |
tree | c7599a9169d5def7df56c480ad6d67f312443d6f /models/openid-php-openid-782224d/examples/consumer/index.php | |
download | elgg-d9bf22a0e29c2a70049443a0ae8521a2c0492c8b.tar.gz elgg-d9bf22a0e29c2a70049443a0ae8521a2c0492c8b.tar.bz2 |
initial commit for git repository
Diffstat (limited to 'models/openid-php-openid-782224d/examples/consumer/index.php')
-rw-r--r-- | models/openid-php-openid-782224d/examples/consumer/index.php | 73 |
1 files changed, 73 insertions, 0 deletions
diff --git a/models/openid-php-openid-782224d/examples/consumer/index.php b/models/openid-php-openid-782224d/examples/consumer/index.php new file mode 100644 index 000000000..1ff091125 --- /dev/null +++ b/models/openid-php-openid-782224d/examples/consumer/index.php @@ -0,0 +1,73 @@ +<?php +require_once "common.php"; + +global $pape_policy_uris; +?> +<html> + <head><title>PHP OpenID Authentication Example</title></head> + <style type="text/css"> + * { + font-family: verdana,sans-serif; + } + body { + width: 50em; + margin: 1em; + } + div { + padding: .5em; + } + table { + margin: none; + padding: none; + } + .alert { + border: 1px solid #e7dc2b; + background: #fff888; + } + .success { + border: 1px solid #669966; + background: #88ff88; + } + .error { + border: 1px solid #ff0000; + background: #ffaaaa; + } + #verify-form { + border: 1px solid #777777; + background: #dddddd; + margin-top: 1em; + padding-bottom: 0em; + } + </style> + <body> + <h1>PHP OpenID Authentication Example</h1> + <p> + This example consumer uses the <a + href="http://github.com/openid/php-openid">PHP + OpenID</a> library. It just verifies that the URL that you enter + is your identity URL. + </p> + + <?php if (isset($msg)) { print "<div class=\"alert\">$msg</div>"; } ?> + <?php if (isset($error)) { print "<div class=\"error\">$error</div>"; } ?> + <?php if (isset($success)) { print "<div class=\"success\">$success</div>"; } ?> + + <div id="verify-form"> + <form method="get" action="try_auth.php"> + Identity URL: + <input type="hidden" name="action" value="verify" /> + <input type="text" name="openid_identifier" value="" /> + + <p>Optionally, request these PAPE policies:</p> + <p> + <?php foreach ($pape_policy_uris as $i => $uri) { + print "<input type=\"checkbox\" name=\"policies[]\" value=\"$uri\" />"; + print "$uri<br/>"; + } ?> + </p> + + <input type="submit" value="Verify" /> + </form> + </div> + </body> +</html> |