includes/template.php
changeset 208 c75ad574b56d
parent 205 c4542792db2b
child 210 2b283402e4e4
equal deleted inserted replaced
205:c4542792db2b 208:c75ad574b56d
  1471    */
  1471    */
  1472    
  1472    
  1473   function username_field($name, $value = false)
  1473   function username_field($name, $value = false)
  1474   {
  1474   {
  1475     $randomid = md5( time() . microtime() . mt_rand() );
  1475     $randomid = md5( time() . microtime() . mt_rand() );
  1476     $text = '<input name="'.$name.'" onkeyup="ajaxUserNameComplete(this)" autocomplete="off" type="text" size="30" id="userfield_'.$randomid.'"';
  1476     $text = '<input name="'.$name.'" onkeyup="new AutofillUsername(this);" autocomplete="off" type="text" size="30" id="userfield_'.$randomid.'"';
  1477     if($value) $text .= ' value="'.$value.'"';
  1477     if($value) $text .= ' value="'.$value.'"';
  1478     $text .= ' />';
  1478     $text .= ' />';
  1479     return $text;
  1479     return $text;
  1480   }
  1480   }
  1481   
  1481