Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...HTML Redirect in New WindowHTML Redirect in New Window
Previous
 
Next
New Post
4/27/2009 7:59 PM
 

I am new to using DotNetNuke and am having some issues getting a link to an external site to open in a new window. I also need to have a warning message telling users that they are leaving our site. I'm using JavaScript to display the warning message which is working just fine. I just can't seem to get the link to open in a new window. I've tried using the JavaScript window.open function but the window is blocked by the pop-up blocker (which I want to avoid). I've also tried using meta-refresh but I can't seem to get it to open in a new window. I know that some of these methods are frowned upon so I'm looking for any suggestions anyone might have on how I might get this to work. If I were just writing straight HMTL code, I wouldn't be having the issue but, using DotNetNuke is a whole new ballgame. I figured that there would be some sort of checkbox somewhere to open the page in a new window but, if there is I can't find it!

 
New Post
4/28/2009 5:25 PM
 

So, I've discovered how to add the link without it getting blocked by the pop-up blocker.  Go to your page properties and then select "URL" for the link type and then insert the following as the URL:   void(window.open('http://www.google.com'))

That solves that problem.  Now I need to let users know that they are leaving our site when they click this link.  I normally use a javascript alert to do this however, I can't figure out where to place the code in this instance so that it will work.  Any suggestions?

 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...HTML Redirect in New WindowHTML Redirect in New Window


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out