Home > Web Front-end > HTML Tutorial > Hyperlinks about td in table_html/css_WEB-ITnose

Hyperlinks about td in table_html/css_WEB-ITnose

WBOY
Release: 2016-06-24 12:11:20
Original
1396 people have browsed it






a name


Now the second column can only be clicked on the text Jumped.
But the name will not occupy the entire column. I need to click on any blank space in the second column to jump.
How to achieve it?


Reply to discussion (solution)

<td onclick="window.location.href='url';"><a href="">一个名字</a></td>
Copy after login

<!DOCTYPE HTML><html>	<head>		<meta charset="gb2312" />		<title></title>			<style>			td {				border:1px solid red;				font-size:12px;			}			.test a{				display:inline-block;				width:100%; height:100%;			}		</style>			</head>	<body>		<table>			<tr>				<td><a><img></a></td>				<td class="test" width="100" height="30"><a href="">一个名字</a></td>			</tr>		</table>	</body></html>
Copy after login


Try it

As a 1L person, I understand that this method is also possible.
2L doesn’t understand what it means, can you explain it?

Just make the height and width of a consistent with the width and height of the parent td, then click on the blank space of td (it seems to be the blank space of td, but it is actually part of a) to trigger a

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template