But I doubt you want to convert width="50%" to width="50" as 50 pixels is much different from 50% of the screen.
Much more likely, is to remove the width attribute and replace it with either a new "class" attribute or even an inline style attribute such as style="width:50%;" or something else that sets the limit for the width of the resulting image.
|