[FX.php List] Using global variables when calling a FileMaker Script

Tim 'Webko' Booth tim at nicheit.com.au
Wed Feb 29 23:01:26 MST 2012


His answer addressed that. 

Every query via the web will behave as if you have logged on for the first time. All globals will be at default values for each query. 

Tim 'Webko' Booth
[m] 0418 993 306

On 01/03/2012, at 3:38 PM, John Funk <csinfo at criticalsolution.com> wrote:

> Thanks Chris,
> Good to know about the session variables but what I am trying to figure out
> is the behavior of global FIELDS while running a FileMaker script from
> PHP/FX. My FM script has multiple sub scripts that use common global fields.
> Running these from a FM Client and as a server script works but not when
> executed from PHP/FX.
> Thanks
> 
> On 2/29/12 10:13 PM, "Chris Hansen" <chris at iViking.org> wrote:
> 
>> John,
>> 
>> Look at it this way: a connection via PHP is like connecting to FileMaker
>> Server, performing a query, and then logging out again.  Based on that, keep
>> in mind that global variables only persist until you log off.  So, you can use
>> globals, as long as you set them as part of the query, and don't expect them
>> to persist to subsequent queries (use $_SESSION variables for that.)  Oh, and
>> to set globals via FX.php use FX's SetFMGlobal() method.  HTH
>> 
>> --Chris
>> 
>> On Feb 28, 2012, at 4:09 PM, John Funk wrote:
>> 
>>> Can someone tell me if FX/FMServer Advance deals with script globals
>>> differently than a FielMaker Client or as a Server script?
>>> I have a very complicated FM script that parses data to make “Jobs”. It runs
>>> great as a Server script and as an FM Client script but will not run or is a
>>> runnaway when called through FX. I am guessing the globals variables are not
>>> being used.
>>> I may have to rewrite the script to use $$ variables, but not sure.
>>> As usual, any help is appreciated.
>>> Thanks,
>>> John Funk
>>> _______________________________________________
>>> FX.php_List mailing list
>>> FX.php_List at mail.iviking.org
>>> http://www.iviking.org/mailman/listinfo/fx.php_list
>> 
>> _______________________________________________
>> FX.php_List mailing list
>> FX.php_List at mail.iviking.org
>> http://www.iviking.org/mailman/listinfo/fx.php_list
> 
> 
> _______________________________________________
> FX.php_List mailing list
> FX.php_List at mail.iviking.org
> http://www.iviking.org/mailman/listinfo/fx.php_list


More information about the FX.php_List mailing list