+ db_query($link, "INSERT INTO ttrss_users
+ (login,pwd_hash,access_level,last_login)
+ VALUES ('$login', '$pwd_hash', 0, NOW())");
+
+
+ $result = db_query($link, "SELECT id FROM ttrss_users WHERE
+ login = '$login' AND pwd_hash = '$pwd_hash'");
+
+ if (db_num_rows($result) == 1) {
+
+ $new_uid = db_fetch_result($result, 0, "id");
+
+ print "<div class=\"notice\">Added user <b>".$_GET["login"].
+ "</b> with password <b>$tmp_user_pwd</b>.</div>";
+
+ initialize_user($link, $new_uid);
+
+ } else {
+
+ print "<div class=\"warning\">Could not create user <b>".
+ $_GET["login"]."</b></div>";
+
+ }