Jump to content

RottenBananas

Members
  • Posts

    31
  • Joined

  • Last visited

    Never

Everything posted by RottenBananas

  1. Thanks for the reply Can you be more specific on 3? A new row for song per user? so a new table for each user with their songs in it? Since im copying myspace think of their database, how should i do it?
  2. Hello, I hope this is in the right section. So im trying to make myspace from scratch on my localhost to learn php. I dont know what to do with the database(im new to mysql and php). So far I have one table that holds everything...username, email, name blah blah Here are my questions: 1. Assuming my site was real and I had millions of users what are the pros/cons of having all that info in one table? I have a weird feeling having it all in one table is dumb but i dont know any better. 2. If i make separate tables how can I access the same row from diff tables. For example I have users table and files table for their pics. users has an id, how do i know that this id corresponds to these pics in the files table? 3.I want to have it so they can upload music. What field could that be? Do i need a separate field for every song they upload? or a new table for every user? Just confused on the database stuff I've never worked with them before Your help is much appreciated Thanks!
  3. Its no problem, figuring it out is the best way to learn. Having you guys around makes it much easier though! Thanks Again
  4. nevermind I figured it out using $sql="SELECT * from `users` WHERE `username`='".$_GET['username']."'"; Thanks alot guys!
  5. Hey thanks for the reply, I kinda get it but confused on how to code it. So far I have a home.php, profilecp.php and profile.php home is the page shown after the user logs in with links to profile and update profile(profilecp.php) the profilecp.php updates the database with the users entries. so I know how to fetch from the database under this users session ID in profile.php but I guess the whole point is to not use sessions on profile.php since i want the profiles to be public....Im confused Anyone get me? P.S this isnt a live site...just doing it to learn php, its on my localhost...so im assuming i have to create .htaccess myself and stick it in the same directory as the rest of my files?
  6. Hey guys, I decided to finally learn php. I asked a friend to gimme a project that would involve a little bit of everything. He told me to make a simple version of myspace. So heres what i'm stumped about. I have my login and everything setup. So a user can setup their profile and view it once they are logged in (using sessions). I want to make it so that anyone can view their page i.e by going to mysite.com/usernameX you would see the usernameX's profile without you having to be logged in. Sorry If I sound vague Im a true newbie. If you guys know how myspace works thats what im looking for. You register, setup your profile, and then anyone can see it by going to myspace.com/username. Thanks for the help!
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.