diff -r a57727e67241 -r d97cf005f674 includes/template.php
--- a/includes/template.php Fri Jul 22 23:14:06 2011 -0400
+++ b/includes/template.php Sun Sep 04 02:32:49 2011 -0400
@@ -2118,6 +2118,15 @@
function username_field($name, $value = false)
{
+ global $db, $session, $paths, $template, $plugins; // Common objects
+
+ $value = $value ? htmlspecialchars($value) : false;
+
+ $val = $value ? "value=\"" . $value . "\"" : "";
+
+ if ( $session->user_id == 1 && getConfig('autofill_username_for_guests', 0) != 1 )
+ return "";
+
$randomid = md5( time() . microtime() . mt_rand() );
$text = '