]> andersk Git - sql-web.git/commitdiff
git-svn-id: svn://presbrey.mit.edu/sql/mitsql@53 a142d4bd-2cfb-0310-9673-cb33a7e74f58
authorJoe Presbrey <presbrey@mit.edu>
Fri, 9 Sep 2005 04:48:30 +0000 (04:48 +0000)
committerJoe Presbrey <presbrey@mit.edu>
Fri, 9 Sep 2005 04:48:30 +0000 (04:48 +0000)
admin/index.php

index fb99d9bebe18efb685d2495ae7232fc43146006e..3bf6b3c09361c583dcb6b8093747f5c2599fe7e5 100755 (executable)
@@ -5,4 +5,21 @@ require_once('mitsql.lib.php');
 
 if (!isAdmin()) redirect('main');
 
+if (isset($i_impersonate)) {
+       impersonate($i_impersonate);
+       redirect('main');
+       exit;
+}
+
+$sql = sprintf("SELECT Username,Name,UserId FROM User WHERE bEnabled=1");
+$users = fetchRows(DBSelect($sql),'UserId');
+
+include 'tpl/head.php';
+
+foreach($users as $id=>$user) {
+       echo '<a href="',newQSA(array('impersonate'=>$id)),'">',$user['Username'],'</a> (',$user['Name'],')<br />';
+}
+
+include 'tpl/foot.php';
+
 ?>
This page took 0.087889 seconds and 5 git commands to generate.