hi ,
Anyone help me on showing the tool tip for lable which is presented in DIV tag.
We have to display the address of the person in two lines ...if it comes more than 2lines need to display tooltip.
we have to show the lable value as address.....
thanks in advance

Sangeetha SRank #212 · 11.4K reputationPosted Nov 28, 2024, 7:50 AM EST
.address-container { max-width: 200px; /* Set the max width for the address */ overflow: hidden; /* Hide overflow content */ white-space: nowrap; /* Prevent text from wrapping */ text-overflow: ellipsis; /* Add ellipsis for overflow text */ position: relative; /* Set position for tooltip */ } .address { display: block; /* Ensure the address takes full width */ max-height: 3em; /* Show only two lines of text */ overflow: hidden; /* Hide overflow content */ text-overflow: ellipsis; /* Add ellipsis for overflow text */ line-height: 1.5em; /* Line height for proper spacing */ } .tooltip { visibility: hidden; /* Hide tooltip by default */ width: 150px; /* Tooltip width */ background-color: rgba(0, 0, 0, 0.75); /* Tooltip background */ color: #fff; /* Tooltip text color */ text-align: center; /* Center text */ border-radius: 5px; /* Rounded corners */ padding: 5px; /* Padding for tooltip */ position: absolute; /* Position tooltip */ z-index: 1; /* Ensure tooltip is on top */ bottom: 125%; /* Position above the address */ left: 50%; /* Center tooltip */ margin-left: -75px; /* Center tooltip */ opacity: 0; /* Make tooltip invisible */ transition: opacity 0.3s; /* Fade in effect */ } .address-container:hover .tooltip { visibility: visible; /* Show tooltip on hover */ opacity: 1; /* Make tooltip visible */ } 1234 Long Address That Needs To Be Shown In A Tooltip 1234 Long Address That Needs To Be Shown In A Tooltip