I want to make my text area handle onCut
, onPaste
, onKeydown
and onKeyup
the same. I.e. they all affect the textArea the same.
I am creating the javascript as a string
and using it within Codeigniter
.
Currently, in my code below, none of the functions are working when all together, How can I fix this?
Note: when the code is only:
$javascript= 'onKeyDown || onKeyUp="exampleFunction()"';
It works fine, but doesn't work with:
$javascript= 'onKeyDown || onKeyUp || onPaste || onCut="exampleFunction()"';
Where javascript being called:
echo form_textarea('text',0,$javascript);