Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Contact

PHP 

Anyone want to help make User Registration and Admin System with me

Anyone want to help make User Registration and Admin System with me trying to put something together. That doesn't look tacky. If you got something we can put together lmk. https://#/GxqRw8

Thanks
CodeCompiler
https://#/GxqRw8
Are you paying? Find the marketplace. This isn't a recruitment forum.

Je t'aime
[Image: fpZ5a5g.png]

(Apr 22, 2022 04:39 PM)-Scrub Wrote:  Jokes on you, I'm not smart enough to know what he's talking about.
Hey buddy, your links aren't working.

You are probably not going to find anyone willing to code all of this for you for free, however if you post the PHP code that you are having problems with, then I am sure some people on here would help you out with that part.

Most people generally like to help others, but if you don't put any effort into asking your question, by providing some source, or describing your problem, then it will put people off and you will get a negative reaction.

Basically, if you cant be bothered posting some details and putting some effort into it, then why should any of us bother to help you?

You can PM me or message me on discord if you have any specific questions though, and Ill try to help you.
I found this from a site called 9lessons.info https://www.9lessons.info/2016/04/php-lo...ction.html I skimmed over it and this looks like it can at least get you started in the right direction. You can find a lot of examples you can learn from online if you look up PHP session login. If you do implement anything, make sure you are doing it with PDO and not mysql prepares and remember to never trust anything the user submits so you don't open yourself up to XSS.

Some personal tips from when I have implemented systems like this in the past, don't store plain text passwords in your database table use a hash of some sort and salt it too. On login you can store a user id in the PHP session array that you can use to identify the user with. Once you get a user system in place a good idea would be to create a class that represents a user and pulls data from the user table. This will help you when creating your admin system for example.

$sessUser = $db>selectUser($_SESSION['username']);
$activeUser = new User($sessUser);

db being a controller class that handles pulling data from your database and User being a class that represents a user. Then you can for example have a method in the user class that checks user privileges like:

//if user privallage is 2 then do some action
if($activeUser->getPrivileges() == 2){
//Do something here
}else{ //not admin maybe header to index?
header('Location: index.php');
}
Easiest solution would be to setup Laravel and use their built in solution... It will give you a few tips on how these things work and what should and shouldnt be stored in database
(Apr 14, 2020 06:29 PM)Gerira Wrote:  Easiest solution would be to setup Laravel and use their built in solution... It will give you a few tips on how these things work and what should and shouldnt be stored in database

Best recommendation imo. Either laravel or symfony.


Possibly Related Threads...
Thread / Author Replies Views Last Post
[PHP] by realsunjesterFeb 1, 2019 12:50 AM 11 510 Feb 1, 2019 12:50 AM
Last Post: Squito
[PHP] by ~RexonApr 28, 2017 01:45 PM 24 698 Apr 28, 2017 01:45 PM
Last Post: elunez
[PHP] by DisparityNov 26, 2016 03:38 AM 12 460 Nov 26, 2016 03:38 AM
Last Post: throwAway445