dijitalmastro Posted April 9, 2012 Share Posted April 9, 2012 Not really sure if I am posting this in the right place. I come here a lot, and have been learning a lot but I am a bit stumped: A few weeks ago I was given a Dell Poweredge 2950 II for free without hard drives. I bought 2, 2TB HDDs, installed ESXi/Vsphere then went on to installing Windows Server 2008 r2. My goal was to build a web site that 5-8 people could share media on. Videos, music, pictures, etc. I have the hard drives setup correctly, (more HDDs on order), IIS is installed, domain is setup correctly, using a free DNS from where I purchased the domain name. So I guess I am trying to accomplish a few things because I am a bit stumped: 1. Build a login page for the 5-8 private users (friends/family)2. Create folders with all the media on the main page (once logged in) that users can upload to and download from3. Have a separate folder for each user to store private files they don't want to share with anyone else. So I have php installed, can't get phpmyadmin to work, and have mysql installed ( I think correctly ). So does anyone have any tips or reading material I should be reading that is relevant to what I am trying to accomplish? Everything seems to be pretty easy to develop, but when you start throwing user rights, login pages in the mix, it started getting confusing for me. Appreciate the assistance in advance. Link to comment Share on other sites More sharing options...
justsomeguy Posted April 9, 2012 Share Posted April 9, 2012 The first thing to do would be to get phpMyAdmin to work, so the first step there is to determine why it isn't working. Other than that, each of the other things you want to do would need to be researched. So you would do some research on setting up a user registration and login system, maybe something about user authorization, using PHP to read and write files, handling file upload forms, etc. There's a description about a basic login/registration system here: http://w3schools.invisionzone.com/index.php?showtopic=12509 Link to comment Share on other sites More sharing options...
dijitalmastro Posted April 9, 2012 Author Share Posted April 9, 2012 Just so I understand, does it sound like what I am referring to may suggest a lot of PHP? Just want to be pointed in the right direction I guess. I started reading your thread, and I am learning a lot already. Appreciate your feedback/recommendations. Link to comment Share on other sites More sharing options...
justsomeguy Posted April 9, 2012 Share Posted April 9, 2012 Most of that involves PHP, yeah, but it wouldn't be a lot of work for someone who already knows PHP. Most of your work will be learning what you need to know rather than actually writing the code. I would recommend that you break it down into small pieces (uploading a file, checking for user permission, etc) and tackle each small problem rather than trying to approach the entire project as one big thing to learn. Link to comment Share on other sites More sharing options...
dijitalmastro Posted April 13, 2012 Author Share Posted April 13, 2012 Alright, I solved the issue with PHP/MYSQL/phpMyadmin - I just had to uninstall everything then reinstall and it works fine. So I have the login working correctly, but now what is the best way to setup folders for each individual user? With that being said, is there a function that can have them take files from their private folder and share them publically? Thanks! Link to comment Share on other sites More sharing options...
justsomeguy Posted April 13, 2012 Share Posted April 13, 2012 You can use mkdir to create a folder: http://www.php.net/manual/en/function.mkdir.php With that being said, is there a function that can have them take files from their private folder and share them publically?There's not a single built-in PHP function to do something that specific. It would be best to create the folders outside of the web root so that they aren't accessible through a browser, and then use a PHP script to get the files. You would tell the PHP script the user and filename and it would do its authorization to figure out if the user requesting the file has permission to get to it (either they are the same user, or the user who owns the file made it public), and then PHP would read the file and send download headers and output the file data. That's basically a PHP file download script, you should be able to find examples of that online. The database table that stores information about the files would include a field saying if the file is public or not. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.