document.write("");
document.write("");
function DrawImage(ImgD,awidth,aheight){
var image=new Image();
image.src=ImgD.src;
if(image.width>0 && image.height>0){
flag=true;
if(image.width/image.height>= awidth/aheight){
if(image.width>awidth){
ImgD.width=awidth;
ImgD.height=(image.height*aheight)/image.width;
}else{
ImgD.width=image.width;
ImgD.height=image.height;
}
/*ImgD.alt="bigpic" */
}
else{
if(image.height>aheight){
ImgD.height=aheight;
ImgD.width=(image.width*awidth)/image.height;
}else{
ImgD.width=image.width;
ImgD.height=image.height;
}
/*ImgD.alt="bigpic" */
}
}
}