Difference between revisions of "Slib"

From ProgClub
Jump to: navigation, search
(→‎Source code: Updating links)
(→‎Functional specification: Adding functional spec notes...)
Line 37: Line 37:
 
== Functional specification ==
 
== Functional specification ==
  
The software provides a web-framework for PHP applications.
+
The software provides a web-framework/toolkit for PHP applications.
 +
 
 +
* url management (SlibUri)
 +
** url()
 +
* database interface, Database inherits SlibDatabase (sorting/pagination/filtering support)
 +
** db()
 +
** DataSort
 +
** DataPage
 +
** DataQuery
 +
** DatabaseSchema inherits SlibDatabaseSchema
 +
* database upgrade DatabaseUpgrade inherits SlibDatabaseUpgrade
 +
** dbu()
 +
* settings management (session, user, global)
 +
** sm()->settings
 +
** SettingsManager inherits SlibSettingsManager
 +
** Setting inherits SlibSetting
 +
** GlobalSettings, UserSettings, SessionSettings inherits SlibSettings
 +
* session management (login, settings/state)
 +
** sm()
 +
** SessionManager inherits SlibSessionManager
 +
* auth management
 +
** auth()->can_edit_post( $sm )
 +
* user/group management (auth, permissions)
 +
** sm()->user and user->groups
 +
** User inherits SlibUser
 +
** Group inherits SlibGroup
 +
* resource management (graphics, style, scripts, caching)
 +
** rm()
 +
* graphics management (database, scale, cache)
 +
** gm()
 +
* file management (database, upload, cache)
 +
** fm()
 +
* form management (validation, submission(POST)/query(GET))
 +
** form()
 +
** Submission inherits SlibSubmission
 +
** Query inherits SlibQuery
 +
** Validator inherits SlibValidator
 +
* content management (news, book, page)
 +
** cm()
 +
** Article (News) inherits SlibArticle (date, title, description, html)
 +
** Book inherits SlibBook
 +
** Chapter inherits SlibChapter
 +
** Page inherits SlibPage
 +
* translation facilities for content and services
 +
** tm()
 +
* access logging (all HTTP activity)
 +
** log()
 +
* error logging (write failed logins to error log, pick up with fail2ban)
 +
** log()->error()
 +
* request management (HTTP input/output)
 +
** req()
 +
** redirection support: req()->goto( $url )
 +
** cookie support: req()->cookie( $name, $etc )
 +
** HTTP headers support: req()->header( ... )
 +
* Category (for content, graphics, files)
 +
* Tag (for content, graphics, files)
 +
* Feed provider
 +
** feed()
  
 
== Technical specification ==
 
== Technical specification ==

Revision as of 20:11, 24 April 2014

Slib is the ProgClub PHP framework software. That's the software that provides a framework for your PHP applications. For other projects see projects.

Project status

Under way. Not released yet, there's stuff TODO.

Contributors

Members who have contributed to this project. Newest on top.

All contributors have agreed to the terms of the Contributor License Agreement. This excludes any upstream contributors who tend to have different administrative frameworks.

Copyright

Copyright 2011, Contributors. Licensed under the GPL.

Source code

The repository can be browsed online:

https://www.progclub.org/pcrepo/slib/trunk

The code for slib is publicly available from svn:

https://www.progclub.org/svn/pcrepo/slib/tags/latest

Or privately available for read-write access:

https://www.progclub.org/svn/pcrepo/slib/trunk

Links

No links at this time.

Functional specification

The software provides a web-framework/toolkit for PHP applications.

  • url management (SlibUri)
    • url()
  • database interface, Database inherits SlibDatabase (sorting/pagination/filtering support)
    • db()
    • DataSort
    • DataPage
    • DataQuery
    • DatabaseSchema inherits SlibDatabaseSchema
  • database upgrade DatabaseUpgrade inherits SlibDatabaseUpgrade
    • dbu()
  • settings management (session, user, global)
    • sm()->settings
    • SettingsManager inherits SlibSettingsManager
    • Setting inherits SlibSetting
    • GlobalSettings, UserSettings, SessionSettings inherits SlibSettings
  • session management (login, settings/state)
    • sm()
    • SessionManager inherits SlibSessionManager
  • auth management
    • auth()->can_edit_post( $sm )
  • user/group management (auth, permissions)
    • sm()->user and user->groups
    • User inherits SlibUser
    • Group inherits SlibGroup
  • resource management (graphics, style, scripts, caching)
    • rm()
  • graphics management (database, scale, cache)
    • gm()
  • file management (database, upload, cache)
    • fm()
  • form management (validation, submission(POST)/query(GET))
    • form()
    • Submission inherits SlibSubmission
    • Query inherits SlibQuery
    • Validator inherits SlibValidator
  • content management (news, book, page)
    • cm()
    • Article (News) inherits SlibArticle (date, title, description, html)
    • Book inherits SlibBook
    • Chapter inherits SlibChapter
    • Page inherits SlibPage
  • translation facilities for content and services
    • tm()
  • access logging (all HTTP activity)
    • log()
  • error logging (write failed logins to error log, pick up with fail2ban)
    • log()->error()
  • request management (HTTP input/output)
    • req()
    • redirection support: req()->goto( $url )
    • cookie support: req()->cookie( $name, $etc )
    • HTTP headers support: req()->header( ... )
  • Category (for content, graphics, files)
  • Tag (for content, graphics, files)
  • Feed provider
    • feed()

Technical specification

TODO.

TODO

Things to do, in rough order of priority:

  • Create the project in svn
  • Document functional specification
  • Document technical specification
  • Copy in existing code

Done

Stuff that's done. Latest stuff on top.

  • JE 2011-12-08: created project page

Notes for implementers

If you are interested in incorporating ProgClub slib into your project, here's what you need to know:

You probably want to setup an svn:externals from your svn repository to the public release tag:

http://www.progclub.org/svnro/pcrepo/slib/tags/latest

That way you'll get changes to the framework as they're released.