Forum Discussion
Hannes_Rapp
Nimbostratus
Using your sample, you can conver it to lower-case, before using the variable for any string comparisons: set myparam [string tolower [URI::query [HTTP::uri] myparam]]
Alternatively:
set myparam [string tolower [HTTP::query]]
In case of a request www.asd.fgh/asd?fFF=1, the code above would return "fff=1" (without the query question mark).
if you want to include the query question mark, use the code below which will return "?fff=1"
set myparam "?[string tolower [HTTP::query]]"
Oct 12, 2015
thanks Hannes but your understanding of the URI::query function does not match my own. My understanding is that 'URI::query uri-string query-param-name' returns 1 if "query-param-name=x" ( irrelevant of value of x ) is present in uri-string, and 0 if it's not.