[FX.php List] FX and Editing Global Fields

Gjermund Gusland Thorsen ggt667 at gmail.com
Wed Nov 17 14:37:19 MST 2010


I put us on facebook too:
http://www.facebook.com/pages/FXphp-Filemaker-Xml-parser/130583853636446

2010/11/16 Chris Hansen <chris at iviking.org>:
> Okay, now as to documentation, Gjermund has mentioned here that he has been putting some development versions of FX.php up on the sourceforge site for FX.php (yes, there is one, and it's been around almost as long as FX, though it hasn't been used much.)  I'll have a wiki of some sort going by Christmas, as well.  (Please hold me to this, folks =)  Basically, I realize that at this point, we've come a long ways, and there are a number of you that could make really solid contributions both in terms of development and documentation.  Additionally, FileMaker Web development is more mainstream than it was when FX.php first appeared.  This list is awesome, but people need better documentation than what I've done, and it won't hurt to have someone checking my facts, too =)
>
> Best,
>
> --Chris
>
> On Nov 15, 2010, at 5:55 PM, Bradley Creamer wrote:
>
>> Hi Karstyn,
>>
>> Here's the instruction set from the "Function Reference for FX.php":
>>
>> SetFMGlobal ($globalFieldName, $globalFieldValue)
>> This function is FileMaker 7 specific and is equivalent to appending ".global" to a field name in order
>> to set a global field. In order to ensure that a global is set in FIleMaker 7 (before performing a script,
>> for example), use this function instead of AddDBParam() to set the global field.
>>
>> >> The $globalFieldName parameter should contain the name of the FileMaker global field to be
>> set.
>>
>> >> The value passed via $globalFieldValue will be stored in the specified global field before other
>> FileMaker actions are performed.
>>
>> That's all I can find. So, my expectations of this function is to "set" the global field permanently regardless of session. I know that FMP11 handles things much differently than FMP6, but why would the DB reset the value of a global field when it's asked so specifically change that value?
>>
>> Regardless of my intent, where does it say globals are set on a per-session only, then revert?
>>
>> I did find this from FileMaker's CWP documentation:
>>
>>
>> For direct XML requests and requests made via XSLT stylesheets that don’t use sessions, the global values expire immediately after the request is made. For requests made via an XSLT stylesheet that use sessions, the global values persist for the duration of the session defined in the stylesheet, or until they are changed again with another request.
>>
>> I seriously don't understand this behavior. Does anyone know of a work-around that makes the NEW global field value persist using XML?
>>
>> Thanks,
>> Bradley
>>
>>
>> On 11/15/2010 4:41 PM, Karstyn McCoy wrote:
>>> Hi Bradley,
>>>
>>> Just to expand on this a bit, PHP can pull data from a global field, but it will default to the value that was stored while the database was last opened in single user mode.
>>>
>>> Remember that global fields are user session specific, so they can behave much different from the web then they may from a FM client. As Tim just mentioned the value may be set correctly, but each new PHP query starts a new user session, so you will not get the last value you set.
>>>
>>> It may help to know the broader issue you are trying to solve.
>>>
>>>
>>> --Karstyn
>>>
>>>
>>> On Mon, Nov 15, 2010 at 4:32 PM, Tim 'Webko' Booth <tim at nicheit.com.au> wrote:
>>>
>>> On 16/11/2010, at 11:25 AM, Bradley Creamer wrote:
>>>
>>>> Hi Chris,
>>>>
>>>> I'm specifically asking you this question because I found your post at:
>>>>
>>>> http://filemaker.463488.n4.nabble.com/Set-Global-Field-in-FileMaker-from-PHP-td2324363.html
>>>>
>>>> ... where you say that FX works when editing a global field.
>>>>
>>>> I haven't been successful.
>>>
>>> How do you know that?
>>>
>>> It may well be edited, but the next request you make effectively re-logs the web user in (the web is stateless...) so that the global will be rest to default... at least, that is my understanding...
>>>
>>> Now, my question - what are you trying to use a global field to do?
>>>
>>> Cheers
>>>
>>> Webko
>>>
>>> _______________________________________________
>>> FX.php_List mailing list
>>> FX.php_List at mail.iviking.org
>>> http://www.iviking.org/mailman/listinfo/fx.php_list
>>>
>>>
>>
>> --
>>
>> ****************************************************
>> De Anza Web Team / Technology Resources Group (TRG)
>> webteam at deanza.edu
>> ----------------------------------------------------
>> Update Your Firefox Browser! (www.firefox.com)
>> ****************************************************
>> _______________________________________________
>> 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