[FX.php List] Related Data on a second server
Stephe Pocock
zippyaus at yahoo.com
Fri Jun 1 02:01:04 MDT 2012
{bump} does anyone have data being displayed from two Filemaker servers? If so, how do you do it.
Thanks
Stephe
________________________________
From: Stephe Pocock <zippyaus at yahoo.com>
To: FX.php Discussion List <fx.php_list at mail.iviking.org>
Sent: Monday, 28 May 2012 4:47 PM
Subject: [FX.php List] Related Data on a second server
Hi all
For performance and dependability reasons we have two Filemaker servers.
On server one I have a comments database and on server two I have a contacts database.
Comments display the related contact in Filemaker without and issue.
If I try and display the contact details in the results returned on the comments database, I don't get a result.
Is this possible using FX.php?
I am trying to get the full name to return from the contacts database. <?php echo $comment['Comment_StaffContact::FullName'][0];?>
Full code below.
Any help would be greatly
appreciated.
Regards
Stephen
<?php
include_once("FX/FX.php");
include_once("FX/server_data.php");
include_once("FX/FMErrors.php");
$resourceId=$_REQUEST['resourceId'];
$resourceType=$_REQUEST['resourceType'];
$comments=new FX($serverIP,$webCompanionPort,'FMPro7');
$comments->setDBData('Precedents.fp7','comment_web','1000');
$comments->SetDBUserPass ($webUN, $webPW);
$comments->AddDBParam('Comment::resource_id',$resourceId);
$commentsResult=$comments->FMFind();
//foreach ($commentsResult['data'] as $key => $comment)
?>
<?php
if($commentsResult['foundCount'] == 0){
echo 'resource id';
include_once("includes/error.php");
}
else{?>
<html>
<head>
<title>Precedents</title>
</head>
<body>
<div id="primary_content">
<ul class="comments">
<?php foreach ($commentsResult['data'] as $key => $comment) { ?>
<li>
<div><span class="comment_name"><?php echo $comment['Comment_StaffContact::FullName'][0];?> </span> <?php echo $comment['comment_text'][0];?> </div>
</li>
<?php } ?>
</ul>
</div>
</body>
</html>
<?php } ?>
_______________________________________________
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/20120601/e5f10f2a/attachment-0001.html
More information about the FX.php_List
mailing list