Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

how to use html tag <area> if the image is background image

 
david arnold
Ranch Hand
Posts: 133
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I have a background image on jsp login page which defined in css


Now I want part of the area of the image could be clicked, and I found this <area> tag which works fine together with <img> tag. Example:



But my problem is that the image work as background, even if I put it in jsp file instead of css, it will be like
, if I could not define the <img> tag, then I could not use <map> tag to associate with the <img>tag, right? Then I could not define the <area> tag.

Thanks for the help.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64629
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No can do. A background is just a background. If you want it to be clickable, don't make it a background.
 
david arnold
Ranch Hand
Posts: 133
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I see. Thank you Bear for the info.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64629
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you need layered elements you could investigate using absolute and relative positioning to place an image element behind other elements.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic