Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Browser specified search operators in Lasso 6

Featured Replies

Platform: E-mac G4

System: 10.2.3

Server: Apache 1.3

Database: FileMaker6 Unlimited

Lasso: Version 6

Question:

How do you allow a browser to choose a search operator on a field and have it operate on that field in an inline search (in a different format file), preferably in Strict Lasso 6?

The

<select name="Operator">

<option value="eq">equals</option>

etc

It's all to do with the order in which Lasso processes stuff

you may have to look at your approach to this........ have a look into processing an output tag..... info about process and output tags can be found in the LDML reference that comes with Lasso

NB don't forget those escape chars ( )

have a go

smile.gifsmile.gifsmile.gif

NB

I would recommend setting variables with the user's search choices and putting those in the output tag.

  • Author

Thank you for your reply. I think I've found every possible way of not making it work, but being new to Lasso I've learnt a bit in the process. I couldn't get any joy from [Output] or [Process] tags, even though I could make a variable of the combined operator and FieldNames, which was quite a lot further than I had managed before:

[Variable: 'CombinedVariableName' =''] [Variable: 'CombinedVariableName' = (Output: '-Operator='', $OperatorNameVariableName,

Output: '', ', Output: ''FieldName'='', $FieldNameVariableName, Output: ''')]

However, whatever I did I just couldn't seem to get it to fire up in the [inline], though I would have thought that:

[Process: (Variable: 'ComBinedVariableName')] would have worked. However I finally found a way and I've included the notes to myself below for anyone in the same situation that I was:

Make the Search format file into an HTML Form, using standard

<Form Action="resultsfile.lasso", Method="post"> action, and insert HTML Operator value lists, giving each a distinctive name, eg:

<select name="Op1">

<option value=""selected>- Select -</option>

<option value="cn">Contains</option>

<option value="eq">Equals</option>

</select>

...coming directly before the field the operator is to operate on:

<input type="text" name="FieldName" value="" size=40>

Use an input button such as:

<Input type="Submit" name="-Nothing" value="Start Search">

The 'name="-Nothing"' stops Lasso trying to perform any actions, such as trying to find fields with the names given to the operators.

In the Results format file, start by making variables of the field operator and its contents by using :

<?LassoScript

Local: 'OperatorNameVariableName'= 0;

$OperatorNameVariableName=(Action_Param:'OperatorName');

?>

<?LassoScript

Local: 'FieldNameVariableName'= 0;

$FieldNameVariableName=(Action_Param:'FieldName');

?>

although 'Variable' can be used instead of 'Local'. (The first line is a precaution.)

The Search criteria is inserted directly into the [inline]:

[inLine: -Search,

-Database='DatabaseName', -Table='TableName,

-Operator=(Variable: 'OperatorVariableName'), 'FieldName' = (Variable: 'FieldVariableName'),

etc with all the remaining Operator/Fields, the other [inLine] requirements and the usual outs or messages if not records are found, and the records themselves are then sandwiched between [Records][/Records] tags before the final [/inLine].

Did I miss something, or is there nothing in the tutorial literature that explains this?

RE: [Process: (Variable: 'ComBinedVariableName')]

u dont need to process this.... you want to process the inline with the vars (ie the search criteria) added.......

one to think about

smile.gif

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.