ibotubot 3 Posted March 9, 2017 Report Share Posted March 9, 2017 Hi guys, I need to click a link and normally in Chrome it just opens a new tab, but in Ubot its the same tab. While I can go back with JS this is not really ideal (proxies and all).I there a way to click a link and have it open in a new tab? Tried with jquery but could not make it work. I know I can scrape the URL and open in new browser, but I need the click to happen so that solution does not work here. Thanks Quote Link to post Share on other sites
deliter 203 Posted March 9, 2017 Report Share Posted March 9, 2017 I'm not sure I exactly follow, but I think this is what your looking for You mightn't need the change attribute bit of code below but might help you allow popups("In New Window") navigate("http://www.ubotstudio.com/resources","Wait") wait for browser event("Everything Loaded","") change attribute($element offset(<login link>,0),"target","_blank") click($element offset(<login link>,0),"Left Click","No") in popup { alert("hello from window {$url}") close page } Quote Link to post Share on other sites
deliter 203 Posted March 9, 2017 Report Share Posted March 9, 2017 I am also guessing you want the user to be able to click stuff if so try this, very crappy code but works, click the login button manually, code will run until you switch page of main browser allow popups("In New Window") define navigateWithUserControl(#url) { navigate(#url,"Wait") wait for browser event("Everything Loaded","") change attribute($element offset(<login link>,0),"target","_blank") loop while($comparison(#url,"=",$url)) { in popup { alert("hello from window {$url}") close page } wait(0.1) } } navigateWithUserControl("http://www.ubotstudio.com/resources") 1 Quote Link to post Share on other sites
ibotubot 3 Posted March 10, 2017 Author Report Share Posted March 10, 2017 Thanks , for some reason just saw this now. I tried it with jquery before, totally missed on the internal functionality.The site I am working with has it set up differently, but I am just experimenting with simply replacing the destination with "" seeing if it still counts the click on it. Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.