Giter Club home page Giter Club logo

filemaker's Introduction

Connector to the relational database FileMaker for PHP 5.5 >=

The connector allows to communicate with the FileMaker tables through the REST API, realizing operations of obtaining, finding and updating data. Support scripts.

Before work you need to initialize a connector with your credentials:

    private static function initialize_fileMaker()
    {
        self::$file_maker_connector = new filemaker_connector();
        self::$file_maker_connector->set_credentials('login', 'pass');
        self::$file_maker_connector->set_entry_point('https://a111111.fmphost.com/fmi/data/v1/databases/test');
        self::$file_maker_connector->open_connection();

        if (self::$file_maker_connector == null || !self::$file_maker_connector->is_opened()) {
            die('Initialize FileMakerConnector before work with Test database.');
        }
    }

After that the connector is ready to work. Below are samples of obtaining data with a FileMaker script:

 $script = '&script=FindActiveForModifiedOnly&script.param=' . date("m-d-Y H:i:s", time());
 $indexer = self::$file_maker_connector->get_table_content('Inventory', $script);

And updating a record in the FileMaker database:

  $new_record = [];
  $new_record["pk"] = strval($employee_info["WOVEN_ID"]);

  $new_record["first"] = $employee_info["FNAME"];
  $new_record["last"] = $employee_info["LNAME"];
  $query_info = [
            "query" => [[
                "Employee" => '=' . $new_record["pk"]
            ]],
            "limit" => "1",
            "script" => "Employee DataAPIUpdate",
            "script.param" => json_encode($new_record)
        ];

  self::$file_maker_connector->update_record("Employees", $query_info);

filemaker's People

Contributors

kulikov-dev avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.