| Gustav Wiberg 2007-02-14, 8:01 am |
| Hi!
This is a kind of security-question....
I'm starting up a system, where several customers should be able to login with there own information.
Each company I give unique identity with "hard-coding" and each company hasits own folder...
Harding-coding, something like:
$company -> setIDCompany(1);
$company -> setIDCompany(2);
$company -> setIDCompany(3);
Diffrent folders:
customers/company1
customers/company2
customers/company3
and so on...
This isn't complicated, but when I add a new company.... ...I must be 200% sure that the IDCompany is set correct (There is a chance of setting thewrong ID for a new company or forgetting to change it)
The companys ARE NOT ALLOWED to see each others information.
Is there any good way of solving this with some sort of comparision-mechanism or something like that? Any thoughts?
Best regards
/Gustav Wiberg
|