Environment and development tools - Optional: Difference between revisions

Jump to navigation Jump to search
m
no edit summary
m (→‎Instal PHPUnit: -> Install & Update URLs)
mNo edit summary
Tag: 2017 source edit
Line 40: Line 40:


For Apache, just add the following line into your apache.conf:
For Apache, just add the following line into your apache.conf:
<source lang="ini">
<syntaxhighlight lang="ini">
SetEnv MAIN_SHOW_TUNING_INFO 1
SetEnv MAIN_SHOW_TUNING_INFO 1
</source>
</source>
For Nginx, add the following line to your php location:
For Nginx, add the following line to your php location:
<source lang="ini">
<syntaxhighlight lang="ini">
fastcgi_param MAIN_SHOW_TUNING_INFO true;
fastcgi_param MAIN_SHOW_TUNING_INFO true;
</source>
</source>
Line 57: Line 57:
*Modify php.ini file to add parameters:
*Modify php.ini file to add parameters:


<source lang="ini">
<syntaxhighlight lang="ini">
  [xdebug]
  [xdebug]
  xdebug.remote_enable=on
  xdebug.remote_enable=on
Line 68: Line 68:
  xdebug.profiler_enable=0
  xdebug.profiler_enable=0
  xdebug.profiler_enable_trigger=1
  xdebug.profiler_enable_trigger=1
</source>
</syntaxhighlight>


===[[File:Logo_ubuntu.png|24px]] In Ubuntu / Linux===
===[[File:Logo_ubuntu.png|24px]] In Ubuntu / Linux===
Line 74: Line 74:
*Install package '''php-xdebug''':
*Install package '''php-xdebug''':


<source lang="bash">
<syntaxhighlight lang="bash">
sudo apt-get install php-xdebug
sudo apt-get install php-xdebug
</source>
</syntaxhighlight>


*Modify xdebug.ini to add parameters after the line zend_extension=xxx (or similar):
*Modify xdebug.ini to add parameters after the line zend_extension=xxx (or similar):


<source lang="ini">
<syntaxhighlight lang="ini">
  ; With xdebug 2.1 and more
  ; With xdebug 2.1 and more
  xdebug.remote_enable=on
  xdebug.remote_enable=on
Line 95: Line 95:
  xdebug.auto_trace=0
  xdebug.auto_trace=0
  xdebug.trace_enable_trigger=1
  xdebug.trace_enable_trigger=1
</source>
</syntaxhighlight>


===[[File:Eclipsephp.jpg|24px]] Eclipse configuration===
===[[File:Eclipsephp.jpg|24px]] Eclipse configuration===
Line 146: Line 146:
*Take a look at tools documentation (PHPCodeSniffer, PHPPcd, PHPDepends). For example, to install or upgrade PHPCodeSniffer
*Take a look at tools documentation (PHPCodeSniffer, PHPPcd, PHPDepends). For example, to install or upgrade PHPCodeSniffer


<source lang="bash">
<syntaxhighlight lang="bash">
sudo pear upgrade PHP_CodeSniffer
sudo pear upgrade PHP_CodeSniffer
</source>
</syntaxhighlight>
And check into PHPCodeSniffer setup, that you use the PEAR libraries store into */usr/bin/php*
And check into PHPCodeSniffer setup, that you use the PEAR libraries store into */usr/bin/php*


Navigation menu