|
|
| Author |
Message |
t_ravichandu
Joined: 28 Aug 2008
Posts: 22
|
Posted: Fri Oct 23, 2009 12:52 pm Post subject: window.open() - popup blocker issue |
|
|
Hi,
My need is - on click of a button to check current URL of IE ('location.href') and based on that either open a new window to show the redirect page or show it in the same window.
For this I wrote javascript in 'href' of 'redirect'. Every thing works fine but IE popup blocker blocks the popups from window.open().
Please help me. How to get around this.
I'm not so keen on using custom javascripts because I have around 20 buttons like these so I do not want to have 20 custom javascript files inside my cab.
Thanks in advance.
Chandu. |
|
| Back to top |
|
 |
Admin Site Admin
Joined: 22 Aug 2006
Posts: 1055
|
Posted: Mon Oct 26, 2009 10:45 am Post subject: |
|
|
| If you don't want to use Custom Javascripts, you can try to open modal windows instead. |
|
| Back to top |
|
 |
t_ravichandu
Joined: 28 Aug 2008
Posts: 22
|
Posted: Tue Oct 27, 2009 12:21 pm Post subject: |
|
|
| Quote: | | If you don't want to use Custom Javascripts, you can try to open modal windows instead. |
Thanks for the reply.
Unfortunately I can not afford to have modal dialogues (which I believe need to closed to access the parent window).
I can use 'newbrowserwindow=true' but for that I need to have a webjump and only webjump but not in <button>.
Please correct me if I'm wrong and if we can use 'newbrowserwindow' attribute in <button> tag. |
|
| Back to top |
|
 |
Admin Site Admin
Joined: 22 Aug 2006
Posts: 1055
|
Posted: Wed Oct 28, 2009 11:03 am Post subject: |
|
|
| No, <button> tag doesn't have "newbrowserwindow" attribute, but you can use Webjump command and call it from a button. |
|
| Back to top |
|
 |
t_ravichandu
Joined: 28 Aug 2008
Posts: 22
|
Posted: Wed Oct 28, 2009 12:43 pm Post subject: |
|
|
Hi,
Thanks for the reply again.
| Code: | | <BUTTON caption="Conditional Open" hint="Opens new window after checking the condition" id="id_con_btn1" command="tbcmd_cn_btn1" > |
The above works with a Webjump name 'tbcmd_cn_btn1'.
But I doubt the following works.
| Code: |
<BUTTON caption="Conditional Open" hint="Opens new window after checking the condition" id="id_con_btn1" href="javascript:somescript;if(true){[call tbcmd_cn_btn1]} else {[call tbcmd_cn_btn2]}" >
|
if the above is possible please help me with the way to call the webjump command from javascript inside a button href.
One more thing is that my toolbar XML comes from a remote source using <INCLUDE_XML filename="http://myserver.com/toolbarxml.xml">
Thanks in advance,
Regards,
Chandu. |
|
| Back to top |
|
 |
Admin Site Admin
Joined: 22 Aug 2006
Posts: 1055
|
Posted: Thu Oct 29, 2009 9:10 am Post subject: |
|
|
| No , this is not possible. Please, use Custom Javascript. |
|
| Back to top |
|
 |
t_ravichandu
Joined: 28 Aug 2008
Posts: 22
|
Posted: Thu Oct 29, 2009 12:14 pm Post subject: |
|
|
| Quote: | | No , this is not possible. Please, use Custom Javascript. |
Well...this is the only way as it looks as of now.
Thanks again for your valuable replies. |
|
| Back to top |
|
 |
|