Topic: Login Company name text box input instead of dropdown

Would it be possible to make some type of mod in order to include a text box instead of a dropdown?

I am setting FA up for an accountant and he does not want to show his other clients name.

I have had a go at hacking the login.php file but I cant get it to work for me

Help with this would be great is I bashing my head HARD against my desk and it's becoming unstable

Re: Login Company name text box input instead of dropdown

Hi fabmendez,
I have the same situation. It would also be nice to have a lost password function.
I did manage to remove the dropdown and login to different companies, however, as soon as you delete a company, the codes that lead access to companies might change.

It seems that such a change requires a modification of how the company index is obtained. At the moment it is searched from the file config_db.php, I think it would have been better to have it stored in its own MySQL table. But that requires a change to the whole front-end of FA.

Anyone with ideas in this area?

Re: Login Company name text box input instead of dropdown

To remove the drop down box and replace it with a text box:

1) in the files access\login.php :

remove the following line

echo "<tr><td>"._("Company")."</td><td><select name='company_login_name'>\n";

insert after the line   

password_row(_("Password:"), 'password', $password);

the following line:

text_row(_("Company"), "company_login_name", $value, 20, 30);

Now in the login screen you have to enter in the company textbox the number of the company as defined in the config_db.php file.

You can change the number in the config_db.php file in text, like ABC. But if you do so, remember to change also the corresponding folder name in the folder company.

Re: Login Company name text box input instead of dropdown

This issue has been comprehensively fixed where you can enter the nickname of the company and not the number of the company in the array (anyone can just enter numbers sequentially from 0 onwards...).

Look up:
http://mantis.frontaccounting.com/view.php?id=1768
and get the code from there.