To obtain the calculated style in a CSS element (that is, the final style after cascading), browsers that support W3C can use the document.defaultView.getComputedSyle method. This method accepts two parameters. The first parameter is the element to be styled, and the second parameter is a pseudo-element string (for example: ":after". If there is none, it is set to null. This method returns a StyleSheetDeclaration object, and the final style property value is obtained through the getPropertyValue(propertyName) of the object. Note that the proprtyName here is of type wrold-world (eg background-color). In IE, the element.currentStyle[propertyName] method is used. Note that the propertyName here is of the worldWorld type (such as: backgroundColor). |
<<: What is the use of the enctype field when uploading files?
>>: JavaScript implementation of magnifying glass details
Docker runs multiple Springboot First: Port mappi...
1. Install cmake 1. Unzip the cmake compressed pa...
Following are the quick commands to clear disk sp...
1. Test environment name Version centos 7.6 docke...
To write a drop-down menu, click the button. The ...
Table of contents Background Configuring DHCP Edi...
Table of contents 1. Command 2. docker-compose.ym...
/******************** * Virtual File System VFS *...
Grid layout Attributes added to the parent elemen...
Introduction Recently, I needed to make a barrage...
Preface MySQL 8.0.13 began to support index skip ...
HTML code: <a onclick="goMessage();"...
Table of contents background Understanding compos...
Get the local public IP address through the conta...
1.vue packaging Here we use the vue native packag...