Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 642075
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T21:07:55+00:00 2026-05-13T21:07:55+00:00

In the table below, the entire cells are hyperlinks. How can I make just

  • 0

In the table below, the entire cells are hyperlinks. How can I make just the text in the cells hyperlinks? The corresponding CSS is also below.

Thanks in advance,

John

<?php
    echo "<table class=\"samplesrec\">";
    while ($row = mysql_fetch_array($result)) { 
        echo '<tr>';
        echo '<td class="sitename1"><a href="http://www.'.$row["url"].'">'.$row["title"].'</a></td>';
        echo '</tr>';
        echo '<tr>';
        echo '<td class="sitename2"><a href="http://www.'.$row["url"].'">'.$row["username"].'</a></td>';
        echo '</tr>';
        }
    echo "</table>";    

?>


table.samplesrec {
    position:absolute;
    left:300px;
    top:125px;
    text-align: left;
    font-family: Arial, Helvetica, sans-serif ;
    font-weight: normal;
    font-size: 16px;
    color: #000000;
    width: 1000px;
    table-layout:fixed;
    background-color: #FFFFFF;
    border: 2px #FFFFFF;
    border-collapse: collapse;
    border-spacing: 2px;
    padding: 1px;
    text-decoration: none;
    vertical-align: text-bottom;    

}

table.samplesrec td {
   border: 2px solid #fff;  
   text-align: left; 
   height: 18px;
   overflow:hidden;

}

table.samplesrec td a{
   display: block;
   padding: 2px;
   color: #000000;
   text-decoration: none;
   overflow:hidden;
   height: 18px;
}

table.samplesrec td a:hover{
   background-color: #FFFFFF;
   display: block;
   padding: 2px;
   color: #FF0000;
   text-decoration: none;
   overflow:hidden;
   height: 18px;
}   

.sitename1 { width: 550px;
            overflow:hidden !important;
            color: #000000;
            vertical-align: 

}

.sitename2 { width: 50px;
            overflow:hidden !important;
            color: #793D00;
            font-size: 12px;
            font-weight: bold;
            height: 18px;
            padding-bottom: 18px;

}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T21:07:55+00:00Added an answer on May 13, 2026 at 9:07 pm

    Remove display:block from table.samplesrec td a and table.samplesrec td a:hover.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Given the example table below, how can I retrieve the high and low range
I am trying to make an entire table cell clickable. The general advice I
I had a page that displayed some text and a centered table below that
I have a stored procedure (below) that returns the entire table. I am trying
The table below works well. However, I am trying to pass $row[username] along as
the mysql table below has two columns. how do i select only those rows
Would following the table below be the best way of determining the access type
i have the table below <tr id=group_1>...</tr> <tr id=el>...</tr> <tr id=el>...<tr> <tr id=group_2></tr> <tr
for the table below tenant_id | status_id ---------------------- 3 | 6 --------------------- 5 |
I'm currently working on a dynamic table below: echo '<table border=1>'; echo '<tr align=center

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.