deanishe Posted July 6, 2015 Share Posted July 6, 2015 (edited) Ref: http://www.alfredforum.com/topic/5993-custom-searches-with-full-url-as-the-query/ Unless {query} is the entire URL, the Open URL action behaves as if {query} is a query string value and URL-encodes it, i.e. it assumes: http://www.example.com/page?arg={query} This is not always the case, however. {query} may also be a part of the URL path, e.g. http://www.example.com/{query}/some/other/thing In the latter case, most browsers will choke on the URL (I think only Firefox is smart enough to handle URL-encoded paths).Alfred should ideally provide a checkbox to turn URL-encoding of {query} off to avoid messing up {query}.Alternatively, it could try to determine whether {query} is actually the value of a GET parameter (for example, based on the presence of "arg=…"), but the on/off option is probably more robust. Edited July 6, 2015 by deanishe Link to comment Share on other sites More sharing options...
Andrew Posted July 7, 2015 Share Posted July 7, 2015 I agree, there are definitely improvements which can be made in this area, but I may leave this until a more major release (as there is the Workflows workaround at this point). Other improvements would be the option to encode spaces as other characters such as - and _ which would give even more flexibility. I've added a ticket smarg19 and deanishe 2 Link to comment Share on other sites More sharing options...
alocknkey Posted September 14, 2022 Share Posted September 14, 2022 I see in Alfred 5 we changed some of the encoding setup. I have a custom search that takes the query value and puts it into an Atlassian JQL search. Unfortunately Atlassian reserves the space character and now with the forced encoding I cannot find a way to keep it an actual space. More info on Atlassian JQL can be found https://confluence.atlassian.com/jirasoftwareserver0820/search-syntax-for-text-fields-1095249262.html. Essentially my resulting URL I want to send to the browser should look like this `https://URL/issues/?jql=text~"alfred app"` and my custom query looks like this `https://URL/issues/?jql=text~"{query}"` . Is there an option to not modify the query? This used to work in Alfred 4, I believe. Link to comment Share on other sites More sharing options...
vitor Posted September 14, 2022 Share Posted September 14, 2022 (edited) @alocknkey Try doing it as a workflow instead: connect a Keyword Input to an Open URL Action (which has finer control over the encoding). Edited September 14, 2022 by vitor alocknkey 1 Link to comment Share on other sites More sharing options...
alocknkey Posted September 14, 2022 Share Posted September 14, 2022 (edited) @vitor - I don't have access to that post for some reason. But the workflow works thanks for the suggestion. Unfortunately now I cannot have it as a fallback search 😕 Edited September 14, 2022 by alocknkey Link to comment Share on other sites More sharing options...
alocknkey Posted September 14, 2022 Share Posted September 14, 2022 After researching this more I found a better URL to send to our Jira instance. Thanks for the reply. Link to comment Share on other sites More sharing options...
vitor Posted September 14, 2022 Share Posted September 14, 2022 1 hour ago, alocknkey said: Unfortunately now I cannot have it as a fallback search You can, by adding a Fallback Search Trigger to the workflow. Link to comment Share on other sites More sharing options...
dannysamk Posted September 20, 2022 Share Posted September 20, 2022 (edited) @vitor Thanks that helped I ran into the exact same issue I had to create a workflow to disable encoding the {query} parameter option. Previously I was able to get this working with Web search now it encodes the % itself breaking the Jira search. The working config is here for anyone who is looking for a fix. This Web search config as shown below no longer works 💔 We need to do this Create a workflow as mentioned here Then uncheck encoding for {query} placeholder Now disable the Web search and only have the Workflow enabled 👍 Edited September 20, 2022 by dannysamk Link to comment Share on other sites More sharing options...
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