I have a Modal CSS class that is absolutely positioned, z-indexed above it by the parent, and perfectly positioned using jQuery. I want to add a carriage image (^) to the top of the modal window and have looked at using the :before CSS pseudo-selector to make this clean.
The image should be absolutely positioned and z-indexed over the modal, but I did not find a way to add the appropriate class to the image in the content attribute:
.Modal:before{ content:url('blackCarrot.png') } .ModalCarrot{ position:absolute; left:50%; margin-left:-8px; top:-16px; }
Second best option - can I add inline styles to the content attribute?
css pseudo-element modal-dialog
RSG Jul 12 '11 at 17:40 2011-07-12 17:40
source share