Solved

Way to have hovering effect

Posted on 2016-09-13
4
56 Views
Last Modified: 2016-09-14
Hi,
I want to have hovering effect (have deep color when mouse is on top of the Linkbutton). What to adjust below?
<body>
    <form id="main_form" runat="server">
    <div class="content" id="wrapper">
    <table width="100%">
        <tr>
            <td align="right" style="ForeColor:#0A2757;">
            <asp:LinkButton ID="lb_reg" 
                Text = "Register"
               CssClass="lb_reg"
               Font-Names="Times New Roman" 
               Font-Size="10pt" 
               OnClick="lb_reg_Click" 
               runat="server"/>
               &nbsp;|&nbsp; 
               <asp:LinkButton ID="lb_log" 
               Text = "Login"
               CssClass="lb_log"
               Forecolor="#0A2757"
               Font-Names="Times New Roman" 
               Font-Size="10pt" 
               OnClick="lb_log_Click" 
               runat="server"/>
               &nbsp;|&nbsp; 
               <asp:LinkButton ID="lb_supp" 
               Text = "Support"
               CssClass="lb_log"
               Forecolor="#0A2757"
               Font-Names="Times New Roman" 
               Font-Size="10pt" 
               OnClick="lb_supp_Click" 
               runat="server"/>
            </td>
        </tr>
        ...
            .lb_reg{
                color: black;
                top: 30px;
                left: 1075px;
                width: 36px;
                height: 30px;
                font-size: large;
                font-weight: bold;
                text-decoration: none;
            }  
            .lb_reg:hover{
                background-color: black !important;
                color: white !important;
            }  
            .lb_log{
            color:#000!important;
            top: 30px;
            left: 1130px;
            width: 36px;
            height: 30px;
            font-size:large;
            font-weight:bold;
            }  

Open in new window

0
Comment
Question by:HuaMinChen
  • 2
  • 2
4 Comments
 
LVL 22

Expert Comment

by:Kim Walker
ID: 41797243
I deleted my previous comment when I noticed you have three LinkButtons. The CSS code you have here should work for the first LinkButton. Does it not? Do you want the same effect on the other two LinkButtons?
0
 
LVL 10

Author Comment

by:HuaMinChen
ID: 41797259
Yes, I do not see hovering effect to all 3 LinkButtons.
0
 
LVL 22

Accepted Solution

by:
Kim Walker earned 500 total points
ID: 41797270
Is it already working on the first LinkButton? If so, just add the other two classes to your style configuration. (See change on line 11 below.)
            .lb_reg{
                color: black;
                top: 30px;
                left: 1075px;
                width: 36px;
                height: 30px;
                font-size: large;
                font-weight: bold;
                text-decoration: none;
            }
            .lb_reg:hover, .lb_log:hover, .lb_supp:hover{
                background-color: black !important;
                color: white !important;
            }
            .lb_log{
            color:#000!important;
            top: 30px;
            left: 1130px;
            width: 36px;
            height: 30px;
            font-size:large;
            font-weight:bold;
            }

Open in new window

0
 
LVL 10

Author Comment

by:HuaMinChen
ID: 41797282
Thanks a lot. BTW, what to adjust below, as ForeColor is underlined?
7t.png
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Finding original email is quite difficult due to their duplicates. From this article, you will come to know why multiple duplicates of same emails appear and how to delete duplicate emails from Outlook securely and instantly while vital emails remaiā€¦
FAQ pages provide a simple way for you to supply and for customers to find answers to the most common questions about your company. Here are six reasons why your company website should have a FAQ page
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will the learn the benefit of plain text editors and code an HTML5 based template for use in further tutorials.

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question