Advertisement
Guest User

Untitled

a guest
Mar 27th, 2017
45
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. ok ovo je html
  2. <div class='comments'>
  3. <img src='uploads/$row[userPhoto]' width='40' height='40'>
  4. <textarea class='commentText' id='" . $row_post["commentID"]. "' name='postText' placeholder='Write a comment...'></textarea>
  5. </div>
  6. i ovo je js
  7. $(.commentText).keypress(function(e) {
  8. var post_id= $(this).attr('id');
  9. if(e.which == 13) {
  10. alert('Button succeed!');
  11. }
  12. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement