com web/doc-editor: Use name instead of login for Github account ; Better encode display_name return by Stackoverflow oauth: index.php
| From: | Yannick Torres | Date: | Wed, 30 Jul 2014 18:15:24 +0000 |
| Subject: | com web/doc-editor: Use name instead of login for Github account ; Better encode display_name return by Stackoverflow oauth: index.php | ||
| Groups: | php.doc.cvs | ||
| Request: | Send a blank email to doc-cvs+get-12678@lists.php.net to get a copy of this message | ||
Commit: daa17ee788ced6256c9b2522865d445944172048
Author: Yannick Torrès <yannick.torres@gmail.com> Wed, 30 Jul 2014 20:15:24 +0200
Parents: 52259c132a6912fafda475aec31b698f21d99f47
Branches: master
Link: http://git.php.net/?p=web/doc-editor.git;a=commitdiff;h=daa17ee788ced6256c9b2522865d445944172048
Log:
Use name instead of login for Github account ; Better encode display_name return by Stackoverflow
oauth
Changed paths:
M index.php
Diff:
diff --git a/index.php b/index.php
index afecd3b..fb476cc 100755
--- a/index.php
+++ b/index.php
@@ -151,7 +151,7 @@ if (!isset($_SESSION['userID']))
$jsVar .= "
auth.service =
\"".$_SESSION['oauth']['identService']."\",
auth.serviceID = \"".$user->id."\",
- auth.login = \"".$user->login."\",
+ auth.login = \"".$user->name."\",
auth.email = \"".$user->email."\";
";
@@ -180,7 +180,7 @@ if (!isset($_SESSION['userID']))
auth.service =
\"".$_SESSION['oauth']['identService']."\",
auth.serviceID = \"".$user->items[0]->user_id."\",
- auth.login = \"".$user->items[0]->display_name."\",
+ auth.login =
\"".utf8_encode(html_entity_decode($user->items[0]->display_name))."\",
auth.email = \"\";
";