char(36)
лучше SELECT UUID()
INSERT INTO table1 (id, text) VALUES ($uuid, 'text')
, где $ uuid - это значение, полученное на первом шаге.
<img style="width: 50%;" src="..." />
worked just fine for me ... Or am I missing something?
Edit: But see Shawn's caveat about accidentally upsizing.
The css properties max-width and max-height work great, but aren't supported by IE6 and I believe IE7. You would want to use this over height / width so you don't accidentally scale an image up. You would just want to limit the maximum height/width proportionately.
Чтобы пропорционально изменить размер изображения с помощью CSS:
img.resize {
width:540px; /* you can use % */
height: auto;
}