Sometimes, when uploading an image, because the image is too large, it not only occupies space and consumes traffic, but also affects the size of the image (the size of the image is different ). The following is a method for scaling images without distortion. In this way, no matter how large the uploaded image ruler is, it will be automatically compressed to the range where we set the size value. It has been tested and proved to be practical. Sometimes, when uploading an image, because the image is too large, it not only occupies space and consumes traffic, but also affects the size of the image (the size of the image is different ). The following is a method for scaling images without distortion. In this way, no matter how large the uploaded image ruler is, it will be automatically compressed to the range where we set the size value. It has been tested and proved to be practical.