Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 7487 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

I have problem getting anything out of the database, and I know that I am the one to blame...lol

The table have 10 fields, and only one row has data in it now (for testing puposes). One container-filed with a jpg, the solution on how to get the picture out of of the container will I have to bother you with later :-)

Here's a little snip of the script, would love any hints on how to get this working. I would like to print the contents of the array $ReturnedData to the screen.

$ProductQuery = new FX( $serverIP, $serverPort);

$ProductQuery->SetDBData('personligweb.fp5', 'www', 'All' );

$ReturnedData = $ProductQuery->FMFindAll();

foreach ($ReturnedData['data'] as $key=>$value) {

echo "Point 1 <br>";

foreach ($value as $key1 => $value1) {

$valuelistData[$key] .= "t<option value="$value1">$value1</option>n";

}

echo "<select name="$key">n";

echo $valuelistData[$key];

echo "</select>n";

echo "<br />n";

}

I get no error messages, just a blank page.

Thanks in advance.....

Posted

If you just want to print the contents of the array $ReturnedData, then all you need to do is use "print_r" as such:

$ProductQuery = new FX( $serverIP, $serverPort);

$ProductQuery->SetDBData('personligweb.fp5', 'www', 'All' );

$ReturnedData = $ProductQuery->FMFindAll();

print_r($ReturnedData);

That'll spit the raw array all over your screen. It's great for debugging. Now, if you are looking for formatted output.... that's a little different.

regards...

Bob Minteer

Dallas, TX

Posted

I did finally get something out of the database...SYSOP forgot to share the database with the webserver... :-)

The script I posted above didn't work, but I figured out a solution to that problem.

What in FX.php would do the following:

output the name-filed from the personligweb.fp5 where userId = 1??

Another question I have is how to get output from two related tables in a database. I have only used php and mySQL before....I am new with FX.php and FileMaker.

This topic is 7487 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.