Se rendre au contenu
Menu
Cette question a été signalée
1 Répondre
4370 Vues

Hi, I have a text field.

my_field = fields.Text()

I want to disable copying and paste(ctrl+c, ctrl+v) from intput with java script or python. How i can do it, thanks.

Avatar
Ignorer
Meilleure réponse

Hi Pavel,

This thing you can do with the jquery event handlers cut, copy & paste.

Code: 

    $ (document) .ready (function () {

       $ ('# txtInput'). on ("cut copy paste", function (e) {

          e.preventDefault ();

       });

    });

Thanks ....

For more information Contact us:- https: //kanakinfosystems.com/odoo-development-services

Avatar
Ignorer
Publications associées Réponses Vues Activité
0
janv. 21
44
2
déc. 23
12724
3
juil. 22
23100
2
juin 21
18548
0
sept. 20
3718