Structure of Chamilo 1.10: a new awakening

1,355 views
1,117 views

Published on

Presentation made by Julio Montoya, Lead developer of Chamilo LMS in the Chamilo Users Day Madrid 2013.

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
1,355
On SlideShare
0
From Embeds
0
Number of Embeds
6
Actions
Shares
0
Downloads
20
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Structure of Chamilo 1.10: a new awakening

  1. 1. LMS 1.10
  2. 2. Julio Montoya @jmontoya Chamilo LMS Lead developer
  3. 3. MS L Under the hood
  4. 4. github ● https://github.com/chamilo/chamilo-lms
  5. 5. Problems ● No common PHP standards between libraries. ● mysql_* functions deprecated in PHP 5.5 ● Lots of require_once. ● Not a clear MVC pattern. ● We need a real Database Layer. ● No library dependency manager. ● … ● Legacy project ….
  6. 6. PHP-FIG ● Drupal, phpBB, PEAR, Symfony2, etc. ● Standards – PSR-0 (Autoloading standard) – PSR-1 (Basic coding standard) – PSR-2 (Coding style guide)
  7. 7. Dependency Manager
  8. 8. composer.json
  9. 9. ● cd /var/www/chamilo-lms ● composer install profit
  10. 10. Silex http://silex.sensiolabs.org ● PHP micro framework. ● Based in Symfony2 components. ● Very extensible. ● Very modular. ● Big responsibility.
  11. 11. Silex ● Define a controller and map to a route: require_once __DIR__.'/../vendor/autoload.php'; $app = new SilexApplication(); $app->get('/blog/{id}', function ($id) { return 'blog item'.$id; }); $app->get('/userportal', 'userPortal.controller:indexAction'); $app->get('/main/admin', function ($id) { return 'Legacy code here'; }); $app->run();
  12. 12. In a Nutshell Doctrine2 Silex Twig Session Security ...
  13. 13. Silex ● MVC pattern – Doctrine2 (Database entities) – Twig (Templates) – Controllers (inspired by Symfony2)
  14. 14. New routes ● Old ● http://campus.chamilo.org/user_portal.php ● New ● http://campus.chamilo.org/web/userportal ● http://campus.chamilo.org/web/julio/userportal ● http://campus.chamilo.org/web/home/userportal
  15. 15. New components ● Silex – Doctrine2 – Twig – Translation – Session – Security – Chash
  16. 16. Chash ● Chamilo Shell = Chash ● https://github.com/chamilo/chash ● php chash.php chamilo:install 1.9.6 ● php chash.php chamilo:update 1.10.0 ● php chash.php files:clean_temp_folders ● etc
  17. 17. New directory structure ● chamilo – config (Chamilo settings) ● – config/configuration.php data (Portal files) ● ● ● ● data/courses data/home data/temp data/upload – vendor (Libraries) – web (Public content)
  18. 18. Database ● Migrating MyISAM to InnoDB (in progress) ● Doctrine migrations (1.11)
  19. 19. Chamilo 1.10 ● Demo platform: ● http://unstable.chamilo.org/

×