Download the PHP package omatech/editora-extractor without Composer

On this page you can find all versions of the php package omatech/editora-extractor. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package editora-extractor

Editora-Extractor

Utilities for extracting info from omatech Editora using GraphQL or a simplified array structure

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Require in composer omatech/editora-extractor and you are get to go

Review the package omatech/editora-laravel-connector for easy Laravel integration

Prerequisites

You need a valid connection to an editora database using Doctrine/DBAL

Usage

Instance

Get the instance information with the needed relations.

For example fetch the inst_id=1 (Home) and get the relations called "carrousel", "news" and "people".

$params = [ 'id' => '1' , 'lang' => 'ca' , 'debug' => true , 'metadata' => true ];

$query='query FetchHomeQuery ($id:Int, $lang:String, $debug:Boolean) { instance(id: $id, lang: $lang, debug: $debug) { id nom_intern link publishing_begins status creation_date class_name class_tag class_id update_timestamp all_values_even_null (filter: "small") {atri_tag text_val}

relation1 (tag: "carrousel", limit:2, alias: "mycarrousel")
    {
      id tag direction limit
        instances {
            id nom_intern link publishing_begins status creation_date class_name class_tag class_id update_timestamp
            all_values_even_null (filter: "fields:title|subtitle_t") {atri_tag text_val}
        }
    }

relation2 (tag: "news", limit: 5)
    {
      id tag direction limit
        instances {
          id nom_intern link
            all_values_even_null (filter: "small") {atri_tag, text_val}
        }
    }

relation3 (tag: "people", limit:10)
    {
      id tag direction limit
        instances {
          id nom_intern link publishing_begins status creation_date
            all_values_even_null {atri_tag text_val}
        }
    }

} }';

$extractor=new Extractor($conn); $res=$extractor->extract($query, $params, 'array', false); // $res now contains an array with the tree of the content

Call to extractor

$res=$extractor->extract($query, $params, $format, $ferretizer);

$query: is the GraphQL query $params: array of valid params (see params array section) $format: ('array' | 'json') Output format. Default 'array' $ferretizer: (true | false) select if you want to simplify the result using the ferretizer post-processor, usually true. Default true

Params Array

The available params include:

id: inst_id lang: language of the extraction, two letter language code or ALL ('ALL' | 'ca' | 'es' |...) class_id: class you want to extract the instances from tag: tag of the class that you want to extract the instance from metadata: true if you want to extract extra metadata for each object, false otherwise, default false. preview: true if you want to extract pending objects, false otherwise, default false. debug: true if you want to get debug information on the extraction, false otherwise, default false. $extractor->debug_messages keeps the debug information

Installing

TBD

Contributing

TBD

Versioning

TBD

Authors

Agusti Pons Christian Bohollo Javier Mogollon

License

This project is licensed under the MIT License


All versions of editora-extractor with dependencies

PHP Build Version
Package Version
Requires doctrine/dbal Version ~2.5
webonyx/graphql-php Version 0.7.*
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package omatech/editora-extractor contains the following files

Loading the files please wait ....