In the first code self.info contains string of single length so it works and in second case when i tried to send lengthier string it fails.
<button onclick="message()">
But when self.info contains more than one length of string than it didn't work
<button onclick="message(event)">
Am i missing something? or i am using it in wrong way?