|
|||||||
New to SitePoint Forums? Register here for free!
|
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
SitePoint Wizard
![]() ![]() ![]() ![]() ![]() ![]() Join Date: Nov 2004
Location: Nelson BC
Posts: 2,309
|
divs inside anchors = bad, workaround?
I finally decided to put some effort into learning CSS so I can design sites without using millions of tables. I needed a simple photo gallery so that's where I started.
I have everything working nicely with one exception, I'm trying to do make a page where you pick one of several galleries: [ (gallery title) (gallery image with "envelope") (gallery description) ] [ (gallery title) (gallery image with "envelope") (gallery description) ] ... each [...] is a div with a border and a background. Inside each is the title on the left, another div that has an image and a border and a background, and a description on the right. Now, each outer div I had wrapped in <a href="gotothegallery"> tags. In IE6 this works when you click anywhere in the div except directly on the image. Oddly enough the text (gallery title and description) maintains its "hover" state when moused over the image, text, anywhere in the div. Also, an onclick event added to the anchor tag fires, but it won't link. I read this article and discovered it was bad to nest divs inside anchors. So...how do I make the entire outer div link to the gallery without resorting to onclicks? I can post code if needed. Cheers, Jim |
|
|
|
| Bookmarks |
«
Previous Thread
|
Next Thread
»
| Thread Tools | |
| Display Modes | |
|
|
|
All times are GMT -7. The time now is 02:57.









Threaded Mode