Often one needs to resize images only using client-side programming. For cases like that, I’m using a technique with JavaScript. Depending on the original size and the desired final size, it may distort a little or lose quality. But in most cases, it’s still useful.