How do I display comments on a webpage?

Reply

Join Date: Jan 2009
Posts: 5
Reputation: guitarscn is an unknown quantity at this point 
Solved Threads: 0
guitarscn guitarscn is offline Offline
Newbie Poster

How do I display comments on a webpage?

 
0
  #1
Jan 7th, 2009
I have forms already made that takes the user's name and input box for their comment, but I cannot figure out how to make it so that when the user clicks on Submit button, it will display on the same page in a certain style that I want (justified left with a line break between different comments, including the date it was posted). I think it has something to do with putting the information in a database and reading it, but I have no clue. Any help?
Reply With Quote Quick reply to this message  
Join Date: Dec 2008
Posts: 19
Reputation: ashafaaiz is an unknown quantity at this point 
Solved Threads: 1
ashafaaiz ashafaaiz is offline Offline
Newbie Poster

Re: How do I display comments on a webpage?

 
0
  #2
Jan 8th, 2009
Hi,
Do you have to display all the comments while the user clicking submit button? Then you must store all users and their comments ina database and retrieve it from database, you display the content in a table within the form. You just write CSS coding whatever you want to display and then include the class name in the appropriate <td> of table where you want to display the content. That's it!
Reply With Quote Quick reply to this message  
Join Date: Jan 2009
Posts: 5
Reputation: guitarscn is an unknown quantity at this point 
Solved Threads: 0
guitarscn guitarscn is offline Offline
Newbie Poster

Re: How do I display comments on a webpage?

 
0
  #3
Jan 8th, 2009
Originally Posted by ashafaaiz View Post
Hi,
Do you have to display all the comments while the user clicking submit button? Then you must store all users and their comments ina database and retrieve it from database, you display the content in a table within the form. You just write CSS coding whatever you want to display and then include the class name in the appropriate <td> of table where you want to display the content. That's it!
How do I store it in a database? I don't know any PHP, but someone told me to ask here
Reply With Quote Quick reply to this message  
Join Date: Jan 2009
Posts: 5
Reputation: guitarscn is an unknown quantity at this point 
Solved Threads: 0
guitarscn guitarscn is offline Offline
Newbie Poster

Re: How do I display comments on a webpage?

 
0
  #4
Jan 8th, 2009
Okay, just in case I might have confused some people about what I need, I'll try to make it clearer. I'm going to use an example from Slashdot:


I post website news on my homepage:


http://i40.tinypic.com/zj9lqh.jpg





When a user clicks on 'Comments,' it leads to another page that looks just like the homepage, except it only displays that one news article that the person clicked on 'Comments' for:


http://i44.tinypic.com/2prttaq.jpg





The format I want for the Comments section below the article is "Posted by [insert user here] on [insert date here]" followed by a break, the person's message, then a break, then a line to separate the comment from the next comment that will be displayed below that.

The Comment input part between the article and the comments would look like this (just not as ugly):


http://i44.tinypic.com/qs77s3.jpg


Which is the only thing I already have (the input boxes and Submit button I already have done, but the Submit button doesn't do anything).
Reply With Quote Quick reply to this message  
Join Date: Jan 2009
Posts: 5
Reputation: guitarscn is an unknown quantity at this point 
Solved Threads: 0
guitarscn guitarscn is offline Offline
Newbie Poster

Re: How do I display comments on a webpage?

 
0
  #5
Jan 8th, 2009
I checked this out: http://www.gentlesource.com/comment-script/

But I wasn't sure which snippets of code I needed to copy out to make the information from the form on my website page be put into a MySQL database I just created.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC