w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
open the link from the popup window in an external window and then close the original popup window
Try <input name="Apply Online" type="button" id="Apply Online" value="Apply Online" ONCLICK="window.location.href='some_url';$.colorbox.close();"> or <input name="Apply Online" type="button" id="Apply Online" value="Apply Online" ONCLICK="window.location.href='some_url';parent.$.colorbox.close();">

Categories : Javascript

Bookmarklet window gets blocked if I try to do anything besides open a new window
I assume that the difference is that i'm doing some parsing in the first example No, the problem is the asynchronous AJAX. The browser tries to determine if a user action initiated a new window or not before deciding to block it or not. For the new window to open without blocking, there must be a "direct line of action" between the user click and the window opening. The async AJAX breaks that direct line. (Synchronous AJAX might work, I'm not sure.) Is there a way to have my cake and eat it too? There is no perfect solution, but an improvement over what you have now is to create a pop-over div on the page with a link similar to <a href="http://localhost:3000/bmfeed?targ=..." target="_blank">click here to open the new window</a>.

Categories : Javascript

Popup Window with javascript - open new popup in the old popup window
Don't you just want to close the old window each time #canvas is clicked? //earlier: var winPop = false; // in the click event: if (winPop) { winPop.close(); } winPop = window.open('About.aspx?info=' + info, "pop", "resizable,width=1000,height=600,"); And to close it later: window.onbeforeunload = function(e) { if (winPop) { winPop.close(); } };

Categories : Javascript

How to open a new window/tab without user interfaction and without getting it blocked
Solution The standard (even though it's not implemented in every browser) event when pressing ENTER or RETURN with a form element or its children selected will be to trigger the submit event of it. Automated Alternative If you want this event to be called automatically you can do it with JavaScript: /*Directly selecting the form by its formIndex*/ document.forms[0].submit(); /* --- */ /* selecting the form by ID */ document.getElementById('myForm').submit();

Categories : Javascript

setTimeout window.open does not wait, how can I solve this?
The problem is in your second setTimeout call, you are invoking the function win_open then passing the value returned by it to setTimeout as the callback You need function link_redirect(linkaddress) { overlay(); setTimeout(function() { overlay(); win_open(linkaddress) }, 2000); //return false; }

Categories : Javascript

Disable parent window when child popup window is open
Play around with this code in the pop-up: $(window).on("blur", function(){ ... }); This will fire every time the user leaves the window. Inside the argument function you should be able to make the window regain its focus, maybe using $(this).focus() or self.focus(). I haven't tested this myself. Good luck!

Categories : Javascript

IE11 on WIN 8.1 : window.open with the same name is opening new popup window
Please try this.. this will check the window is still open or closed.. <script type="text/javascript"> var myWindow = null; if(!myWindow || (myWindow && myWindow.closed)){ myWindow = window.open("http://www.google.com", "test", "resizable=no,scrollbars=yes,width=260,height=225"); } else{ myWindow.location.href = 'http://www.google.com'; } </script>

Categories : Javascript

Reset window.open specs in popup window
Specify scrollbars=1 and specify width and height, that way the scrollbars would show when the content is larger than the specified window width and height. window.open("...url...", "...blah...", "scrollbars=1,width=600,height=600")

Categories : Javascript

Open a window popup using php
PHP is a server side scripting language. You'll need to use JavaScript (which runs on the client side most of the time) You're going to want to use something like window.open which should work a little like this: window.open('http://google.com'); Bear in mind that most browsers these days have built in pop-up blockers and will block your attempts unless over-ridden by the user. And if all else fails, use modals! Just to sum that up, Get PHP to return a value to the user, which the Javascript will then catch and launch the appropriate URL. This URL should be made to contain whatever parameters you'll need to tell the PHP who to open the chat session with.

Categories : Javascript

Javascript setTimeout(); for ProgressBar doesn't work
set your onclick="startTime(i);" as onclick="startTime(0);" <input value="Download" type="button" onclick="startTime(0);"> Here is JSBin

Categories : Javascript

Open link in popup window
The snippet you shared works when I append it to the page we are at, in Google Chrome. Which makes me wonder which browser you are having the trouble in. So I would encourage you to try the snippet you shared in Google Chrome, and if it works there then you will know it is a browser specific kind of bug, in which case I would try adding a semicolon after return false.

Categories : Javascript

Why does window open sometimes open a new tab and sometimes a popup?
Check out this response from another question. When a javascript event is initiated by the user, open() opens the link in a new tab. Otherwise, it's opened in a popup window. So if the user clicks something that triggers open(), a new tab will open. If you set a timeout or try to open a link after some other event, like an ajax response, a new window will open.

Categories : Javascript

How to open popup window from each of dynamically generate tr
Your html is invalid: the id attribute is supposed to be unique. When you use the selector #JN_apply" it selects just one of the buttons (in most browsers this will be the first, as you have seen). You should change each one to use a class instead of an id: <input class="JN_apply" type=button value="Apply" data-url="http://www.yahoo.com/"> ...and then change the jQuery selector to match: $('.JN_apply').click( function() { open($(this).data('url')); }) Updated demo: http://jsfiddle.net/p3wgm/3/ Note also that it's not a good idea to create global functions called open() and close() because there are already built-in functions open() and close() and your functions will overwrite these. Perhaps openPopup() and closePopup() or similar? Or define them inside your document ready ha

Categories : Javascript

Open a popup window in the center of the monitor
you can center you popup in css like this is only css method to make it center so no js will be required to center it #containerdiv { width:90%; height: 90%; display: none; position: fixed; left:50%; top:50%; margin:-45% 0 0 -45%; background:#FFF; border: 1px solid #666; border: 1px solid #555; box-shadow: 2px 2px 40px #222; z-index: 999999; box-sizing:border-box; -webkit-box-sizing:border-box; -moz-box-sizing:border-box; }

Categories : Javascript

joomla 1.5 : how to open a pdf file in popup window?
How PDF's are rendered depends entirely on the browser you are using. Up until recently, only WebKit based browsers (and FireFox w/extensions) would even display PDF's in the browser. But even still, there aren't any (that I'm aware of) that will treat a PDF as an image and allow you to open it in a lightbox. I've actually had to deal with this previously from a client request. They basically demanded to be able to view PDF's in the lightbox we had created for them, and weren't taking "but browsers don't work that way" for an answer. (facepalm) So, what I ended up doing was taking his 75 page PDF and splitting it up into 75 JPG images, and then loading them, full resolution, into the lightbox. It worked, I finally got paid, and then I fired the client. TL;DR; If you have any control over

Categories : Joomla

How to open WebView in Popup Window in AsyncTask
You can use custom dialogs, all you need to do is in your custom dialog's layout file put a WebView and then in your code give a source URL to your WebView according to the selected item in your ListView. For how to make a custom dialog take a look at here http://www.mkyong.com/android/android-custom-dialog-example/

Categories : Android

Copy table and open a new popup window
Add onclick function for your button first: <input type="button" value="test it" onclick="openWin()" /> In script: function openWin() { myWindow=window.open('','','width=200,height=100'); myWindow.document.write(document.getElementById('data').outerHTML); myWindow.focus(); } Thats it. I am not sure outerHTML property compatibility across browsers. Please check once.

Categories : Javascript

PopUp window should not open with copy paste URL
A referrer or an URL to a page has nothing to do with security. If you don't want the user to access a certain page when not logged in, then check whether the user is logged in when that page is requested. If it's only about the popup part: to my knowledge you can't detect whether a page is displayed in a popup or a 'regular' browser window.

Categories : Asp Net

how do i open a popup using my action link keeping the same window mvc
Try this, <input type="button" id="btnpopu" value="Open Modeless popup" onclick="ShowPopup();" /> <script type="text/javascript"> ShowPopup = function () { window.open('URL', "PopupWindow", 'width=400px,height=400px,top=150,left=250'); } </script>

Categories : Asp Net Mvc

How do you open a link in a popup window in edge animate
Hi I think this is what you are looking for: Add this to a Click action on the button you want to press that will drive you to the new page. window.open("http://yourURL.com", "_blank"); I hope that helps. Adam

Categories : Misc

I'm trying to use javascript to open a popup window. It works in Chrome but not in IE or Firefox
The issue is your target="". You don't need it if you're going to be using javascript popup code. This works fine: <a href="javascript:newPopup('buy-now/ambush-jacket.html');"><img src="images/banner/buy.gif"></a>

Categories : Javascript

Javascript Onclick window.open Popup not working in Firefox and Safari
Try this code : function popwin(url) { window.open('', url, 'height=800, width=1000, top=500, left=200, scrollable=yes, menubar=yes, resizable=yes'); url.target =url; } And for link,use the same code javascript: onclick=popWin('http://www.weybridgestrategies.com/team/debra-porter-president-ceo'); return (false);

Categories : Javascript

need popup window inside a mysql table
You need a client-side script to manage this. I'd recommend something in jQuery. <script type="text/javascript"> $(document).ready(function(){ $(".myButton").click(triggerPopup); }) function triggerPopup(){ //do popup stuff } </script> an example in more details can be found by googling. something like this http://istockphp.com/jquery/creating-popup-div-with-jquery/

Categories : PHP

Flex - Call JavaScript Function And Open a Popup Window that Displays Data
I figured this out and thought I would share it for anyone else experiencing this problem: In my Flex Code: if (ExternalInterface.available) { try { ExternalInterface.call("onPrintRequest", dataToPass); } catch (error:SecurityError) { Alert.show("Printing Security Error"); } catch (error:Error) { Alert.show("Printing Error"); } } else { Alert.show("Printing currently unavailable"); } In my index.template.html I added this JS method: <script type="text/javascript"> function onPrintRequest(val

Categories : Javascript

How to work with Jquery Popup window in Spring Application?
Even if the file extension of your page is .jsp you can still open it in a Highslide popup using the Highslide iframe method. See this barebones sample and replace the href with your .jsp page: http://highslide.com/examples/iframe.html <a href="your-page.jsp" onclick="return hs.htmlExpand(this, { objectType: 'iframe' } )"> Content in iframe </a>

Categories : Jquery

Handling the popup window in selenium webdriver doesnt work
You have to provide the window handle when switching to the popup so you can control whats going on there. I use this class to make it easier to switch back and forth. This is in C#: public class WindowManager { private string _parentWindowHandle; private string _popupWindowHandle; public void SwitchWindowFocusToPopup(IWebDriver driver, string NewWindowTitle) { //pass the expected popup window title so the IWebDriver can get //the windowhandle and assign it to the current iWebDriver IWebDriver popup = null; var windowIterator = driver.WindowHandles; foreach (var windowHandle in windowIterator) { popup = driver.SwitchTo().Window(windowHandle); if (popup.Title == NewWindowTitle)

Categories : Java

How to close a popup window when a button on the popup window is click?
In the parent window I placed a function called close_Popup(). function closePopup() { $.window.closeAll(); } And in the popup window I used also the codes below to call the function in the parent window to close the popup window. $("#no").click(function() { top.closePopup(); }); the "top" javascript function is used to call the function "closePopup()" that resides in the parent window and it solves the problem.

Categories : Misc

PLease tell me how to auto click in popup window by using Id of popup window page
You were almost there. Just use variable created when window is opened. var aut=window.open('https://www.mysite.com/mypage'); aut.document.getElementById('ID in abovepage').click(); // this will locate and click element within "aut" window. Note: This will work only if parent and popup belong to the same domain.

Categories : Javascript

Page-up doesn't work inside bash inside conqueterm inside vim
Bind is a bash built-in command. It is nothing to do with vim. PgUp and PgDown is used by vim on the most usual way, and You cannot show bash command history in vim. Actually You can, but it seems to be pointless to me. If I know well the best place for key-bindings for bash is the ~/.inputrc file. I added your lines to it "e[5~": history-search-backward "e[6~": history-search-forward And it works well! But the "standard" way is the up and down arrow for these. Please describe what is your goal! ConqueTerm interprets "e" (escape) before bash does. This is why this would not work.

Categories : Bash

Next function doesn't work for Magnific popup
Seems like the plugin is having a hard time with the index being a string, you should cast it to an integer: var index=parseInt($(this).attr('data-index'),10); Here's the updated codepen

Categories : Javascript

Listview in Popup menu doesn't work properly
Create your own adapter class extending BaseAdapter. There you will find getView() method. Implement onClick method there, it will work. Don't use this, final ArrayAdapter<String> popadapter = new ArrayAdapter<String>(this, android.R.layout.simple_list_item_1, pop);

Categories : Android

Links inside iframe (not in popup) doesnt work
I can't really explain the 'why' cause don't know much about the sandbox attribute of the iframe, but the link opened in a new tab just fine for me when I removed that attribute. edit: Looking into it a little more, it seems that you can add the attribute "allow-top-navigation" and then change the link to 'target=_parent' and that works, but it still will not work if you leave the target=_blank Here is a little bit of documentation from the mozilla site sandbox HTML5 only If specified as an empty string, this attribute enables extra restrictions on the content that can appear in the inline frame. The value of the attribute can be a space-separated list of tokens that lift particular restrictions. Valid tokens are: allow-same-origin: Allows the content to be treated as being

Categories : HTML

Jquery click doesn't open new window
The JavaScript is executed as soon as it loads, which is before that element loads. So when the JavaScript code runs it's trying to attach a click event handler to an element which doesn't exist yet. You can wait for the elements to load by wrapping your JavaScript code with the document's ready event: $(document).ready(function () { $("#more_info").click(function(){ window.open("google.com"); return false; }); }); Or, a shorter version: $(function () { $("#more_info").click(function(){ window.open("google.com"); return false; }); });

Categories : Jquery

Code after window.open doesn't get executed
A reference to the window is returned from the window.open call, you can use it to modify the window. win=window.open(...); win.document.doYourThing You also probably need to wait until the document is ready (aka loaded). Using jquery below $(win.document).ready(function() { //the document is loaded by here, this is probably where you should do your stuff. });

Categories : Javascript

Replace Page Links on Popup Page With Javascript to Open in Main (Parent) Window
You cant replace attribute target, from attribute href. use el.target and just set the value var aEls = document.getElementsByTagName('a'); for (var i = 0, aEl; aEl = aEls[i]; i++) { aEl.target="_parent"; }

Categories : Javascript

window.open not working inside string
That's because you're putting quotes within quotes ('"Hello, "World!""'). You need to escape them using a backslash (). Change: onclick="window.open("...", "...", "...")" To: onclick="window.open("...", "...", "...")"

Categories : Javascript

On button click outlook window doesn't open
No Office app, Outlook included, can be used in a service (such as IIS). Extended MAPI (C++ or Delphi) can be used in a service. You can also use CDO 1.21 (it is no longer included with Outlook and has not been updated functionality-wise in the last 10+ years). Or you can use an Extended MAPI wrapped (Redemption). What does your Outlook code do?

Categories : C#

Why shellcodes with jmp instruction work, and why doesn't the labels work inside a C wrapper?
The address of mesg can vary depending on how your program is laid out in memory. The following will hard-code a specific address and will not work reliably (or at all): mov ecx, mesg For reference, the first approach hard-codes the following address: mov ecx, 0x804807d The second approach does work because it figures out the address of mesg at runtime, using the return address of a call instruction. Put another way, the first version only works if loaded at a specific address whereas the second is position-independent. It is worth noting that the jmp and the call instructions that appear in the second version use relative addressing, meaning that the opcodes specify the distance to the target rather than the address of the target. This makes these instructions work regard

Categories : Assembly

Ajax modal popup extender doesn't work and displays the panel on page load
Change your css. <style type="text/css"> .modalBackground { background-color: Gray; filter: alpha(opacity=70); opacity: 0.7; } .modalPopup { background-color: #ffffdd; border-width: 3px; border-style: solid; border-color: Gray; padding: 3px; width: 250px; } </style> And set ModalPopupExtender control property BackgroundCssClass="modalBackground". And panel CssClass="modalPopup".

Categories : Asp Net

Visual Studio doesn't open command window for console application
Your application is probably finishes its job so fast, that you dont notice the command window. Add Console.ReadKey(); at the end of your main function. That is assuming you actualy run an exe file.

Categories : C#



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.