I’m making a thing which acts like chat convo, you can next another message by pressing a space key, but it didn’t work, there is a live code:
Can anyone to explain it how to order events by pressing a key each one to next message?
Thanks!
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Is this what you’re looking for: http://jsfiddle.net/VCpqs/11/ ?
You need to keep a track of which message is currently being displayed (I’m using a class
currentfor that), and accordingly hide that message and display only the next one.This is the jquery:
Good to know you got it working in a loop. I was just working to implement it in a loop as well, and this is what I got: http://jsfiddle.net/VCpqs/18/