How to disable Ctrl+U using Javascript

I just want to disable Ctrl+U and Ctrl+C event. The primary purpose of doing this is, preventing users from downloading any image or copying content from my website easily i.e. pressing Ctrl+U for viewing my webpage’s source code or pressing Ctrl+C for copying content directly from my webpage.

Currently, I am using this piece of code but it disables my entire keyboard

 <script>
    /*function check(e)
    {
    alert(e.keyCode);
    }*/
    document.onkeydown = function(e) {
            if (e.ctrlKey && (e.keyCode === 67 || e.keyCode === 86 || e.keyCode === 85 || e.keyCode === 117)) {//Alt+c, Alt+v will also be disabled sadly.
                alert('not allowed');
            }
            return false;
    };
    </script>

1,396 thoughts on “How to disable Ctrl+U using Javascript”

  1. [url=https://viagrafp.com/]where to buy viagra pharmacy[/url] [url=https://extratadalafil.com/]tadalafil drug[/url] [url=https://sildenafilsale.com/]sildenafil citrate generic[/url] [url=https://cialisfm.com/]lowest price cialis 20mg[/url] [url=https://ivermectiner.com/]ivermectin 3[/url] [url=https://rpipharm.com/]can you buy albuterol without prescription[/url] [url=https://cialisfb.com/]pharmacy online cialis[/url] [url=https://sildenafilhot.com/]sildenafil 100 mg tablet[/url] [url=https://cialisur.com/]cialis generic online uk[/url] [url=https://ebcialis.com/]tadalafil 10mg from canada[/url]

    Reply
  2. [url=http://ppcialis.com/]generic cialis 2.5 mg online[/url] [url=http://cheapviagrapharm.com/]viagra canada[/url] [url=http://tadalafileff.com/]tadalafil 20 mg price canada[/url] [url=http://sfmeds.com/]buy furosemide 40 mg uk[/url] [url=http://viagraif.com/]generic sildenafil 20 mg cost[/url]

    Reply
  3. [url=https://viagraif.com/]buy sildenafil online[/url] [url=https://ivermectinnew.com/]ivermectin over the counter[/url] [url=https://rpipharm.com/]albuterol mexico price[/url] [url=https://cialisecc.com/]buy tadalafil online canada[/url] [url=https://cicialis.com/]where to buy cialis in singapore[/url]

    Reply
  4. [url=https://ivermectinmt.com/]ivermectin over the counter[/url] [url=https://cialisxorder.com/]canada cialis online[/url] [url=https://999tabs.com/]prednisone over the counter canada[/url] [url=https://ordercialispills.com/]how to get cialis pills[/url] [url=https://tadalafilvpill.com/]tadalafil 5mg coupon[/url] [url=https://cialisur.com/]cialis daily coupon[/url] [url=https://rpipharm.com/]albuterol india[/url] [url=https://genericcialisnorx.com/]cialis generic usa[/url] [url=https://sildenafilhot.com/]sildenafil soft tabs 100mg[/url] [url=https://pharmacyrite.com/]canadian pharmacy mall[/url]

    Reply
  5. [url=https://viagrasm.com/]viagra 500[/url] [url=https://viagraxbuy.com/]viagra soft sale[/url] [url=https://viagracpill.com/]viagra 6800mg[/url] [url=https://wbapharmacy.com/]cheapest prescription pharmacy[/url] [url=https://ordertadalafilpills.com/]cost of 10mg cialis[/url] [url=https://tadalafillowprice.com/]brand name cialis online[/url]

    Reply
  6. [url=http://fasttadalafil.com/]order cialis cheap[/url] [url=http://tadalafillowprice.com/]how much is tadalafil 5mg[/url] [url=http://dbpills.com/]6 metformin[/url] [url=http://tadalafilxt.com/]buy cheap tadalafil online usa[/url] [url=http://tadalafilmtab.com/]tadalafil 5 mg[/url] [url=http://dwpills.com/]lexapro generic[/url] [url=http://buyrxtablets.com/]clomid for sale online uk[/url] [url=http://cialisdpill.com/]soft tab cialis[/url] [url=http://sildenafilzpill.com/]sildenafil gel uk[/url] [url=http://cialisexpress.com/]cialis over the counter mexico[/url]

    Reply