HTML framework IFrame combines JS to transfer values between main page and sub page

The following DEMO that the main page and the sub page pass values to each other. If you only need the sub page to trigger the main page function, you only need [parent.window. Your function] DOM method:Parent window operation IFRAME: window.frames["iframeSon"].documentIFRAME operation parent window: window.parent.documentjquery metho ...

Posted on Tue, 05 Nov 2019 15:29:48 -0500 by Siann Beck

General instruction verification of vue input tag

The mobile terminal usually requires some verification for the input tag, and the instructions of vue can achieve the perfect verification anticipate result <input v-model="times" :data-last_value="lastTimes" v-int v-max="8" v-min="2" /> The value of the attribute data last value is used to cache the value entered after the user's input b ...

Posted on Tue, 05 Nov 2019 11:36:35 -0500 by misty

iOS knowledge combing asynchronous programming - coobjc learning

Asynchronous programming is a hot topic in recent years. Today, we will talk about asynchronous programming and coobjc in iOS platform. First of all, to answer the question, why do we need asynchronous programming? In the early years, people were used to running a thread to perform time-consuming tasks, even if the time-consuming task was not C ...

Posted on Tue, 05 Nov 2019 05:18:42 -0500 by nishanthc12

The problem of a parseInt function found by javascript random number

A few days ago, I wanted to forge some data and used random numbers. I didn't write it myself, so I searched the Internet and found this article: https://www.cnblogs.com/starof/p/4988516.html  . Then I tested it and found a problem about parseInt. Finally, we found that the reason for the problem was that we didn't know enough about this ...

Posted on Mon, 04 Nov 2019 22:41:58 -0500 by moboter

Several benefits of using HooX to manage React state

HooX Is a lightweight React state management tool based on hook. It can be used to manage the global state of React application conveniently, with simple concept and perfect support for TS. 1. Embrace more functional components From the hook of React@16.8 to the hook of vue@3 composition-api It can be concluded that functional components are t ...

Posted on Mon, 04 Nov 2019 18:08:41 -0500 by pollysal

On node events module

Module overview In node, events module is one of the core modules. Almost all the common node modules inherit events module For example, net.Server will trigger events every time there is a new connection, fs.ReadStream will trigger events when the file is opened, stream will trigger events when the data is readable, etc The events module itsel ...

Posted on Mon, 04 Nov 2019 16:50:32 -0500 by etherboo

Native js implementation of each method

There is an each method in jquery to simplify and facilitate circular operation.Then es produced a forEach method. Although the two methods are similar in usage, they cannot handle object types. And the continue effect cannot be achieved through return true.In addition, there is an every method. Although this method can achieve the continue eff ...

Posted on Mon, 04 Nov 2019 15:59:44 -0500 by MikeL

One server of front and back end separation project is online

I. purchase server Here are some notes When you choose to configure linux system, you'd better choose centos7 + instead of centos6+ To configure the development port, it is better to open the common port and the operation port to prevent the subsequent nginx startup page from being unable to access the ip. Generally, the port permission is no ...

Posted on Mon, 04 Nov 2019 13:35:13 -0500 by jumpfroggy

Swoole and thinkp5 develop WebSocket online chat communication system

To use Swoole in ThinkPHP, you need to install the think Swoole composer package, provided that the system has installed the Swoole PECL extension* To install think swoole, execute the composer command in the project root directory of tp5: composer require topthink/think-swoole   If you don't say much, go straight to the code: ...

Posted on Mon, 04 Nov 2019 09:58:41 -0500 by tecktalkcm0391

How to load template file with MarkDown rich text editor

We only need a piece of loading code to finish the mark down loading template file. $("#md-demo").bind('click', function () { $.get("/Lib/MarkDown/examples/test.md", function (md) { testEditor = editormd("test-editormd", { width: "99%", height: 740, path: "/Lib/MarkDo ...

Posted on Mon, 04 Nov 2019 09:25:12 -0500 by villas