Skip to content

Commit

Permalink
escaping of user provided input (fixes #185)
Browse files Browse the repository at this point in the history
  • Loading branch information
miguelgrinberg committed Dec 20, 2015
1 parent 7089bc2 commit 68efeac
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion example/templates/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
// event handler for server sent data
// the data is displayed in the "Received" section of the page
socket.on('my response', function(msg) {
$('#log').append('<br>Received #' + msg.count + ': ' + msg.data);
$('#log').append('<br>' + $('<div/>').text('Received #' + msg.count + ': ' + msg.data).html());
});

// event handler for new connections
Expand Down

0 comments on commit 68efeac

Please sign in to comment.