Welcome to Geeklog, Anonymous Friday, November 29 2024 @ 04:33 am EST

Geeklog Forums

username focus


Anonymous

Anonymous
Someone must have done this: How do you set the cursor focus to the username when the User Functions block displays? Usually when a geeklog page is first brought up, a person should be able to type directly without moving the mouse cursor into the Username text area. Help! Tanchi
 Quote

Anonymous

Anonymous
I don't know, but you're making a big assumption that anyone who hits your site initally wants to have an account. That's probably not the case. Most folks will surf around your site first before deciding they want to join. I would say most will use the search box multiple times before ever signing up. The lurker community is usually much larger than signed-up members. For returning members, the cookie will remember them so they won't need to sign in again until it expires or they decide to log out. For me, I like the code not having focus on either one.
 Quote

Anonymous

Anonymous
I may have misread your post. If you meant when a person is trying to sign up as a New User, then yes I agree. the cursor should automatically go to the "username".
 Quote

Status: offline

wayhorn

Forum User
Newbie
Registered: 12/09/02
Posts: 1
To set focus on username text area, and e.g. if you are using layout XSilver, edit ./layout/XSilver/header.thtml, change line <body bgcolor="#404040"> TO <body bgcolor="#404040" inLoad="document.loginform.loginname.focus()"> and copy the function COM_userMenu from ./lib-common.php and paste to ./lib-custom.php, change line . '<form action="' . $_CONF['site_url'] . '/users.php" method="post">' . LB TO . '<form name="loginform" action="' . $_CONF['site_url'] . '/users.php" method="post">' . LB Hope this helps your. By the way, I am still new to Geeklog, if anything mentioned above is wrong, please let me know.
 Quote

Status: offline

richschmidt

Forum User
Junior
Registered: 11/12/02
Posts: 32
Location:Valparaiso, Indiana
Just to toss in my own 2 cents... How long do you set the cookie to remember you? I set mine pretty low - an hour or two - since I'm often accessing the sites from work. It'd be great to not have to hunt for the login box when I check in every day! And lurkers will only outnumber members if your site attracts the public. If it's primarily being used as a quasi-intranet, then you'd definitely want something like this. Besides, any common internet user is going to click in that search box before trying to type... Peace, Rich
 Quote

Anonymous

Anonymous
Normally, people aren't given the option of setting the length of time on cookies. I think this feature is pretty neat because it gives visitors a sense of empowerment. It's also very useful for people who share computers. Those who frequent the same sites regularly are probably like me. We would rather have a cookie auto sign us in rather than wasting key strokes of having to log in every day at every site. So, I don't mind a cookie w/ an expiration date of several months to a year out. I don't want to be auto logged in though at sites like brokerages, banks, etc. And, I don't want a cookie keeping me logged in for an hour if I'm only there for 10 minutes. Perhaps you're disciplined in how much time you spend surfing the net, but there's a lot of folks who waste a good part of the day on message boards, chat rooms, etc. It can get quite annoying if they're logged out by an expiring cookie in the middle of playing around. My guess is the majority of those using quasi-intranets either won't bother setting the cookie expiration or will make it an extended time period if they regularly visit that GL site. The reason I say that is because most folks don't have to share computers at work these days. They're more conditioned to either log out of a site, do a screen lock (either manual or auto-timer), or log completely off if they wander from their computers. If your site is on the internet, it will attract lurkers. The number will obviously depend on the material and whether the site can be easily found through search engines, word of mouth, links from other sites, etc. Many members will turn into part-time or full-time lurkers. Others will have their cookies set to auto log them in.
 Quote

Status: offline

rv8

Forum User
Regular Poster
Registered: 10/10/02
Posts: 105
Location:Ottawa, Canada
I set my account to remember me for a year. I log in from many different machines, but I've only needed to enter my user name and password once on each machine. The automatic log in works great.---Kevin
Kevin Horton
 Quote

Anonymous

Anonymous
In that input box put: inload="this.focus()"
 Quote

Anonymous

Anonymous
Thanks! Your code works. Except that the COM_userMenu function in the lib-common.php has to be commented out. Otherwise, there will be fatal error. Tanchi
 Quote

Anonymous

Anonymous
Oh yeah, why give members any menu options. Too funny.
 Quote

Status: offline

jadiepoo

Forum User
Chatty
Registered: 01/11/03
Posts: 43
This works great, thanks for all the suggestions here. Anyway, is there a way to disable the function if a person is already logged in? Because everytime the header loads (even after login) it'll still try to look for the form and the page will load with an error (saying the form doesn't exist, which is true). It's not a major error (you'll need to click on the "Error on page" on the bottom left corner of the screen) It's not a biggy, but if anyone knows a way to fix this (using If else maybe?) the help would be greatly appreciated.
 Quote

All times are EST. The time is now 04:33 am.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content