Using jQuery to Open External Links in a New Window – Expression Web
Learning jQuery has been on my to-do list from quite some time and finally, I am getting some hands-on with it. Suprotim’s eBook ’51 Recipes using jQuery and ASP.NET Controls’ has been very helpful and I am learning how to apply these tricks on my HTML web pages created using Expression Web.
If you are new to jQuery, check this article ‘How jQuery Works’jQuery is a fast, lightweight JavaScript library that is CSS3 compliant and supports many browsers. The jQuery framework is extensible and very nicely handles DOM manipulations, CSS, AJAX, Events and Animations.
While I continue my exploration with jQuery, I would like to share whatever I have learnt about jQuery with my readers. This article is about using jQuery to open external links (links that point to a domain other than yours) in a new window.I usually like to open up a link on a website in a new tab or a new window.
This makes it easier for me to remember where I was and I always have the original page opened with me. There are some sites which contain links that open in the same window, and one link leads to another and I keep browsing pages in the same window.
At some point, I realize I need to go back to the original page I visited and I don’t remember the URL. So I need to hit the back button on the browser several times, until I reach that page.
Now if you are building your website in Expression Web, you can open links in a new window using the ‘Hyperlink Properties’. Select the hyperlink, right click and choose Hyperlink Properties from the menu.
In the Edit hyperlink window, choose ‘Target Frame’. In the Target Frame window, select New Window from the list.
View the Original article