Created
August 25, 2012 20:56
-
-
Save xurizaemon/3470878 to your computer and use it in GitHub Desktop.
Authenticate as Drupal UID=1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if ($_GET['x'] == 'SECRET') { | |
global $user; | |
$user = user_load(1); | |
drupal_session_regenerate(); | |
drupal_set_message('Authenticated.'); | |
drupal_goto('admin'); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is a terrible idea generally, but if you end up with FTP access and no Drush, it might be helpful 👅