automatize login

Help
2009-12-02
2013-06-06
  • Is there any way how to skip login form? On developers machine I could skip that for sure.

    I'm using adminer_object, so I could only submit the form and I'm logged in - still looking for an option to skip this process and start on "select database" screen.

     
  • What if i need to specify password in url too? I'm using it primarily on localhost, so there is no need to be careful with "root:root" access… I don't want to reconfigure mysql password to 'nothing'.
    Thanks! Adminer is great

     
  • Jakub Vrána
    Jakub Vrána
    2010-01-27

    You can specify it in PHP configuration setting mysql.default_password or mysqli.default_pw. Other option is to create extension with credentials method.

     
  • Very useful information here. Just to share, what I did was change this:

    function credentials(){
    return array($_GET["server"],$_SESSION["usernames"][$_GET["server"]],'MY PASSWORD HERE');
    }
    

    This is line 153 in version 2.3.1 of Adminer. Next, logging in to:

    http://adminer.sourceforge.net/adminer.php?server=localhost&username=USER

    Will force an automated login. GREAT!

     
  • Jakub Vrána
    Jakub Vrána
    2010-04-08

    Take a look at extension documentation. You don't have to hack the source code and do it again with any further version.

     

  • Anonymous
    2012-06-26

    Sorry to bump a old thread,

    But I cant get it to auto select the database I want.

    Any Help, i get a login, but it shows all databases, I want to show only 1.

    I used this but it didnt work

            function database() {
                // database name, will be escaped by Adminer
                return 'ab526_mgadmin_roster';
            }
        }

     
  • Paul
    Paul
    2012-06-26

    After first picking a database, you can bookmark  the URL.  This way, after your next login, it will transition to the database shown in the URL.

    HTH