Welcome, guest! Login / Register - Why register?
Psst.. new poll here.
Psst.. new forums here.
Microsoft is blocking us again (TY IP Reputation!) so just use oauth login instead. :)

Paste

Pasted as Diff by kd ( 15 years ago )
commit 53cb4c16ed85b09706676540e8bf704188f32c41
Author: Kamil Domanski <[email protected]>
Date:   Fri Jun 24 00:24:45 2011 +0200

    add template to openid request page

diff --git a/apps/user_openid/phpmyid.php b/apps/user_openid/phpmyid.php
index 719bbd9..330cd46 100644
--- a/apps/user_openid/phpmyid.php
+++ b/apps/user_openid/phpmyid.php
@@ -12,6 +12,8 @@
  * @version 0.9
  */
 
+require( 'template.php' );
+
 
 /**
  * Set a constant to indicate that phpMyID is running
@@ -558,9 +560,8 @@ function logout_mode () {
  * @global array $profile
  */
 function no_mode () {
- global $profile;
-
- wrap_html('This is an OpenID server endpoint. For more information, see http://openid.net/<br/>Server: <b>' . $profile['idp_url'] . '</b><br/>Realm: <b>' . $profile['php_realm'] . '</b><br/><a href="' . $profile['idp_url'] . '?openid.mode=login">Login</a>' . ($profile['allow_test'] === true ? ' | <a href="' . $profile['idp_url'] . '?openid.mode=test">Test</a>' : null));
+ $tmpl = new OC_TEMPLATE( 'user_openid', 'nomode', 'guest' );
+ $tmpl->printPage();
 }
 
 
diff --git a/apps/user_openid/templates/nomode.php b/apps/user_openid/templates/nomode.php
new file mode 100644
index 0000000..13a1a89
--- /dev/null
+++ b/apps/user_openid/templates/nomode.php
@@ -0,0 +1,23 @@
+<?php
+
+global $profile;
+
+?>
+
+<div id="login">
+ <img src="<?php echo image_path(" alt="ownCloud" />
+ <ul>
+  <li class='error'>
+   <div id="setup_form">
+   <p><?php echo($l->t('This is an OpenID server endpoint. For more information, see http://openid.net/'));?></p>
+   <p><?php echo($l->t('Server: <b>').$profile['idp_url']); ?></b>
+   <p><?php echo($l->t('Realm: <b>').$profile['php_realm']); ?></b>
+   <p><a href="<?php echo($profile['idp_url']); ?>?openid.mode=login"><?php echo($l->t('Login')); ?></a>
+   <?php if($profile['allow_test'] === true){ ?>
+   | <a href="<?php echo($profile['idp_url']); ?>?openid.mode=test">Test</a>
+   <?php } ?>
+   </div>
+  </li>
+ </ul>
+</div>
+

 

Revise this Paste

Your Name: Code Language: