Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Disable Chrome address bar autosearch for dev

Developing a web app locally and I just can't get Chrome to actually go to this address, because auto search always kicks in (http://0.0.0.0:5000/api works though, for example).

enter image description here

Is there a way to overwrite this behaviour or force Chrome to try a http request first, before anything else?

I am aware I can just curl it or whatever to see the response...

like image 583
kontur Avatar asked Jan 29 '15 11:01

kontur


3 Answers

Go to chrome://omnibox/ and check [x] Prevent inline autocomplete

The answer to this has to be in chrome://chrome-urls

you should see something like the following:enter image description here

The "full" set of settings is on the chrome://chrome-urls . Also chrome://flags is worth to check. As a side by enabling some experimental features from chrome://flags you can greatly enhance your browsers HTML5 support which can be checked at HTML 5 support . chrome://chrome-urls

else: Clear browser historythen go to settings and under Privacy --> uncheck [] Use a prediction service to help complete searches and URLs typed in the address bar . Another idea is to examine carefully if using linux the output of the following command for parameters: ps -aux | grep google-chrome-stable in my case the output tells me a lot about what parameters are used at launch by default:

/opt/google/chrome/chrome --type=renderer --disable-layer-squashing --enable-transition-compositing --enable-deferred-image-decoding --enable-display-list-2d-canvas --enable-distance-field-text --enable-encrypted-media --enable-experimental-canvas-features --enable-experimental-web-platform-features --enable-lcd-text --enable-one-copy --enable-overlay-scrollbar --enable-renderer-mojo-channel --enable-smooth-scrolling --enable-viewport-meta --enable-webgl-draft-extensions --enable-web-midi --enable-zero-copy --max-tiles-for-interest-area=512 --enable-plugin-power-saver --lang=en-US --force-fieldtrials=AutoReloadExperiment/FlagEnabled/AutoReloadVisibleOnlyExperiment/FlagEnabled/ChromeSuggestions/Default/DomRel-Enable/enable/EnhancedBookmarks/Default/ExtensionContentVerification/Enforce/ExtensionInstallVerification/None/GCM/Enabled/MaterialDesignNTP/Enabled_forced/OmniboxBundledExperimentV1/StandardR4/PasswordGeneration/Disabled/PrerenderFromOmnibox/OmniboxPrerenderEnabled/QUIC/FlagEnabled/SafeBrowsingIncidentReportingService/Default/SettingsEnforcement/no_enforcement/UMA-Dynamic-Binary-Uniformity-Trial/default/UMA-Population-Restrict/normal/UMA-Uniformity-Trial-1-Percent/group_09/UMA-Uniformity-Trial-10-Percent/group_02/UMA-Uniformity-Trial-100-Percent/group_01/UMA-Uniformity-Trial-20-Percent/group_04/UMA-Uniformity-Trial-5-Percent/group_16/UMA-Uniformity-Trial-50-Percent/group_01/UwSInterstitialStatus/OnButInvisible/VoiceTrigger/Install/WebRTC-IPv6Default/Default/ --enable-crash-reporter=9F2AFD26-85F1-40CB-991F-0980EF2C4D14 --enable-offline-auto-reload --enable-offline-auto-reload-visible-only --enable-offline-load-stale-cache --enable-app-window-controls --enable-embedded-extension-options --enable-experimental-extension-apis --enable-scripts-require-action --enable-nacl --enable-nacl-debug --enable-streamlined-hosted-apps --enable-web-based-signin --javascript-harmony --out-of-process-pdf --enable-delegated-renderer --enable-impl-side-painting --num-raster-threads=4 --enable-gpu-rasterization --channel=5035.27.2136067136

Even yet another idea is maybe to write a small widget using python's tkinter and the webrowser modules, it could even get its input from the clipboard.

this command could be a work around solution too:

 python -m webbrowser -t "http://ip.ip.ip.ip:portport/file/"

Another option yet is to use The Omnibox API and embed a custom omnibox in a simple webpage. Here are the omnibox api ready made samples.

like image 139
Schopenhauer Avatar answered Oct 24 '22 01:10

Schopenhauer


You can avoid this by adding a "/" at the end of the URL http://0.0.0.0:5000/api/

or

You can try to add a null search engine with a URL of http://%s and null keyword.

Go to the search engine settings:

  • Open Settings.
  • Click Manage search engines
  • At the bottom of the Other search engines section add a new search engine. Screenshot of Settings
like image 29
Juan Buhagiar Avatar answered Oct 24 '22 01:10

Juan Buhagiar


Using @Juan Buhagiar answer as a starting point, I added your URL as the URL of a default search engine:


Other search engines

| MyAPI | 0.0.0.0 | http://0.0.0.0:5000/api/venues/show/45/20/cafes?rubbish=%s |

That just worked. The only drawback is that you get a redundant query to your request:

http://0.0.0.0:5000/api/venues/show/45/20/cafes?rubbish=0.0.0.0%3A5000%2Fapi%2Fvenues%2Fshow%2F45%2F20%2Fcafes%2F

instead of plain:

http://0.0.0.0:5000/api/venues/show/45/20/cafes

So as long as it does not conflict with your own GET, you can just ignore it.

like image 1
ptrk Avatar answered Oct 24 '22 01:10

ptrk