Solved

Problem with hover on display

Posted on 2014-10-21
8
85 Views
Last Modified: 2014-10-23
I'm having problems trying to figure this out.  It's very simple and I can't see it!!!!

I have a table that looks something like this:
--------------------------------------
Address
Building Name
Crossing Street
---------------------------------------

What I want to do is just do a hover on the address.

Here's the code that I'm using:

echo "<tr>";
                        echo '<td style= "text-align:left"';
                        echo ' font color= "blue" class="Body_Labels">';
                              //Address
                              $work = "$ROW[ADDRESS]";
                              $work = trim($work);
                              $_SESSION['Data'] = $ROW['SEQ'].$ROW['STOREKEY'];
                        
                              echo '<a href="Space_Display.php?id=';
                                    echo $_SESSION['Data'];
                                    echo '">';
                                    echo "$work";
                              echo "</a>";

                              echo "<style>";
                                    echo "#left_Table a:hover{";
                                    echo "text-decoration:none;";
                                    echo "color:#0000FF";
                                    echo "}";
                              echo "</style>";                  
                              
                              $work = "$ROW[ADDRESS]";
                              $work = trim($work);

                              echo "<br>";
                              echo "$ROW[BNME]";
                        
                              echo "<br>";
                              echo "$ROW[CRST]";
                        
                              echo "<br>";
                              echo "</td>";

I know it's on the <href> but it hilights the address with a blue underline.

Thanks
Glenn
0
Comment
Question by:breeze351
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
8 Comments
 
LVL 58

Expert Comment

by:Gary
ID: 40395450
Hover to do what?

This isn't valid
font color= "blue"
0
 

Author Comment

by:breeze351
ID: 40395636
By hover, I meant that when the cursor goes over the text it will change to blue rather than having text in blue with an underline.
0
 
LVL 58

Expert Comment

by:Gary
ID: 40395653
An anchor tag will be blue and underlined by default, if you want to override the style then you have to add your own styles

a {
    color:green /* or whatever color it should be */
    text-decoration:none
}
a:hover {
    color:blue /* or whatever color it should be */
}

Open in new window


And please attend to this question
http://www.experts-exchange.com/Q_28531393.html
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:breeze351
ID: 40397860
Ok, I'm a moron that needs help!!!!
I changed the code to read as follows:

                        echo '<td style= "text-align:left"';
                        echo ' font color= "black" class="Body_Labels">';
                              //Address
                              
                              $_SESSION['Data'] = $ROW['SEQ'].$ROW['STOREKEY'];
                                          
                                    // ****************************************************
                              // * Display Address                                  *
                                    // ****************************************************
                                    echo "<style>";
                                          echo "a ";
                                                echo "{";
                                                      echo "color:black";
                                                      echo "text-decoration:none";
                                                echo "}";
                                                
                                          echo "a:hover ";
                                                echo "{";
                                                echo "color:blue";
                                          echo "}";
                                    echo "</style>";
                                          echo '<a href="Space_Display.php?id=';
                                                echo $_SESSION['Data'];
                                                echo '">';
                                                echo "$ROW[ADDRESS]";
                                          echo "</a>";

I still end up with the address in an underline blue.

I'm not the greatest at this.  I just wish they would let me get back to the data side of this site.  That's what I'm good at.

Thanks
Glenn
0
 
LVL 58

Expert Comment

by:Gary
ID: 40397915
Don't write styles inline - add them to your css file.
Have you got a link to look at?
0
 

Author Comment

by:breeze351
ID: 40400161
Got It!!!!
Last question.
What is a:active as opposed to a:link?
0
 
LVL 58

Accepted Solution

by:
Gary earned 500 total points
ID: 40400165
0
 

Author Comment

by:breeze351
ID: 40400390
Gotcha.

Can I get back to the data now!!!! (See up above).

Thanks
Glenn
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Obsolete font tag need to convert to CSS 3 55
ASP get fieds value 2 39
HTML auto refresh to another site 4 45
Add Rows on a Table 8 51
Not sure what the best email signature size is? Are you worried about email signature image size? Follow this best practice guide.
Originally, this post was published on Monitis Blog, you can check it here . Websites are getting bigger and more complicated by the day. Video, images and custom fonts are all great for showcasing your product or service. But the price to pay in…
In this tutorial viewers will learn how to position items using CSS's three positioning types Create a new HTML document with an internal stylesheet.: Create another div in CSS and name it Absolute : Type "position:absolute;" and "top:10px; left:50p…
In this tutorial viewers will learn how to code links for mobile sites that, once clicked, send a call or text to a specified number. For a telephone link (once clicked, calls a number), begin with a normal "<a href=" link tag. For the href, specify…

734 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