ggv
asked on
Putting text over an image
In order to save downloading time I would like to have one button image and then be able to programmatically put a number of different texts on the same image. I read, Nescape understands the LAYER tag, which might be used to accomplish this task. However I am looking to have a universal code that will run also on IE. Would be grateful for any hints how to do that.
ggv
ggv
<style> .myimage { background: url(img/my.gif); } </style>
...to be more precisely and for points split ;))
also consider adding width: 100px; height: 200 px; to style above in order to match image size
...to be more precisely and for points split ;))
also consider adding width: 100px; height: 200 px; to style above in order to match image size
ASKER
Makc, are you saying that if I add width and height then my image should be accordingly resized? Doesn't seem so if I try with jpeg files.
ggv
ggv
no. I am just saying you should set width/height for <div> to match image size, or it will look cropped, I think.
also, overflow:hidden; will help to avoid text overflow...
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
if you have php on your server, i have another solution that would solve the problem much easier.
ASKER
No, I do not have php unfortunately. I'll have to use devic's proposal.
Thanks a lot.
ggv
Thanks a lot.
ggv
why devic's ? why2liz proposed essentially same thing... :-O
netscape suports it.. all major browsers suports it
add style
.myimage {
bacground: ...
color: ....
...
}