Welcome Guest, Not a member yet? Register   Sign In
For CI 3.1.6: Seeking very simple login system, no DB, good example code
#3

If you intend to manage the login credentials manually, you could just setup an array of them in the config file.

like in config.php

PHP Code:
$config['insecure_logins'] = array("username1"=>"password","username2"=>"password",...) 

Then make your login page (form with username and password) post it to a controller and check the config login array to see if it matches.

Of course, you should secure the passwords with something and you should have a brute force detection.

I'd take the time to get one of the authentication systems and use them so you learn how to setup a legitimate authentication system so the next time you actually need something robust, you'll already know one and know how to do it.
Reply


Messages In This Thread
RE: For CI 3.1.6: Seeking very simple login system, no DB, good example code - by Kaosweaver - 10-05-2017, 06:28 AM



Theme © iAndrew 2016 - Forum software by © MyBB