2017 © Pedro Peláez
 

library v3application

V3ctor WareHouse Web Application

image

yorch/v3application

V3ctor WareHouse Web Application

  • Tuesday, August 9, 2016
  • by yorch
  • Repository
  • 2 Watchers
  • 0 Stars
  • 23 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

V3ctor WareHouse Web Application

Description

V3ctorWH is a Web Application REST API for V3 WareHouse Core., (*1)

Requirements

Installation

Clone Repository Execute php composer.phar install, (*2)

Create config.php, (*3)


$hostname = 'DB_HOST'; $username = 'DB_USER'; $password = 'DB_PASSWORD'; $dbname = 'DBNAME'; $port = 27017; $key = "KEY";

Examples


<?php require 'config.php'; require 'vendor/autoload.php'; // Init Database Connection //V3WareHouse::getInstance("v3Mongo", $hostname, $username, $password, $dbname, $port); // For PHP 7 V3WareHouse::getInstance("v3MongoDB", $hostname, $username, $password, $dbname, $port); // Init Application $app = new V3Application($dbname, $key); // Add Custom Route $app->addRoute('/openshift', function () { $app = \Slim\Slim::getInstance(); $app->response()->header('Content-Type', 'application/json'); $app->response()->status(200); $msg = array("msg" => "Hello localhost !!!"); $envvar = getenv('OPENSHIFT_MONGODB_DB_HOST'); if (! empty($envvar)) $msg = array("msg" => "Hello Openshift !!!"); echo json_encode($msg); }); // Start V3ctor Application $app->start(); ?>

References

https://en.wikipedia.org/wiki/Representational_state_transfer, (*4)

P.D. Let's go play !!!, (*5)

The Versions

09/08 2016

dev-master

9999999-dev https://github.com/yorch81/v3application

V3ctor WareHouse Web Application

  Sources   Download

Apache-2.0

The Requires

 

mongodb mysql warehouse