Computer >> คอมพิวเตอร์ >  >> การเขียนโปรแกรม >> CSS

เลือกองค์ประกอบทั้งหมดด้วย rel=”nofollow” ด้วย CSS


ใช้ตัวเลือก [attribute =”value”] เพื่อเลือกองค์ประกอบที่มีแอตทริบิวต์และค่าที่ระบุ

คุณสามารถลองเรียกใช้โค้ดต่อไปนี้เพื่อใช้ตัวเลือก CSS [attribute="value"] ที่นี่เราได้พิจารณาแอตทริบิวต์เป็น rel ,

ตัวอย่าง

<!DOCTYPE html>
<html>
   <head>
      <style>
         a[rel = nofollow] {
            border: 3px solid blue;
         }
      </style>
   </head>
   <body>
      <a href = "https://qries.com/What-is-Uber-s-business-model-and-how-does-it-compare-with-Ola-smodel-
         in-India" rel = "nofollow">Uber's Business Model</a><br><br>
      <a href = "https://www.qries.com/How-does-share-market-work-in-India" rel = "noreferrer">Share
         Market</a>
   </body>
</html>