[FX.php List] Alternate grammar?

Nick whatdoyouwant at gmail.com
Mon Feb 18 13:29:09 MST 2013


I wanted to add to this - usePortalIDs=true doesn't do anything unless you
have the actual portal object on the layout.


On Thu, Feb 7, 2013 at 1:42 PM, Nick <whatdoyouwant at gmail.com> wrote:

> If you're starting a new project using FM Server 12 (and you use portals
> on your layouts), it is advisable to set $myQuery->usePortalIDs = true;
> the difference is that portals have their record id/modid instead of zero
> through x.
>
> That means that instead of using a for loop, use a foreach loop to walk
> through the portal records (which is backwards compatible with the old way
> as well).
>
> foreach ( $record['PortalTable::IDField'] as $portalkey => $portalIDData)
> {
>   echo $record['PortalTable::OtherField'][$portalkey];
>
> // only now portalkey is not 0 or 1, etc.  It is recordnumber.modID like
> the ['data'] array.
>   $portalTable_recordinfo = explode('.', $portalkey);
>   $portalTable_recordid = $portalTable_recordinfo[0];
> // if you wanted to loop through and edit, or something, use the recordID.
>
> }
>
>
> usePortalIDs is set to false currently in order to maintain backwards
> compatibility with the old code, for people that would use a for loop.
>
>
> On Thu, Feb 7, 2013 at 10:03 AM, Michael McIntyre <aragon at umich.edu>wrote:
>
>> To answer my own question, fmresultset.xml grammer can be invoked from
>> the initial FX call,
>>   $myQuery = new FX($dbIP,$dbPort,$dbType);
>> where $dbType='fmalt';
>>
>> This would be an excellent addition to the PDF documentation.
>>
>> ~Michael
>>
>> On Mon, Jan 28, 2013 at 4:13 PM, Michael McIntyre <aragon at umich.edu>
>> wrote:
>> > What config (in which files) is needed to invoke the fmresultset.xml
>> grammer
>> > & RetrieveFM7VerboseData.class.php?
>> >
>> > I set $dataServerType = 'fmalt' to no avail...
>> >
>> _______________________________________________
>> FX.php_List mailing list
>> FX.php_List at mail.iviking.org
>> http://www.iviking.org/mailman/listinfo/fx.php_list
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.iviking.org/pipermail/fx.php_list/attachments/20130218/ec34f797/attachment.html


More information about the FX.php_List mailing list