You can use several query string parameters in the image URL so that Sitecore changes the image. The image must be a Sitecore Media element.
The following is a list of supported query string parameters:
- w: Width in pixels
- h: Height in pixels
- mw: maximum width in pixels
- mh: maximum height in pixels
- la: Language (the default language is context)
- vs: ( - )
- db: ( )
- bc: ( )
- as: (as = 1)
- sc: (sc =.25 = 25%)
- thn: Thumbnail (thn = 1)
- dmc: , , (dmc = 1)
, ,? as = 1 & w = 600, 600 .
, MediaUrlOptions mediaUrl:
var mediaOptions = new MediaUrlOptions {AllowStretch = true, Width = 600};
var mediaUrl = MediaManager.GetMediaUrl(mediaItem, mediaOptions);