Style = "vertical-align: bottom;" No matter what you use, you need to use JavaScript to perform online search. If you find a code and the test fails, the code is too messy to be tested.
So write it by yourself.
Copy codeThe Code is as follows:
$ (Function (){
If ($. browser. msie | $. browser. mozilla | $. browser. opera) {// IE Firefox Opera and other browsers
$ (". Productli img"). each (function (){
Var margin = 120-$ (this). height ();
((This).css ("margin-top", margin + "px ");
});
}
If ($. browser. safari) {// if it is an apple or chrome browser
$ (". Productli img"). load (function (){
Var margin = 120-$ (this). height ();
((This).css ("margin-top", margin + "px ");
});
}
})
Tested in the following browsers:
IE6, IE8, Chrome, Opear, FireFox, QQ browser, 360, aoyou, Apple
Baidu and Other IE kernels will certainly be usable if they are not tested.
We look forward to more streamlined code.