2017 © Pedro Peláez
 

library comiccms-export

A library for the export of ComicCMS user data

image

leijou/comiccms-export

A library for the export of ComicCMS user data

  • Monday, December 16, 2013
  • by leijou
  • Repository
  • 1 Watchers
  • 1 Stars
  • 11 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

ComicCMS Exporter

Classes to handle the export of ComicCMS data without the need to dive in to its source code., (*1)

Requirements

  • PHP 5.2
  • A ComicCMS install to point to

Quickstart

Note: This is a non-namespaced, single-file version of the code in this repo. The only external difference between the two versions is the conversion from namespace: Classes are called ComicCMSExport_* instead of \Leijou\ComicCMSExport\*, (*2)

Namespaced Requirements

If you're lucky enough to have PHP 5.3 on the target servers of your project you can instead choose to use the namespaced version: - PHP 5.3 - PSR-0 compliant autoloader or Composer: "leijou/comiccms-export": "1.*" - A ComicCMS install to point to, (*3)

The example contents script is also available for this namespaced version: contents_namespaced.php, (*4)

Usage

A ComicCMS object must be constructed and passed to the other classes. Once created it can be re-used for all iterators., (*5)

$comiccms = new \Leijou\ComicCMSExport\ComicCMS('/absolute/path/to/comiccms');

$comics = new \Leijou\ComicCMSExport\ComicIterator($comiccms);
foreach ($comics as $comic) {
    // ...
}

Item types available

Click for available property and method documentation: - Comic - News - User - UserGroup, (*6)

Each are constructed by its own Iterator: ComicIterator NewsIterator UserIterator UserGroupIterator, (*7)

Additionaly there are two iterators for queued/draft items: QueuedComicIterator QueuedNewsIterator, (*8)

Internals

On construction of an iterator the relevent storage file(s) are scanned and a list of IDs used (not deleted) are loaded. The full details can then be pulled one by one by looping over the iterator or using standard SeekableIterator methods., (*9)

Note: The seek method uses the offset of Item, not its ID. For such usage the method seekById is available., (*10)

Note: Generation of the the non-namespaced distributable version is done by build.php. It's just basic RegExp, not anything clever. So please be gentle & careful with it if you're aiming to edit and re-build this tool., (*11)

The Versions

16/12 2013

dev-master

9999999-dev https://github.com/leijou/ComicCMSExport

A library for the export of ComicCMS user data

  Sources   Download

MIT

comiccms

16/12 2013

1.0.0

1.0.0.0 https://github.com/leijou/ComicCMSExport

A library for the export of ComicCMS user data

  Sources   Download

MIT

comiccms