[Resolved] Have external link open in smaller window

Home Forums Support [Resolved] Have external link open in smaller window

Home Forums Support Have external link open in smaller window

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #495484
    CRISTO

    I am not sure how to word this: |All the external links on my site open in a new window. I had thought to put a notification on those links using the “Exit Notifier” plug-in. Works Ok, but now I found something that I think will work better…but clueless as to how to do it.

    Looking at Tripadvisor on this page if you click website at the top of the page (right next to Vatican Museums) it opens in a new window, but smaller than the TripAdvisor window, so you know you are going to a new window. Pretty neat imho, but not sure how to accomplish this. Any ideas?

    #495592
    Leo
    Staff
    Customer Support

    Hi there,

    Not too sure what I’m looking at? I see lots of “Vatican Museums” on that page.

    #495663
    CRISTO

    Sorry… I should have been clearer.

    “Vatican Museum Tour”

    underneath there are images, and then to the right of those images there is a listing of “Vatican Museums”

    Underneath Vatican museums is:
    Viale Vaticano, 00120 Vatican City, Italy +39 06 6988 4676
    Website E-mail Improve this listing

    When you click on “website” it opens up the page in a new window about half the size of my site window, where you can see both the smaller TripAdvisor page and their original page.

    Does this make it any clearer?

    #495845
    Tom
    Lead Developer
    Lead Developer

    You would have to use javascript within the link:

    <a href="URL TO YOUR PAGE" onclick="window.open(this.href,'targetWindow', 'width=500, height=500'); return false;">Your link text</a>

    I believe that should work.

    #496079
    CRISTO

    Thanks, Tom. I realize this was not really a GP problem, but was hoping some smart guy like you could give me an answer.

    #496364
    Tom
    Lead Developer
    Lead Developer

    No problem 🙂

    #497099
    CRISTO

    It worked like a charm, but I realized that won’t be practical….with thousands of external links I would have to change each one (I assume). So I will keep looking….perhaps some css.

Viewing 7 posts - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.