Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/jquery/74.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript 如何计算股息的10%?JQuery_Javascript_Jquery_Html_Css - Fatal编程技术网

Javascript 如何计算股息的10%?JQuery

Javascript 如何计算股息的10%?JQuery,javascript,jquery,html,css,Javascript,Jquery,Html,Css,我有这个样本: 代码HTML: <div> </div> div{ width:200px; height:500px; background:red; } jQuery(document).ready(function ($) { var height= $('div').outerHeight(); alert(height); }); 代码JS: <div> </div> div

我有这个样本:

代码HTML:

<div>

</div>
div{
    width:200px;
    height:500px;
    background:red;
}
jQuery(document).ready(function ($) {
    var height= $('div').outerHeight();
    alert(height);

    });
代码JS:

<div>

</div>
div{
    width:200px;
    height:500px;
    background:red;
}
jQuery(document).ready(function ($) {
    var height= $('div').outerHeight();
    alert(height);

    });
目前,我保留了一个可变高度的div。
我想保留一个变量,即div高度的10%。

这是一个简单的数学问题:

 jQuery(document).ready(function ($) {
        var height= $('div').outerHeight()/10;
        alert(height);

        });

这只是一道简单的数学题…
将高度乘以
0.1

var height=$('div').outerHeight()*.1

jQuery(文档).ready(函数($){
var height=$('div').outerHeight()*0.1;
警戒(高度);
});
div{
宽度:200px;
高度:500px;
背景:红色;
}


您是否尝试过
var height=$('div').outerHeight()*10/100
var tenpct=height*0.1
?我遗漏了什么吗?可能是重复的