PowerToys-Run-WebSearchShortcut icon indicating copy to clipboard operation
PowerToys-Run-WebSearchShortcut copied to clipboard

Allow multiple URLs for one search

Open mbaas2 opened this issue 1 year ago • 6 comments

It might be nice if the url of a search could be an array of multiple strings - so that it would be possible to pass one search to multiple engines at once ;)

mbaas2 avatar Mar 30 '24 12:03 mbaas2

Hi, thanks for your advice. I think this feature will conflict with other features (such as search suggestions). Also, I want to keep the functionality of this plugin as simple as possible.

Daydreamer-riri avatar Apr 05 '24 09:04 Daydreamer-riri

Oh man, I really support the multi-url idea. I think we don't need search suggestions or any other extras. I use another launcher where this feature exists and it is really a time saver. For my work, I use a lot of sites to search on, but for a very simple usage would be:

?? shop 'keyword' -> search on eBay, Amazon, etc. at once on the default browser's default provider.

I know this is not the plugin for it, but if you could make this happen in another plugin sometime, it would be very much appreciated.

If it matters, you could look at Fluent Search's Web Settings for ideas. I set the tag and the keyword and it searches on every site I gave. That app also started with only one url search but then they developed it to work with multi-url.

image

DRYN07 avatar May 16 '24 08:05 DRYN07

‌‌@DRYN07 Perhaps this could work. I wonder where these icons are sourced from?

Daydreamer-riri avatar May 17 '24 09:05 Daydreamer-riri

It is basically a json file, i will attach it when I get back to my pc, maybe it will help :D

DRYN07 avatar May 17 '24 10:05 DRYN07

This is from an older version because in the new one it is encrypted. Sometimes there was a link for the icon but it is null now...

I think this was rewritten because when I first updated from 0.9 to 1.0, it was not encrypted but the js is changed.... I don't know if this code helps, but I made a multi search with the "shop" keyword. It searches on google and bing.

[
  {
    "SettingName":"AutomaticallyShowPreview",
    "Value":false
  },
  {
    "SettingName":"UseMobileWebsite",
    "Value":true
  },
  {
    "SettingName":"ImprovePerformance",
    "Value":false
  },
  {
    "SettingName":"OpenLinksInBrowser",
    "Value":false
  },
  {
    "SettingName":"WebPreviewZoomFactor",
    "Value":1
  },
  {
    "SettingName":"EnableApplication",
    "Value":true
  },
  {
    "SettingName":"SearchTagOnly",
    "Value":false
  },
  {
    "SettingName":"Search hotkey",
    "Value":{
      "Name":"Keyboard shortcut to start searching using Web",
      "HotKeys":[
        
      ]
    }
  },
  {
    "SettingName":"Search key gesture",
    "Value":null
  },
  {
    "SettingName":"Default suggestion provider",
    "Value":{
      "SelectedItem":"Google"
    }
  },
  {
    "SettingName":"Custom suggestion provider",
    "Value":""
  },
  {
    "SettingName":"Web search URLs",
    "Value":[
      {
        "Name":"Shop",
        "Image":{
          "Value":null
        },
        "Icon":null,
        "Tag":"shop",
        "Url":"https://www.google.hu/search?q=%s https://www.bing.com/search?form=\u0026q=%s",
        "SearchTagOnly":false,
        "SuggestionUrl":null
      }
    ]
  }
]

DRYN07 avatar May 17 '24 13:05 DRYN07

This feature will be added in the next version.

Daydreamer-riri avatar May 19 '24 04:05 Daydreamer-riri

‌‌‌Hello @mbaas2 @DRYN07, the latest version now supports multiple URLs, see: https://github.com/Daydreamer-riri/PowerToys-Run-WebSearchShortcut?tab=readme-ov-file#urls

Daydreamer-riri avatar May 25 '24 14:05 Daydreamer-riri

Sorry, but there is a problem - even with your GoogleAndBingSearch: after typing "??GoogleA" and clicking "GoogleAndBing", a new browser window is opened with the default URL!

mbaas2 avatar May 27 '24 07:05 mbaas2

Hi @mbaas2, I haven't encountered a similar situation, everything is normal on my end.

I noticed that you used the word "Clicking," did you accidentally click on this context menu? This is a quick way to enter the domain:

image

Daydreamer-riri avatar May 27 '24 17:05 Daydreamer-riri