Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Web Programming > CSS > CSS Cascading Style Sheets
Password Reminder
Register
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
CSS Cascading Style Sheets All issues relating to Cascading Style Sheets (CSS).
Welcome to the p2p.wrox.com Forums.

You are currently viewing the CSS Cascading Style Sheets section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old March 2nd, 2006, 09:50 AM
Friend of Wrox
 
Join Date: May 2004
Location: , , .
Posts: 212
Thanks: 0
Thanked 0 Times in 0 Posts
Default aligning text in ul to top of image

Hi,

I have three entries in a ul that reveal a picture when you mouseover them, using the line-height property. Here is the css:

    ul
    {
    border: 3px solid gold;
    background:black;
    float:left;
    display:block;
    }

    li a
    {
    font: 12px tahoma;
    color: gold;
    width:100%;
    text-decoration:none;
    }

    li a:hover
    {
    vertical-align:top;
    color:black;
    background:gold;
    line-height:18;
    }

    .Paul a:hover
    {
    background-image:url(paul saunders.jpg);
    background-repeat:no-repeat;
    background-attachment:fixed;
    background-position:center;
    }

    .Sarah a:hover
    {
    background-image:url(Sarah Chilcott.jpg);
    background-repeat:no-repeat;
    background-attachment:fixed;
    background-position:center;
    }

This is the HTML:
[list]
    <li class = "Paul"><a href = "#">Gareth Rayworth - CSC General Manager</a></li>
    <li><a href = "#">Amanda Hartley - CSC Call Centre Manager</a></li>
    <li class = "Sarah"><a href = "#">Sarah Chilcott - P.A. To Gareth Rayworth</a></li>

Its a long shot but is there anything I can add to the hover classes, to make the text in the ul tag move to the top of the background-image?

Thanks in advance
Joe

__________________
\'sync\' &lt;cr&gt;
The name specified is not recognized as an internal or external command, operable program or batch file.
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
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 Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Convert Text(Sql Server Text Field) to Image(JPG) srinivas72 ADO.NET 2 February 13th, 2009 06:31 PM
SELECT TOP n NOT SELECTING TOP n! ibi SQL Language 8 March 30th, 2005 08:08 PM
Aligning Text in a Listview Control? xgbnow VB How-To 1 September 30th, 2004 06:37 AM
Aligning Text of a textbox mahulda General .NET 0 July 27th, 2004 12:16 AM
how can I insert a new line at top of text file? Satorikin VB.NET 1 March 4th, 2004 03:41 AM



All times are GMT -4. The time now is 07:57 PM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.