Lively discussions on the graphic arts and publishing — in print or on the web

Go Back   Desktop Publishing Forum > General Discussions > Web Site Building & Maintenance

Thread Tools Display Modes
Old 03-17-2007, 06:31 PM   #1
Join Date: Oct 2005
Location: Manchester, NH
Posts: 65
Default Building a specialized link

Back with another complicated problem that (I hope) has a simple solution.

Here's the situation: I have a chunk of material that I want to make into a link. The link-material includes two graphics and some text, which are configured using floats so that the text wraps around the graphics. I want to make the entire thing behave like a single button-style link -- that is, a link that has borders and rollover effects like a button -- using HTML and CSS.

When I simply surround the entire chunk, graphics and text, with an <a href> tag that has the border and other attributes set using CSS, it acts like three links: borders around both images in the link-color, the text is also in the link-color, and areas between the elements are not clickable. By adding another layer and setting a specific width and height, I was able to get the whole chunk to be clickable, but I still can't get rid of the link borders. However, this looks so ugly and clumsy that I can't help but think there's a better way. I also twitch at the thought of redoing this for every one of these buttons on the page (there are nine of them, with different dimensions), and then redoing it if I ever edit the page in future. Is there an easier way to do what I want, something that I can code only once and have it apply to all nine links, regardless of shape or size?
jwoolf09 is offline   Reply With Quote
Old 03-18-2007, 09:24 AM   #2
Kelvyn's Avatar
Join Date: Feb 2005
Location: In the Heart of the English Lake District
Posts: 1,381

Have you tried making the <a> a block element?
a {display:block;}


Web site design, hosting and marketing, Keswick in the UK Lake District

If you are planning a visit to Keswick then try Keswick Tourist Information website

Kelvyn is offline   Reply With Quote

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Avatar is now a link? gary How to Use the Forum 73 08-28-2006 06:20 PM
What to charge for web site building ? Daudio Business Matters 5 11-19-2005 11:30 PM
House-building tales ktinkel The Corner Pub 35 07-01-2005 04:45 PM

All times are GMT -8. The time now is 07:47 AM.

Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
Contents copyright 2004–2018 Desktop Publishing Forum and its members.