Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/phpmyadmin/phpmyadmin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichal Čihař <michal@cihar.com>2014-05-09 20:06:42 +0400
committerMichal Čihař <michal@cihar.com>2014-05-09 20:07:39 +0400
commit3eccb9eb2614a9188bcafb54971b9a096421ab11 (patch)
treead55c135f4e2fc97c5e91116b8a9023d598f67ee /examples/signon-script.php
parent616e732c37f9d9685b14bf5a3f027d8b2c3d6bb9 (diff)
Improve signon-script example
Signed-off-by: Michal Čihař <michal@cihar.com>
Diffstat (limited to 'examples/signon-script.php')
-rw-r--r--examples/signon-script.php10
1 files changed, 9 insertions, 1 deletions
diff --git a/examples/signon-script.php b/examples/signon-script.php
index e333f2ee1b..1c2a4b957a 100644
--- a/examples/signon-script.php
+++ b/examples/signon-script.php
@@ -23,7 +23,15 @@
*/
function get_login_credentials($user)
{
- return array('root', '');
+ /* Optionally we can use passed username */
+ if (!empty($user)) {
+ return array($user, 'password');
+ }
+
+ /* Here we would retrieve the credentials */
+ $credentials = array('root', '');
+
+ return $credentials;
}
?>