a target='' - HTML CSS HTML Tag

HTML CSS examples for HTML Tag:a

Introduction

The target attribute tells the browser where you want the linked resource to be displayed.

By default, the browser uses the window, tab, or frame in which the current document is displayed.

The new document replaces the existing one.

The following table lists the supported values for the target attribute.

Attribute Description
_blankOpen the document in a new window (or tab).
_parent Open the document in the parent frameset.
_self Open the document in the current window (this is the default behavior).
_top Open the document in the full body of the window.
<frame> Open the document in the specified frame.

Demo Code

ResultView the demo in separate window

<!DOCTYPE html>
<html>
   <head> 
   </head> 
   <body>
       I like <!--from www . ja  va  2 s.  c  om-->
      <a target="_blank" href="http://java2s.com/">CSS</a>
       and 
      <a href="http://java2s.com/">HTML</a>
      .  
   </body>
</html>

Related Tutorials