Jump to content

Comment system... PHP/MYSQL... just like youtube


rx3mer

Recommended Posts

Hi

I`m making new website about some music and videos and I want guests to be able to comment on each song... I know some php but i have never done something big like this. I know how to make for example comment box for one page but Im not sure about the other pages. If i do it one by one its going to take a lot of writing for each page and the pages are a lot.

 

Is there simple way to make something like this.

 

If you didn`t understand me take for example youtube... users can comment on each video.. this is what im trying to do

 

Thanks

Raddy  :P

 

[attachment deleted by admin]

What is your current setup? One page for every song? If so then at the minimum you are going to have to write at every page:

 

include('modules/comments/index.php');

 

Edit: nevermind read it wrong

 

What do you actually want in the system? user registration/login, promote/demote, mark as spam?

only the comments but as i tryed to explain i want comment input for each different page, so people are going to be able to comment for each section

 

for example

 

Page1: Eminem - comment

 

Page2: Timbaland - comment

 

Page3....

 

if i use

  Quote
include('modules/comments/index.php');
this is going to echo the same comment everyware i put it... I dont want this.

 

 

  Quote

this is going to echo the same comment everyware i put it... I dont want this.

 

No it is not as it would use the parameters in $_GET or $_POST. Anyway you can use one page for all songs as they all will look the same except will differ in content.

i will think about it but imagine if i have 20 songs on page with 20 pictures with 20 play sample buttons and allo thouse information about them...

Thats why i want to make the comments seperated so people can coment on each song/artist... but i got no idea how to make it simple rather than making manualy myslq rolls and connect to them...

 

I feel like I am missing something here as the answer seems too simple. You pass in the artist/song in the URL like so.

www.example.com/song.php?artist=Bond&song=Shine

 

and the will query the DB for all comments for that song, loop through the result and you're done.

 

There is no need to write code for each song/page.

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.