How to stop Netbeans opening my index on run? - html

When I run my project in Netbeans 6.8, it loves to open the index page automatically. It's annoying because I always keep a tab with the page I'm working on when I work, so I don't need this index page. It also makes my current page lose focus.
I have tried not specifying an index or my project URL, but then I can't run or save my project.
How can I prevent it from doing so?

In NetBeans 7.4:
Right-click your project, select 'Properties'
In left hand pane of popup, select 'Run Configuration'
In the right pane of the popup, in the bottom right corner of the list of fields, click 'Advanced...'
Select radio button 'Do Not Open Web Browser'

I ran into that issue as well. The solution is quite simple - go to the menu bar:
Run/Run File.
That's it. It will just run the current php script without going to the index.php.

Basically, you want to reopen the same page (refresh it ?) in the browser ? You can set settings in the project properties > run configuration, then chaange the index file or project url. But apart from that I am afraid that you can't do anything to prevent opening a new window on run. When you click 'run', netbeans says to your OS : "Hey, let's open that page (your_project_URL/index_file) now". The OS thinks and execute a command like "default_browser url", where the argument "url" is here your_project_URL/index_file. Then the browser thinks it's a new page to open, and BAM, opens a new page.

Just use shift+F6 which will open the current page with focus.

Related

Drag and drop a window upwards in sikuli

Background:
I am trying to automate a desktop application using sikuli with Java.
When we click on a Browse button in the application, it will open a new window to select destination folder to download some files.
We need to click OK button once the folder is selected.
Problem:
Whenever we click on Browse button, an enlarged window is opened by default in the lab execution machine where the script is running.
Due to this, the OK button is not visible on screen.
We have to move the Browse window upwards in order to make it visible.
I tried using Region.dragDrop() method to move the window upwards.
However, it is not find the destination match which is behind the Browse window.
Please guide me in coming up with a working approach to this problem.
This is an indirect solution to your problem. Since drag/drop and other "visual" actions are usually more flaky and harder to automate, I suggest you use keyboard shortcuts as much as possible. In your case, if the blocking window is opened last, I assume it becomes the active window which means you can minimize it using Win+down combination (assuming you are in Windows).

When designing website is opening new tab as bad as a popup window

My web application is mimicing the UI of my desktop application, flow is as follows
Select Task in browser window
Change any Options and then start
Show Progress in same browser window, the progress bar goess back to server every 5 seconds checking progress.
When task has completed we show report in new tab
and go back to Select task Window,
this is done by running following Javascript in progress page
window.open('/start','_self'); window.open('/reporturl','_blank');
This works fine on my PC but when trying on Safari on OSX and on Android phone and iPad one of two things happen
The progress page becomes the start page but the report page is not opened in tab
The Progress page becomes the report page
My question is does opening window in new tab with _blank have all the problems of using popup windows. If so should I modify my prcoess so that at stage 3 it just displays report page, and then add a back button or navigable footer to the report to allow user to get back to start page ?
I can think of some options you could use instead of new tab.
Modal with Ajax
-- With jQuery it is posible to open modal
dialogs they can be populated with html (or other data) fetched with ajax (async). I am a big fan of these and use them all over my projects. Users will not be annoyed with pop-up warning messages, etc. Once the content is read (or whatever) the user can simply close the dialog. (If I had to make your app I would certainly implement this).
Besides the jQuery dialogs, other modal/dialog scripts are out there. Check out Bootstrap Modal if you like it modern.
Serve report as download
-- Depending on what the user can/will do with the report, it might be interesting to write the report page in a way that it sends back a .pdf file, or another type of file, as download. Loading the URL in a new tab will now always start a download. Triggering this from JS without user interaction might be a problem though (same as with pop-up / new tab). Adding a button to trigger the download on complete will solve this.
I know the question was about the use of tabs.. But try to avoid it. Browsers handle it all in their own way. And many users get confused when suddenly stuff is opening in tabs when they did not ask for it. In case of pop-ups, it is possible for users to turn them of or convert into opening a new tab from within the browser settings. If they have been fiddling with browser defaults, you'll have troubles of keeping the 'flow' of the app the same for all users (and cross browser).

Chrome load tab without selecting it

The question is opposite to this one.
Say I open link in a new tab. Currently it is opened, but not loaded. It starts loading only when I select it. I want so that I open a lot of links on a page and those tabs start loading without need to be selected.
Furthermore, there is another problem. When I open link, select that tab, tab is loaded. Then I go to another tab, do something there and return to the first tab. So this tab starts to reload again.
How to fix this?
My version of Chrome is - 48.0.2564.116. It starts to happen recently.
If you are using (in settings) "continue where you left off" then switch to "Open specific page or set of pages" try it there, then switch back
The answer is https://superuser.com/questions/1048029/disable-auto-refresh-tabs-in-chrome-desktop#answer-1049471. Shorter, the flag #automatic-tab-discarding needs to be disabled on chrome://flags.

Don't show run tab after launch in Android Studio

I'm developing apps in Android Studio. But everytime I hit Run button, the Run tab pops up automatically from bottom with messages like Installing com.packagename etc..., Success, Launching
I've already disabled automatic displayin of Android DDMS tab (because I use DDMS from toolbar which opens new window) by editing configurations. But I can't disable this stupid automatic Run tab showing.
Is there any way to do this ?
There is no standard way of achieving this but I found an interesting workaround mentioned below and using the same.
When your run tab is opened, Instead of hiding it using right-top corner button, Drag it till it hides.
Like in picture shown below
Now Run your project run window wont appear, When you want it back click on run button in horizontal bar.
Working perfectly for me .
In case anyone still struggling with this annoying thing, there is a way to disable this annoying popup.
Note: this will remove the run tab altogether.
So basically go to your Run/Debug configuration and Uncheck Activate tool window at the bottom.
This gets rid of the Run tab.

accessing a chrome extension from outside the browser

Is it possible to access a Chrome Extension from outside the browser?
I would like to be able to run a command from my text editor (MacVim) that refreshes the page on which I am working. From reading the Chrome Extension documentation it looks like I could try something really hack-y, like opening a page that uses Chrome message passing to refresh another page, but there does not seem to be a strait-forward way to do this.
I am running Mac OS X. I've tried the shell command:
$ open <url>
But that opens a new tab every time in Chrome, so this doesn't help when I'm using the developer tools
You are right, there is no straight forward solution.
Your hacky approach is the simplest way to go. Only instead of messaging I would put a tab creation listener into background page, and when a tab with some special URL is created (http://example.com/?do=refresh) - close it and refresh the next selected tab. You will see new tab flickering, but that's as good as it gets.
You can also look into using WebSocket API, for which you would need to write a server side app (which you need to call from your editor somehow). Not sure how this all might turn out.