www.webdeveloper.com
Results 1 to 5 of 5

Thread: open a jpeg in a new window (links)

  1. #1
    Join Date
    Apr 2005
    Posts
    3

    open a jpeg in a new window (links)

    I have this pic and its a link. But how do i make it so that when i click on the pic it opens up in a new window and not the current one????? PLEASE HELP!! thanks

    <a href=""><img src=""></a>

  2. #2
    Join Date
    Feb 2005
    Posts
    1,018
    Code:
    <a href="" target="_blank"><img src=""></a>

  3. #3
    Join Date
    Apr 2005
    Location
    Left of Nowhere
    Posts
    17
    I think an easier way would be to use JS instead of just plain HTML.

  4. #4
    Join Date
    Dec 2003
    Location
    A series of tubes known as the "internets"
    Posts
    2,165
    Quote Originally Posted by Stevos
    I think an easier way would be to use JS instead of just plain HTML.
    pure html is better for 2 reasons. 1)it's less coding 2) you don't have to worry abou different browsers or people that have javascript disabled.
    "Outside of a dog, a book is a man's best friend. Inside a dog, it is too dark to read." - Mark Twain

  5. #5
    Join Date
    May 2004
    Location
    dobson ave.
    Posts
    694
    Hi -

    ...onclick="window.open(this.href); return false;">

    Works for me - and will just open in the same window if js is disabled.

    El

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles