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.

PHP and relationships with separate files

Featured Replies

Hi,

I'm building an application that receives user-submitted data from a php form, then emails a receipt to the user and a report to an address outside the organization. The emails get sent by a script called from php on the form's submit page.

For one of the emails, some content and the recipient's address are stored in a related table in a separate file. Both the application doing the emailing and the separate file with the addresses are on Filemaker Server 11 and both are enabled for php via the guest account.

The problem is that any data, including the recipient address, that lives in the related file does not seem to show up when the script is called via php. It works fine when I run the script from the client. As a result, these emails won't go out because they have no address to go to.

It seems like maybe the relationship between the original file and the related file doesn't work in PHP. Does anyone have any experience with this sort of thing or any ideas?

Thanks!

Kelly

  • 4 months later...
  • Newbies

Hello,

I have the same problem, dose someone have a solution?

I have try a lot of ways, setting up an layout with the field from the extern database

but it won't work!

I hope someone can help us?

Thanks

Does the external file have a valid account and proper access privileges for the account name used by the PHP API?

  • Newbies

Yes, but I think there is a Problem:


$obj = new FileMaker($database, $hostname, $username, $password);



$script_object = $obj->newPerformScriptCommand($config->layout_order_item, "test", $pos["articleordernumber"]);

$script_result = $script_object->execute();



with new Filemaker() I will only get acces to the $database I choose, but not to the other "relation" database.

We must find a way to login into the other database without loosing the connection to the first, am I right?

  • Newbies

Ok, I have solve the problem.

I will try to describe it with my bad english :)

I have 3 Databases ...

What I have not observed is, that I have in Database 2 an relation to Database 3!

I have give Database 3 not the correct rights!

  • 2 weeks later...

Real question: Why would you use separate files these days? You can have an effectively unlimited number of tables in any given file anyway, so why confuse the issue?

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.