ATTENTION: You are viewing a page formatted for mobile devices; to view the full web page, click HERE.

DonationCoder.com Software > Find And Run Robot

Possible to lower/upper case Regex Alias Filter Pattern matches?

(1/1)

Merlin2001:
Hi @all,

I'm a long time devoted FARR user and started to use aliases more heavily recently.
Now I have a problem I couldn't solve by myself (using the help, the forum and trial and error) and hope somebody can point me in the right direction :D

I have setup an alias that calls a URL in my browser if prefixed with '@'.
So searching @test will open the browser with https://foobar.com/test.
This works like a charm!

The problem now is, that the URL is case sensitive while I want the query to be case insensitive.
So searching @TesT should also open https://foobar.com/test because https://foobar.com/TesT will give me a 404.
Unfortunately, I have no power to fix this on the target side :(

Is there any way to convert the $$u1 placeholder in my URL to lower case?

Thanks in advance for all your thoughts!
Marcus

Nod5:
I don't think there is a built in method in FARR to do that, though I might be wrong.

Here is a workaround where you pass the search string to AutoHotkey which makes it lowercase and runs the search. You can change the alias name, folder path, base URL and so on to fit your use case.

First create the alias
- alias name: _
- RegEx: _(.+)
- Result(s): C:\folder\search_lowercase.exe "$$1"

Next save this code as search_lowercase.ahk, compile it and move to C:\folder\search_lowercase.exe

--- Code: Autohotkey ---#NoEnv#SingleInstance force;Search Google for input parameter stringif A_Args[1]  Run % "https://www.google.com/search?q=" Format("{:L}", A_Args[1])

Merlin2001:
Hi Nod5,

sorry for my late reply and thank you very much for your suggestion!
I didn't think about pre-processing with an AutoHotkey script and may go down that route :D

Have a great week!
Marcus

Navigation

[0] Message Index

Go to full version