summaryrefslogtreecommitdiffstats
path: root/includes/header.php
diff options
context:
space:
mode:
Diffstat (limited to 'includes/header.php')
-rw-r--r--includes/header.php10
1 files changed, 9 insertions, 1 deletions
diff --git a/includes/header.php b/includes/header.php
index d3256c3..cb34fac 100644
--- a/includes/header.php
+++ b/includes/header.php
@@ -180,11 +180,19 @@ function topbar($links) {
//Empty first-div contains sound manager stuff
echo '<div></div>';
+ //Create Google login link! So simple... </sarcasm>
+ global $google_client_id, $mydomain;
+ $googleLoginAuth = "https://accounts.google.com/o/oauth2/auth?response_type=code";
+ $googleLoginAuth .= "&redirect_uri=" . urlencode($mydomain . 'login?op=google');
+ $googleLoginAuth .= "&client_id=" . urlencode($google_client_id);
+ $googleLoginAuth .= "&scope=email&access_type=online&approval_prompt=auto";
+ $googleLoginAuth .= "&openid.realm" . urlencode($mydomain);
+
echo ' <div class="wrapper" id="oid_hidden" >
<h2>Sign in</h2>
<div id="oid_box">
<h2 style="color:#333;">Please sign in using one of the following</h2>
- <a rel="nofollow" href="login?op=google"><img id="oid_btn" src="images/btns/signin_Google.png" alt="Sign in with Google" /></a>
+ <a rel="nofollow" href="'.$googleLoginAuth.'"><img id="oid_btn" src="images/btns/signin_Google.png" alt="Sign in with Google" /></a>
<a rel="nofollow" href="login?op=facebook"><img id="oid_btn" src="images/btns/signin_Facebook.png" alt="Sign in with Facebook" /></a>
<a rel="nofollow" href="login?op=twitter"><img id="oid_btn" src="images/btns/signin_Twitter.png" alt="Sign in with Twitter" /></a>
<a rel="nofollow" href="login?op=yahoo"><img id="oid_btn" src="images/btns/signin_Yahoo.png" alt="Sign in with Yahoo" /></a>