Javaスクリプトを使用して画面の幅と画面の高さを見つける方法
5 に答える
1
私はあなたがこれを探していると信じています
// Get the window dimensions
var $window = $(window);
var wWidth = $window.width();
var wHeight = $window.height();
于 2013-08-01T12:38:38.350 に答える
1
使用する
$(function() {
$.post(window.location, { width: screen.width, height:screen.height }
});
于 2013-08-01T12:39:18.267 に答える
1
ここに答えがあります
JS
$("#width").val($(window).width());
$("#height").val($(window).height());
HTML
Width<input type="text" name="width" id="width">
Heigth<input type="text" name="height" id="height">
于 2013-08-01T12:47:58.800 に答える