To insert an attribute(_blank) to (a) element

add target attribute with the value _blank to the anchor (a ) element’s opening tag, so that the link opens in a new tab.

Click here to view more cat photos.

You’ve already added an href attribute to the link. Adding a target attribute is the same concept:

name=“value”

Replace name with target and replace value with the value the instructions are telling you to use.

I’m not sure what you are asking? Can you be more specific.

Also, to show your code in here you need to wrap it in triple back ticks. On a line by itself type three back ticks. Then on the first line below the three back ticks paste in your code. Then below your code on a new line type three more back ticks. The back tick on my keyboard is in the upper left just above the Tab key and below the Esc key.

how do you insert the _ blank attribute to element (a)

I don’t think you are being asked to insert the _blank attribute. Aren’t you being asked to insert the target attribute and give it a value of _blank?

Again, you’ve already added an attribute/value when you added the href attribute to the link. Adding a target attribute is exactly the same thing, just using a different name/value.

<p>Click here to view more <a href="https://freecatphotoapp.com">cat photos</a>.</p>

in that situation

I’m not sure what more I can tell you without just showing you how to do it and that’s not something we really do around here. Do you see how you added the href attribute to this link? You would do the same thing for the target attribute, except you would use target instead of href and then set the value to _blank instead of a URL. Don’t remove the href attribute though. Just add the target attribute to the link.

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.