Wordpress plugin for the dhtmlxScheduler
PHP JavaScript
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
codebase initial version Dec 19, 2012
mce_scheduler initial version Dec 19, 2012
SchedulerHelper.php initial version Dec 19, 2012
admin.php initial version Dec 19, 2012
default.xml initial version Dec 19, 2012
groups.php initial version Dec 19, 2012
readme.txt initial version Dec 19, 2012
scheduler_include.html initial version Dec 19, 2012
settings_export.php initial version Dec 19, 2012
wpmu_options.php initial version Dec 19, 2012


dhtmlxScheduler Wordpress plugin

##Component structure

  • codebase/ - scheduler codebase
  • mce_scheduler/ - mce button to add event in wordpress post/page editor
  • admin.php - initializing admin panel
  • scheduler.php - plugin code
  • scheduler_include.html - additional html/js/css code which is included at page before scheduler.init()

All scheduler logic is located in codebase.
It includes scheduler codebase, scheduler configurator, code generator. There are 3 main points in code:

  • initializing admin panel:
    • wordpress/admin.php
  • generating scheduler code:
    • wordpress/scheduler.php (function scheduler_init())
  • processing loading/saving requests:
    • codebase/dhtmlxSchedulerConfiguratorLoad.php

##Database structure

  • events_rec - stores scheduler events
    • event_id - event id
    • start_date - event start date/time
    • end_date - event end date/time
    • text - event text
    • rec_type - event recurring logic
    • event_pid - parent event (for editing one event from recurring series)
    • event_length - event length (required for recurring events)
    • user - event creator/editor id
    • lat - event latitude (for map view)
    • lng - event longuitude (for map view)
  • scheduler options are located in wordpress options table.
    Here is a list of options:
    • scheduler_xml - scheduler xml configuration. Is used to load settings in admin panel
    • scheduler_php - parsed xml configuration and serialized into more useful form
    • scheduler_php_version - version of the last php configuration
    • scheduler_xml_version - version of the last xml configuration
    • scheduler_stable_config - last stable configuration (is used for restoring scheduler configuration after config xml error)

##Codebase details Core provides universal control panel, API for generating scheduler and events data-feed.
Logic of parsing settings may be found in codebase/dhtmlxSchedulerConfigurator.php.

For saving/parsing configuration is used the follow logic:
when user saves configuration it is saved into database.
At the same time scheduler_xml_version (have a look database structure) is increased.
When user opens scheduler then configurators compare scheduler_xml_version and scheduler_php_version.
If scheduler_xml_version if bigger than scheduler_php_version then it parses xml configuration and serialize it into php (scheduler_php in database).
At the same time configurator updates scheduler_php_version to actual.
If scheduler_xml_version equals scheduler_php_version than xml is already parsed and serialized php configuration may be used.

Read more about dhtmlxScheduler Joomla! component in documentation.