Home > WdCore

WdCore

WdCore is a project mainly written in PHP and JAVASCRIPT, based on the View license.

A high-performance object-oriented framework for PHP5.2

WdCore

WdCore is a high-performance object-oriented framework for PHP 5.2 and above. It is written with speed, flexibility and lightness in mind. WdCore doesn't try to be an all-in-one do-it-all solution, prefering to provided a tiny but strong set of classes and logics as a solid ground to build web applications.

WdCore offers the following features: Models and activerecords, Internationalization, Modules, a RESTful API, runtime Mixins, Autoload, Operations, Events, Hooks, Sessions, Routes, Caching, Image resizing.

Together with WdElements and WdPatron, WdCore is the base framework for the Publishr CMS, you might want to check these projects too.

Requirements

The minimum requirement for the WdCore framework is PHP5.2 except PHP5.2.12-13 (bug #49521, #50875). WdCore has been tested with Apache HTTP server on Linux, MacOS and Windows operating systems. The Apache server must support URL rewriting.

Installation

The WdCore framework can be retrieved from the GitHub repository at the following URL:

[email protected]:Weirdog/WdCore.git

The WdCore framework doesn't need to be web-accessible, thus a single instance can be used for multiple projects.

Configuring

Low-level components of the framework are configured using multiple configuration files, usually one per component. The default configuration files are available in the /config/ folder. To override the configuration or part of it, you can provide the path or pathes to your configuration files.

For example, you want to define the primary database connection:

  1. Edit your core configuration file e.g. /protected/all/config/core.php with the following lines:

    return array ( 'connections' => array ( 'primary' => array ( 'dsn' => 'mysql:dbname=;host=', 'username' => '', 'password' => '' ) ) );

  2. Then specify your config path while creating the core object:

    $core = new WdCore ( array ( 'pathes' => array ( 'config' => array('/protected/all/') ) ) );

What's next

The project website is under construction, but some examples are available on my blog [fr].

Inspiration

MooTools, Ruby on Rails, Yii

Previous:blitzed-atheme