Waiting cache events for img
Demand:
Ensure that the printing method is executed after all pictures are loaded successfully
Implementation of final code:
printMail = () => {
this.btnDisplay='none';
//Get the window object of iframe
let iframe = document.getElementsByClassName('wea-email-content-iframe')[0].contentWindow;
let img_lengt ...
Posted by Gladiator2043 on Sun, 05 Jan 2020 12:42:28 +0100
Implementation of special effect of carousel carousel with native JS
It's about this son:
First of all, let's make a simple layout (emm... Let's do something about it, anyway, it's mainly made up of js)
1 <!DOCTYPE html>
2 <html lang="en">
3 <head>
4 <meta charset="UTF-8">
5 <meta name="viewport" content="width=device-width, initial-scale=1.0">
6 <meta http-eq ...
Posted by USMarineNCO on Thu, 26 Dec 2019 19:00:16 +0100
Advanced Http protocol
What is http protocol
http protocol: Format Specification for data transmission between browser client and server
Tools for viewing the http protocol
1) Use Firefox's firebug plug-in (right click > firebug > Network)
2) Use Google's "censorship element"
http protocol content
Request (browser->Server)
G ...
Posted by SkyRanger on Sat, 21 Dec 2019 16:03:15 +0100
JS---DOM --- common.js involved in the course
//Code to format the date
//Get the specified label object
//Get the text content of the element
//Get the text content of the element
//Get the first child element in the parent element
//Get the last child element in the parent element
//Get the previous sibling of an element
//Get the next sibling of an element
//Get all siblings of ...
Posted by zTagged on Wed, 11 Dec 2019 15:18:25 +0100
jQuery click other parts of the page to hide the drop-down menu
I. key points of development
In web pages, we usually don't use select or option to achieve the pull-down menu effect, because the style of the pull-down box is ugly and difficult to beautify, so we choose to control ul display and hide to achieve the same and tall effect, but we can't click other parts of the page like the pull-down box, and ...
Posted by lmaster on Tue, 10 Dec 2019 13:49:29 +0100
js utility method record - js dynamically loads css and js script files
js utility method record dynamic loading css/js
1. Dynamically load js file to head tag and execute callbackMethod call: dynamicLoadJs(' http://www.yimo.link/static/j... ', function(){alert('loading succeeded')});
/**
* Load JS dynamically
* @param {string} url Script address
* @param {function} callback Callback function
...
Posted by NCllns on Sat, 07 Dec 2019 16:00:23 +0100
Python climbs to Boss direct employment to help you get all kinds of career salary lists in China
Preface
The text and pictures of this article are from the Internet, only for learning and communication, not for any commercial purpose. The copyright belongs to the original author. If you have any questions, please contact us in time for handling.
Author: Wang Xiang Qingfeng Python
PS: if you need Python learning materials, you can click the ...
Posted by Tuss on Wed, 04 Dec 2019 22:36:13 +0100
python crawler - basic module, you must understand!
Prefacepython crawler, web spider. Crawls the website to obtain the web page data, and carries on the analysis extraction.
The basic modules are urllib, urllib2, re, etc
(I) basic usage, examples
(1) make a basic GET request to GET the html of the web page
#!coding=utf-8
import urllib
import urllib2
url = 'http://www.baidu.com/'
# Get request
...
Posted by mcatalf0221 on Sat, 30 Nov 2019 15:05:25 +0100
PyQt5: layout, push button, radiobutton, lableImage basic usage of setting picture
Design sketch:
Navigation:
Horizontal layout
Grid layout
Vertical layout
Set up pictures with lable
The use of radiobutton
1 horizontal layout
First of all, we created a QGroupBox and put three buttons in this component
self.groupBox = QGroupBox('there are some buttons')
Then create a horizontal layout object
hbox ...
Posted by kida462 on Sat, 23 Nov 2019 18:38:12 +0100
js event object event event delegation
Event | window.event (for IE)
div.onclick = function(event ){
var event = event || window.event;
}
Event source object the object that triggered the event
event.target Firefox only has this
Event.srcelement ie only this
Both of them have
Can be used for event delegation
Event delegation
Manage e ...
Posted by dyip on Mon, 28 Oct 2019 19:31:51 +0100