Tag:js

  • JS implementation of simple calendar effect

    Time:2020-11-30

    In this paper, we share the specific code of JS to realize the simple calendar effect for your reference. The specific content is as follows Knowledge points 1. Introduce my Toolkit2. Use JavaScript built-in object date Operation effect code <!DOCTYPE html> <html lang=”en”> <head> <meta charset=”UTF-8″> <title>Title</title> <style> *{ margin: 0; padding: 0; } #box{ […]

  • JS realizes the function of scanning QR code with code scanning gun

    Time:2020-11-27

    The scanning gun scans the QR code as follows: Business needs to generate two-dimensional code data, and use the code gun to scan the data and upload to the server. First on the code, and then improve the point of attention this.start = new Date().getTime() let code = ” let lastTime, nextTime let lastCode, nextCode […]

  • JS judge the instance code of IP address not beginning with 127

    Time:2020-11-18

    JS verify the loopback address, IP address cannot start with 127 The loopback address (127. X.x.x) is the loopback address var ipNotStartWith127 = function(ip) { try { var data = ip.split(“.”), ip1; return 4 == data.length && 127 !== parseInt(data[0]) } catch (e) { return !1 } } console.log(ipNotStartWith127(“127.0.0.1”)); // false console.log(ipNotStartWith127(“192.168.1.1”)); // true PS: […]

  • Explain the method of JavaScript modifying registry

    Time:2020-11-17

    This example is mainly implemented by the related methods of the WSHShell object. WSHShell object is the built-in object of WSH (WSH is the abbreviation of windows ing host, embedded in the script language working environment of Windows operating system). It is mainly responsible for the local running of programs, the processing of registry, the […]

  • JavaScript modify registry instance code

    Time:2020-11-16

    Description of the security setting key in the registry: Registry path: HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Zones 1. The zones entry contains entries representing each security zone defined for the computer. By default, the following 5 areas (numbered from 0 to 4) are defined: Value setting   —————————— 0 my computer 1. Local intranet zone 2. Trusted sites zone […]

  • JS and jQuery methods to terminate the sending Ajax request

    Time:2020-11-7

    This article describes how JS and jQuery terminate the Ajax request that is being sent. For your reference, the details are as follows: Core: call the abort method on the XMLHttpRequest object The Ajax method of jQuery has its own timeout setting parameters: $.ajax({type:’POST’, url:’b.php’, data:”, timeout:5000, success:function(){ } }) meanwhile 1. The data type […]

  • JS implementation of music navigation effect

    Time:2020-11-7

    In this paper, we share the JS implementation of music navigation effect specific code for your reference, the specific content is as follows Knowledge points One audio.play () play audioTwo audio.currentTime =0 play from the beginning3. Introduce the tool library Operation effect< After the mouse enters, plays the audio code <!DOCTYPE html> <html lang=”en”> <head> […]

  • Realization of music piano special effects with JS

    Time:2020-10-21

    In this paper, we share the JS implementation of music piano specific code for your reference, the specific content is as follows Knowledge points 1. Keydown keyboard press event2. EV [‘keycode ‘] gets the current key3. Introduce the tool library Operation effect 1-9 control keys code <!DOCTYPE html> <html lang=”en”> <head> <meta charset=”UTF-8″> <title>Title</title> <style> […]

  • JS realizes the magnifier effect of e-commerce product display

    Time:2020-10-19

    In this paper, we share the specific code of JS implementation of e-commerce product display magnifier for your reference. The specific content is as follows Knowledge points 1. Use children to get word tag group2. Find the current mouse coordinates3. Collision detection4. The size of the box is synchronized by proportion Operation effect code <!DOCTYPE […]

  • Implementation of linkage menu effect with JavaScript

    Time:2020-10-18

    An article about JavaScript special effects, today to bring you linkage menu effects, this may be a series of Oh! design sketch As before, first send out the renderings, and then explain. code <!DOCTYPE html> <html> <head> <meta charset=”utf-8″> <meta http-equiv=”X-UA-Compatible” content=”IE=edge”> <title></title> <link rel=”stylesheet” href=””> </head> <body> <h1>Linkage menu</h1> <select onchange=”ld();”> < option value […]

  • Implementing asynchronous interaction with Ajax + JS

    Time:2020-10-14

    When it comes to asynchronous interaction, people will say Ajax, as if Ajax technology has become synonymous with asynchronous interaction. Next, we will study the core object of Ajax! There are four steps to realize asynchronous interaction with Ajax Creating Ajax core objects Establishing a connection with the server Send request to server Receive data […]

  • A simple and practical example of Ajax with JS

    Time:2020-10-12

    This paper describes the simple and practical method of Ajax implementation in JS. For your reference, the details are as follows: //Copyright wujxping //ajax 1.2 //Update 2012-2-20 //1. Asynchronous data loading can be set by loading method get and post //2. Property setting of asynchronous synchronous mode //3. Data loading automatic timeout setting //4. Add […]