Ok, this is strange to me. Here is the HTML element I'm working with:
LOLZ http://www.ubuntu-pics.de/bild/14571/screenshot_030_0O2o3D.png
Photo with the inscription. Ideally, I would like it to look like this: through pure CSS:
alt text http://www.ubuntu-pics.de/bild/14572/screenshot_031_mp84u7.png
The width of the parent image element should depend on the size of the image.
I can change the markup that I need. (The text is not currently in its own div, but it can be if necessary.) Is there a way in CSS for this? I get the impression that I need to "force" the text to wrap as much as possible (which is not possible) or to make the entire width of the element dependent on only one element and ignore the other (which I have never heard before).
Is there a real way? Or do I need to use magic Javascript? (The JS solution is pretty simple, but pretty lame ...)
source
share