Editing Search Query variables

This forum is for all Flare issues related to the HTML5, WebHelp, WebHelp Plus, and Adobe Air Targets

Editing Search Query variables

Postby DaleFranks on Thu Mar 25, 2021 5:07 pm

When you perform a search, the UI Text for the HTML5 skin says something like "Your search for {query} returned {total_results} results."

In the output, the search term that is returned by the {query} var is enclosed in quotation marks, e.g., 'Your search for "search term" returned...'

I want to alter the operation of the {query} variable because when a user uses quotation marks in the search, the result is: 'Your search for ""search term"" returned...', and I want to eliminate the double quotes.

I'd like to replace the quotation marks that the {query] variable returns with some other characters, perhaps a single quote or >> << or [].

I can't for the life of me figure out where to go to change how these system variables are returned. Help?
DaleFranks
Jr. Propeller Head
 
Posts: 7
Joined: Fri Jun 12, 2015 12:56 pm

Re: Editing Search Query variables

Postby Dave Lee on Fri Mar 26, 2021 1:53 am

Unfortunately, Flare doesn't provide a way to customise that in the skin.
The quotes appear to be added by Flare scripts at runtime, so your only option is to write your own script to modify that; i.e. get the text from span.query, remove/replace the quotes, then replace it with new text.
Dave Lee
Master Propellus Maximus
 
Posts: 5961
Joined: Mon Mar 05, 2007 8:33 am
Location: UK

Re: Editing Search Query variables

Postby DaleFranks on Fri Mar 26, 2021 11:40 am

*sigh*
That's what I was afraid of. Thanks for the answer.
DaleFranks
Jr. Propeller Head
 
Posts: 7
Joined: Fri Jun 12, 2015 12:56 pm


Return to Web-based Outputs

Who is online

Users browsing this forum: No registered users and 13 guests