Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
237 views
in Technique[技术] by (71.8m points)

.htaccess - Protect files in folder on hosting linux using codeigniter php

Im doing a little application write in php with codeigniter hosted in hostinglinux i had no problems with create codeigniter interface with user login to access the application

now i have a problem... i want to create some folder for the user to store some .pdf file like this picture enter image description here

what can i do to protect every single users folder with the same password to login in the codeigniter application ? my idea/goal is

username:user_a pass:pass_user_a

for displayng the files in the folder of user_a (that is on hosting linux) the user must insert the password

anyone can help me ? sorry for the baddest english ever

question from:https://stackoverflow.com/questions/65903570/protect-files-in-folder-on-hosting-linux-using-codeigniter-php

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

You have a solution in the following link which use CI framework and session to protect each user file:

Solution for document protection with session in CodeIgniter


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...