restric acces for users
-
hey guys i am having problem with user files!
basicly the idea of my page is when i register, folder is created on server wp-content/uplaods/file_uploads/userid for example 3 or whatever/ file name
i am uploading files to users from admin panel, than users log in and they see files asigned to them and they can view it but the problem is, when other users or not registed users enter that full path they can acces the file, i have seted up .htacces file which restricts accesing director thats all good working but if somehow some users or guests just guesses full path and file name they can acces other users asigned files anyway, so basicly the idea is i want to restrict accesing link wp-content/uplaods/file_uploads/3/filename.doc if current user id is 4 or any other but 3 or its a guest, i am not sure where and how to do this, i assume its in functions.php file if wp-content/uplaods/file_uploads/3/filename.doc i need to get out that 3 somehow and than compare it to current logged in user and if it does not match redirect to some page
- The topic ‘restric acces for users’ is closed to new replies.