• Home
  • Services
    • Business Consulting
    • Solution Development
    • Implementation
    • Ongoing Support
    • About FileMaker
  • Products
    • Colibri Studio
      • QuickBooks® Integration
      • Screenshots
      • System Requirements
    • Ad Sales 4
      • Screenshots
      • System Requirements
  • Clients & Solutions
    • Solution Summaries
  • About Us
  • News

One Approach to using FileMaker, PHP and Smart Pill

jamesPosted in: All Things FileMaker on August 19, 2008 at 3:36 pm

When addressing integration challenges with FileMaker, we try to solve them using the SmartPill plug-in (www.scodigo.com), especially when we have already used it for other purposes within a given solution. I’d like to share a technique we use for managing PHP in SmartPill that we have found to be very helpful and powerful.

In order for FileMaker to execute PHP, the PHP has to exist somewhere. It can be hard-coded into a script or stored in a field or a variable — there are a variety of approaches. Within SmartPill are several FileMaker-centric functions that will help you take full advantage of its functionality. Perhaps most important of these is the function “fm_evaluate,” which allows a user to pass data from FileMaker’s calculation engine into a piece of PHP code.

The fm_evaluate function in action

The Colibri team has created a library of the PHP functions we typically use in a given solution. Normally, we have a record in a FileMaker table that has a text field containing the PHP code for a specific function. The variables declared at the head of the function contain the necessary fm_evaluate calls. Each record has a unique serial number and a global field that can be used as a self-join. We develop a script that feeds the specific value correlating to a specific PHP call so that the PHP code is available on a global basis to the solution and driven from the context in which it is invoked. Consequently, our library becomes a solution-specific subset of PHP.

We have used this functionality to:

  • manage a digital archive;
  • manipulate directories on local machines;
  • use Web services via SOAP for credit card transactions; and
  • create SQL queries on SQL databases that do not require ODBC connections.

SmartPill also has a PHP extension for FileMaker that allows you to do SQL queries directly against FileMaker, create global variables outside of FileMaker’s field structure, and launch scripts, as well as error trap.

Execute SQL within PHP

We want to hear about your experiences using FileMaker, PHP and SmartPill. Please contact us or add any techniques, questions or comments to this blog.

J Sciarra
Chief Technologist

One Response to “One Approach to using FileMaker, PHP and Smart Pill”

  1. Recent Links Tagged With "filemaker" - JabberTags

    [...] public links >> filemaker One Approach to using FileMaker, PHP and Smart Pill Saved by raymondiwi on Sat 04-10-2008 My Free Mac Student Software Arsenal Saved by bentoi on Wed [...]

    October 5th, 2008 | 12:35 pm

Leave a Reply

  • Thinking about improving your business technology?

    Contact us to see how Colibri Solutions can help you achieve your business goals.

  • Categories

    • All Things FileMaker (2)
    • Company News (2)
  • RSS RSS Feed

    • One Approach to using FileMaker, PHP and Smart Pill
    • Using PHP as an Integration Tool for FileMaker Pro
    • New Website Design for 2008
    • Colibri Solutions Gets Certified for FileMaker Pro 9
Copyright and TM Colibri Solutions 2008. All rights reserved.