Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $('.chatUsuariosLista').click(function() {
- idUsuario = this.id;
- $("#chatMsg").load('inc_chatMensagens.php?de='+idUsuario+'¶='+$("#para").val());
- $("#para").val(idUsuario);
- $('#chat2').attr({scrollTop: $('#chat2').attr('scrollHeight')});
- });
- <div id="chat2">
- <ul>
- <?php while ($row = $rs->fetch_assoc()) {?>
- <?php if ($_GET['de'] == $row['de']) {?>
- <li>
- <div class="bubble">
- <span class="personName">Cliente:</span> <br>
- <span class="personSay"><?php echo $row['msg']; ?></span> <br>
- <span class="time"><?php echo $row['data']; ?></span>
- </div>
- </li>
- <?php }else{ ?>
- <li>
- <div class="bubble2">
- <span class="personName2">Você:</span> <br>
- <span class="personSay2"><?php echo $row['msg']; ?></span><br>
- <span class="time2"><?php echo $row['data']; ?></span>
- </div>
- </li>
- <?php } ?>
- <?php } ?>
- </ul>
- </div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement