Ctrl+/
IE11
F11
ESC
PgUp
PgDn
<HTML>
<HEAD>
<TITLE>JS上传预览的图片</TITLE>
</HEAD>
<script>
function DrawImage(ImgD){
var preW = 300;
var preH = 400 ;
var image=new Image();
image.src=ImgD.src;
if(image.width>0 && image.height>0){
flag=true;
if(image.width/image.height>= preW/preH){
if(image.width>preW){
ImgD.width=preW;
CSS代码...
JS代码...
xxxxxxxxxx