[Greasemonkey] Login script,
problem with international chars and privacy concerns
Anton Berezin
tobez at tobez.org
Fri Aug 18 15:38:13 EDT 2006
On Fri, Aug 18, 2006 at 02:28:13PM +0200, Arvid Andersson wrote:
> I am new to greasemonkey, I am trying to write a script that will
> automatically log in to a website that requires a username and a password.
> The password manager does not work on this site for som reason. I can enter
> data into the login fields with the following code:
>
> var username = document.getElementById("navbar_username");
> username.value = "sample_uname";
> var password = document.getElementsByName("vb_login_password");
> password[0].value = "sample_pword";
>
> However, my username contains swedish characters and they become garbled if
> I enter them this way. I also tried replacing them with html code
> ("ö") but that did not work either. Is there a way to specify the
> character encoding for a userscript? Perhaps that would solve the problem.
>
> A second concern is that the password is stored in plain text. I wonder if
> it is possible to use the firefox password manager from the script?
>
> I appreciate any help. Arvid Andersson.
Instead of doing this, you might investigate why password manager does not
work, and make your script to fix the cause instead. Most likely the fields
in question have autocomplete="off" attributes. So the easiest thing to do
is to investigate that.
Come to think of it, you might not need to write a script of your own, there
is a number of existing scripts that do the same. Look at "Allow Password
Remembering" and probably some other scripts here:
http://userscripts.org/tag/password
Hope this helps,
\Anton.
--
We're going for 'working' here. 'clean' is for people with skills...
-- Flemming Jacobsen
More information about the Greasemonkey
mailing list