Is there a way to avoid hardcoding username & pswd in javscript for the login() method. Im using 21.0 ajax toolkit
var res = sforce.connection.login('username' , 'password');
Coz it becomes difficult to change the user credentials in every environment. I tried to get infor on whether sessionId can be used instead of logging in again, but did not find mush help. Can anyone please throw some light on this.
And if we have to use the login() method, Should we use the system admin credentials? Or should we create a dummy user whose pswd never changes? What is the best way to do it?