View Full Version : Write to <p> with JS or PHP

04-20-2011, 02:54 AM
How to I write to a <p> with JavaScript or PHP? For example, if someone entered a form (like a comment), it would display the time. Thanks to anyone who can help. :)

04-20-2011, 09:01 AM
That would be done with PHP. But semantically a paragraph element is wrong in this case (I suppose you wanna display the date the post was made on), you should use either span or div, whichever makes more sense in the context (i. e. inline or block-level element).