M.O.S. Studios Posted April 30 Share Posted April 30 Hey Everyone, I own a business (unrelated to programming). To make my life easier I made some php apps that automate some of the paperwork I have to do. Does any one know a good framework that will allow me to put these behind a username and password? ideally, it would be something really simple to use. I want to avoid having to learn all the intricacies of something like drupal. In my mind, I picture a software that I install, put all my files in one directory, and those files now can only be accessed though this software . any thoughts? Quote Link to comment https://forums.phpfreaks.com/topic/320266-quick-members-area/ Share on other sites More sharing options...
requinix Posted April 30 Share Posted April 30 How simple and how user-friendly do you want it? You can configure your web server to do authentication with a simple list of usernames and passwords, but it's not a fancy solution: you have to manage the list yourself, and the authentication prompt is very plain. The username is available to PHP, if you want to do something with it after the authentication happens. Quote Link to comment https://forums.phpfreaks.com/topic/320266-quick-members-area/#findComment-1622790 Share on other sites More sharing options...
Solution M.O.S. Studios Posted April 30 Author Solution Share Posted April 30 54 minutes ago, requinix said: How simple and how user-friendly do you want it? You can configure your web server to do authentication with a simple list of usernames and passwords, but it's not a fancy solution: you have to manage the list yourself, and the authentication prompt is very plain. The username is available to PHP, if you want to do something with it after the authentication happens. Fancy isn't important as I am the only one using it. However easy is ideal. I was thinking of using htaccess, htpasswd, .htaccess. I have never used those before, but I think they will be pretty simple to set up. My only concern is that I use Ajax to reference other pages, and I am worry that will interfere Quote Link to comment https://forums.phpfreaks.com/topic/320266-quick-members-area/#findComment-1622791 Share on other sites More sharing options...
requinix Posted April 30 Share Posted April 30 htaccess/htpasswd stuff works as part of the HTTP protocol, much like cookies. Same-domain AJAX shouldn't know or care that it's happening. Quote Link to comment https://forums.phpfreaks.com/topic/320266-quick-members-area/#findComment-1622792 Share on other sites More sharing options...
M.O.S. Studios Posted April 30 Author Share Posted April 30 19 minutes ago, requinix said: htaccess/htpasswd stuff works as part of the HTTP protocol, much like cookies. Same-domain AJAX shouldn't know or care that it's happening. Ah, so if I log in on one page, and make a Ajax call to another page; it should work? Even if the link is an absolute address like https://myodomain/page.php opposed to page.php? Quote Link to comment https://forums.phpfreaks.com/topic/320266-quick-members-area/#findComment-1622793 Share on other sites More sharing options...
requinix Posted April 30 Share Posted April 30 "Absolute address" is just you explicitly telling the browser what you want instead of letting it fill in the blanks itself. There's no difference between an absolute URL and a relative URL if they're both referring to the same resource. Quote Link to comment https://forums.phpfreaks.com/topic/320266-quick-members-area/#findComment-1622797 Share on other sites More sharing options...
M.O.S. Studios Posted May 1 Author Share Posted May 1 this worked exactly as needed! Quote Link to comment https://forums.phpfreaks.com/topic/320266-quick-members-area/#findComment-1622893 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.