politicus Posted August 5, 2019 Share Posted August 5, 2019 (As I am not sure if it is already possible, I post this thread here and not in Alfred features suggestions). I was thinking about web searches found cool how easy it is to create them. One url + {query}. Done. I was wondering if it was possible to perform multiple queries at once. For example typing the following in Alfred's bar: one web searches keyword + {query1}+{query2}+{query3}. with the alexa.com web search I sat it would give : sale keyboardmaestro.com,alfredapp.com,google.com It would open 3 tabs with the result of each query. Maybe there are other way to do it. I am just trying to find a way not to have to perform the same task three times. Link to comment
deanishe Posted August 5, 2019 Share Posted August 5, 2019 2 hours ago, politicus said: sale keyboardmaestro.com,alfredapp.com,google.com That's not practically possible with a built-in websearch, no: That would make it impossible to search for anything with a comma in it. It can be done easily enough with a workflow, however. You just need to split your input on whichever delimiter you've chosen (comma in your case), add it to the URL, then open it. Link to comment
politicus Posted August 5, 2019 Author Share Posted August 5, 2019 Thanks @deanishe That makes sense. I do not understand how I can "add" my input to the URL. Here is my workflow : https://ufile.io/7ixxc19t (file will be deleted in 30 days). Link to comment
deanishe Posted August 5, 2019 Share Posted August 5, 2019 1 hour ago, politicus said: I do not understand how I can "add" my input to the URL. Not by using {query}. Have you read the docs on splitting argument to variables? Try adding a Debug utility, so you can see what's being passed between workflow elements. Link to comment
politicus Posted August 5, 2019 Author Share Posted August 5, 2019 (edited) Yes, I did I even tried the workflows. The output will then contain the list of variables you've just created I do not know how to work with the variables I get from the split action. Here is what I get from the debug : [20:32:39.148] Multiple queries at once[Keyword] Processing complete [20:32:39.149] Multiple queries at once[Keyword] Passing output 'google,yahoo,bing' to Split Arg to Vars [20:32:39.149] Multiple queries at once[Split Arg to Vars] Processing complete [20:32:39.150] Multiple queries at once[Split Arg to Vars] Passing output 'google,yahoo,bing' to Debug [20:32:39.151] Multiple queries at once[Debug] 'google,yahoo,bing', { var1 = "google" var2 = "yahoo" var3 = "bing" } [20:32:39.151] Multiple queries at once[Debug] Processing complete [20:32:39.152] Multiple queries at once[Debug] Passing output 'google,yahoo,bing' to Open URL Edited August 5, 2019 by politicus Link to comment
deanishe Posted August 5, 2019 Share Posted August 5, 2019 Well, the no-code way would be to add a bunch of Filters with “if var1 is not empty”, “if var2 is not empty” etc. And connect each one to an Open URL action that uses {var:var1}, {var:var2} etc. instead of {query}. That’s clunky, though, and it would be better to write a few lines of code to grab all the variables and stick them in URLs. If you’d prefer that, I can help you with the code. Link to comment
politicus Posted August 9, 2019 Author Share Posted August 9, 2019 Thanks @deanishe But given my current programming skills, I prefer to add this in my workflows idea list. Message to anyone: feel free to steal the idea and develop the workflow 😀 Link to comment
deanishe Posted August 9, 2019 Share Posted August 9, 2019 6 hours ago, politicus said: But given my current programming skills Well why don't you give it a try, and I'll help you. That way, your programming skills might improve dfay 1 Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now