The Task is to learn how to isolate a part of the text that may be formatted in a different direction using HTML5?
Approach: As we know that bdi stands for Bi-Directional Isolation. Basically. It is used to differentiate a text from other text that may be formatted in a different direction. The Task can be done by using the <bdi> Tag in the Document.
Syntax:
<bdi> Contents... </bdi>
Example Code: The below example illustrate the bdi tag .
HTML
<!DOCTYPE html>
<html>
<body>
<h1>GeeksforGeeks</h1>
<ul>
<h3>bdi Content</h3>
<li>
<bdi class="name">Himanshu Jha</bdi>: indian name
</li>
<li>
<bdi class="name">الرجل القوي إيان</bdi>: arabic name
</li>
<li><bdi>Manas Chhabra</bdi>
</li>
<li><bdi>GeeksForGeeks</bdi></li>
</ul>
</body>
</html>
Output
Supported Browsers: Google ChromeFirefoxOperaSafar
Whether you're preparing for your first job interview or aiming to upskill in this ever-evolving tech landscape,
GeeksforGeeks Courses are your key to success. We provide top-quality content at affordable prices, all geared towards accelerating your growth in a time-bound manner. Join the millions we've already empowered, and we're here to do the same for you. Don't miss out -
check it out now!
Last Updated :
14 Apr, 2021
Like Article
Save Article