How do I link a div
airbornflght
Houston, TX Icrontian
I'm aware that it's not kosher to do so, but I need to.
If you look here, on the left side of the page you will see three boxes. I want each box to be linked, not just the title.
I've looked online and of the two solutions I found one was javascript, which I don't want to use, and the other was css, which didn't work.
How can I do this and retain functionality?
If you look here, on the left side of the page you will see three boxes. I want each box to be linked, not just the title.
I've looked online and of the two solutions I found one was javascript, which I don't want to use, and the other was css, which didn't work.
How can I do this and retain functionality?
0
Comments
You could wrap an 'a' tag around the div (probably won't validate). Or, you could absolute-position a clear linked gif over the boxes (ick). Or, you could just link everything in the div (meh). Or, you could make the entire box an image, link the image, and assign the text as its' alt text (probably what I would do).
I could never find the creative talent to make something from scratch. I'm a typesetter, not an artist
I'm pretty bummed out about not being able to size the href to encompass the entire div. That would be so awesome. I'm thinking of the transparent gif route, but that's kind of jerry-rigged. You would think a situation like this would be provided for.
Remember, an HTML element doesn't necessary look like anything in particular. If you really want to go nuts, you can do whatever is necessary to make it work in browsers, semantics be damned. (There, I said it!) Heck, you could make the strong tag display:block and dump the entire contents in that Just test the crap out of it.
Related reading: http://meyerweb.com/eric/html-xhtml/html5-linking.html