|
|
||||||
|
||||||
| Index Link To US Private Messages Archive FAQ RSS | ||||||
| Web Programming Discussion Forum Working with an API? Developing a plugin? Writing a Mod or script for your favorite blog, Web 2.0 site or Forum? Welcome. |
Share Thread: & Tags
|
||||
|
![]() |
|
|
LinkBack | Thread Tools | Display Modes |
|
|||
|
A hello from a newcomer. Let me try this! :)
I wonder if anybody knows if it is possible to let a user (of a forum for example) know that he has Caps Lock turned on when he is typing a username and password into a login form? Did anybody meet whit a thing like that on any website? Or does anybody have an idea what kind of server technology supports this if any (HTML, PHP, ASP,...)? |
|
|||
|
If you want the alert to occur while the user is typing (or at least before they move on to the next page) use a client side script (i.e. Javascript). If you want to alert them after processing the page, any server side script will do.
Either way, you could check each character individually and compare it to its ascii code. If the code falls within a certain range you know that it is a capital letter. (I don't know what the range of capital letters is off the top of my head) You could also use a statement such as: if ucase(password)=password then 'This password is all uppercase end if ucase is the vbscript command for converting a string to all upper case. IMO you should do this after the user submits info AND the information doesn't match. That way if a user really does have an all uppercase password, he/she isn't bothered everytime they try to enter their password. |
|
|||
|
There is an open source caps lock alarm available, and can be found with such a simple search term. Reason I didnt tell you before is that every one seems to post a boat load of queries in forums and dont even think to run a search for the answer. Fact is typing three words to a search engine would have produced an immediate result, rather than waiting for replies here. Why does nobody apply an effort?
|
![]() |
|
| Thread Tools | |
| Display Modes | |
|
|
|
WebProWorld |
Advertise |
Contact Us |
About |
Forum Rules |
MVP's |
Archive |
Newsletter Archive |
Top |
WebProNews
WebProWorld is an iEntry, Inc. ® site - © 2009 All Rights Reserved Privacy Policy and Legal iEntry, Inc. 2549 Richmond Rd. Lexington KY, 40509 |