CSS的作用:主动选择器
使用CSS:active选择器来设置活动链接的样式。您可以尝试运行以下代码来实现:active选择器-
示例
<!DOCTYPE html>
<html>
<head>
<style>
a:active {
background-color: orange;
}
</style>
</head>
<body>
<a href = "https://qries.com">Welcome to Qries</a>
<p>Click on the above link to see the effect.</p>
</body>
</html>