Git Product home page Git Product logo

libflexport's Introduction

FINDOLOGIC export toolkit

Travis Latest Stable Version Code Coverage

Synopsis

This project provides a export library for XML and CSV generation according to the FINDOLOGIC export patterns.

####Export recommendation

Using the XML export is recommended by FINDOLOGIC. The XML is easier to read and has some advantages over the CSV export like:

  • No encoding issues as the encoding attribute is provided in the XML response <?xml version="1.0" encoding="UTF-8"?>
  • Validation is more reliable
  • Simple escaping of content using the <![CDATA[...]]>-tag
  • Standardized structure
  • Dynamically extract the products from the database via start and count parameter in the url
  • No limited file size for XML because of pagination
  • Using multiple usergroups per product

Basic usage

XML export

require_once './vendor/autoload.php';

use \FINDOLOGIC\Export\XML\XMLExporter;
use \FINDOLOGIC\Export\Data\Price;

$exporter = Exporter::create(Exporter::TYPE_XML);

$item = $exporter->createItem('123');

$price = new Price();
$price->setValue('13.37');
$item->setPrice($price);

$exporter->serializeItems(array($item), 0, 1);

Setup

  1. Include as composer dependency using composer require findologic/libflexport
  2. Load ./vendor/autoload.php into the project

Contributors

If you want to contribute to this project, feel free to fork the repository. Afterwards you can create a pull request following the steps mentioned at this Github help page.

Tests should be provided if possible.

Running php-cs-fixer before commiting will reduce style-caused build failures.

libflexport's People

Contributors

howard avatar mmachatschek avatar

Watchers

James Cloos 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.