Yannick Warnier d1b37f34fe Minor - Add license refs + change dirname(__FILE__) to __DIR__ (about 4 times faster). See http://stackoverflow.com/questions/2749416/is-there-any-difference-between-dir-and-dirname-file-in-php пре 7 година
..
xhprof_html d1b37f34fe Minor - Add license refs + change dirname(__FILE__) to __DIR__ (about 4 times faster). See http://stackoverflow.com/questions/2749416/is-there-any-difference-between-dir-and-dirname-file-in-php пре 7 година
xhprof_lib d1b37f34fe Minor - Add license refs + change dirname(__FILE__) to __DIR__ (about 4 times faster). See http://stackoverflow.com/questions/2749416/is-there-any-difference-between-dir-and-dirname-file-in-php пре 7 година
README.md d943b6522b Update xhprof profiler rules with fork of xhprof пре 8 година
footer.php 0c3fedf2af Add get_memory_peak_usage() info to profile link пре 7 година
header.php d1b37f34fe Minor - Add license refs + change dirname(__FILE__) to __DIR__ (about 4 times faster). See http://stackoverflow.com/questions/2749416/is-there-any-difference-between-dir-and-dirname-file-in-php пре 7 година

README.md

XHProf / Tideways

Previously the XHProf library was developed by Facebook. Since they moved to HHVM, they have dropped support for the library and several projects have forked it, between other reasons to provide support for PHP 7.

Install procedure

To enable the profiler into Chamilo, you will need to do the following:

  • install the tideways-php library from https://tideways.io/profiler/downloads
  • add the following two lines to your Apache VirtualHost or (in a slightly different form) to your php.ini config (don't forget to update the path to your Chamilo root directory): php_value auto_prepend_file /var/www/chamilo/tests/xhprof/header.php php_value auto_append_file /var/www/chamilo/tests/xhprof/footer.php
  • restart your PHP interpreter (Apache or PHP-FPM, in most cases)
  • modify Chamilo's .htaccess file to comment (temporarily) the tests/ directory line, like so

    # Deny access
    #RewriteRule ^(tests|.git) - [F,L,NC]
    

Using XHProf

Once you've done all the above, reload any Chamilo page. You should now see a little link at the bottom left of the page (under the footer). Click the link to see the details of the page load as seen by the profiler.