SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Addict sstaubin01's Avatar
    Join Date
    Nov 2000
    Location
    Ont, Canada
    Posts
    234
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    New Browser Window Question

    I'm using this piece of code to access another site.

    <table border="0" width="100%" height="20" cellspacing="0" cellpadding="0" >
    <tr>
    <td><script language =JavaScript src = 'http://www.theweathernetwork.com/weatherbutton/search/120X60.js'></script></td>
    </tr>
    </table>

    How can I get the link to open in a new browser window?

  2. #2
    ☆★☆★ silver trophy vgarcia's Avatar
    Join Date
    Jan 2002
    Location
    in transition
    Posts
    21,235
    Mentioned
    1 Post(s)
    Tagged
    1 Thread(s)
    If that JS file is generating the link for you then you can't. It would be up to the developer of the remote script to have the link open in a new window.

    By the way, scripts go in the <head> of your document. I don't know if your site would validate, if that's a concern of yours.

  3. #3
    SitePoint Wizard Bill Posters's Avatar
    Join Date
    Dec 2001
    Location
    UK
    Posts
    1,523
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally posted by vgarcia
    By the way, scripts go in the <head> of your document. I don't know if your site would validate, if that's a concern of yours.
    Scripts contained within the body area will not invalidate a page as long as they follow the correct tag criteria.

    Scripts are often used within the body of a page when content is brought in dynamically. Popular uses of such methods include adding clocks or tickers to a specific position somewhere on a page.

    It may not be the only method for adding such things, but there is no significant reason against using it, even by the standards set by the validation process.
    New Plastic Arts: Visual Communication | DesignateOnline

    Mate went to NY and all he got me was this lousy signature


Bookmarks

Posting Permissions

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