I am implementing a channel system on my website. I have all the channel related information stored in a database and when someone clicks on a channel I do something like this: www.website.com/channel?id=4
. Upon loading the channel.php
, I use PHP to retrieve all the variables and necessary files.
I noticed many video hosting sites with channels have their url look like something like this: www.website.com/channel/channelname
. Upon interacting on that page, the url then looks like www.website.com/channel/channelname/playlist
when I click the playlist tab.
- Do these sites create folders per channel/user?
- Does that mean each channel/user has an autogenerated file called (in the example above)
playlist.php
? - How can I set the url
www.website.com/channel/channelname
to load theindex
in that folder? - In question 2, rather than having the
playlist.php
file in each and every single channel folder, somehow accessplaylist.php
while not creating a folder. How can I make a template file rather than creating many instances of the file? - Is there a way to make the URL appear as
www.website.com/channel/channelname
without creating the folderchannelname
?
Aucun commentaire:
Enregistrer un commentaire