I’ve noticed that, when going to profile pages on facebook, it directs you to the page http://www.facebook.com/profile.php?=id. I’m curious as to how exactly this works. I would like to make a website where users have different profiles and I think routing it through my profile.php would work the best. However, I’m not sure how to do that exactly. I’d like to direct to profile.php, but then I don’t think my html and css would be taken into the equation. I know you can use php and html in the same file, but how do you direct the content generated by php to the correct divs in html? Sorry if this question is a little confusing. Thanks for the help!
Share
Web apps would have user profile records in a database, with one column reserved for its
id. When a user goes towww.facebook.com/profile.php?id=5, the code in the page searches the database for a profile with an id of 5, it then displays the information for that profile by placing this data into html: