I am using both PHP and .htaccess login systems on my website.Both authentications are handled seperately(i.e php by quering database and .htaccess by including password file in root directories). PHP login directs user to the specific page and .htaccess login directs user to a specific directory that includes subdirectories and various files. As per current situation if a user wants to access directories he is required to login twice. First login directs him to a page where he finds a link and clicking on the link again prompts him to enter username and password and directs him to the directory.
Is there a way that would simplify the two authentication problem and make it one. I mean the login system should work in such a way whereif user A logs in he will be directed to the page, and if user B logs through the same login he should be directed to the directories?
Any help would be highly appreciated.