Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
web:eclipse [2024/05/20 13:44] – [Installation] Bernard Condrauweb:eclipse [2024/10/31 14:32] (current) – [Settings] Bernard Condrau
Line 14: Line 14:
 ===== LAMP with Xdebug ===== ===== LAMP with Xdebug =====
   * Follow [[deb12:lamp|LAMP on Debian 12]]   * Follow [[deb12:lamp|LAMP on Debian 12]]
- 
- 
-==== Apache ==== 
- 
-Modify x:\xampp\apache\conf\httpd.conf. The best way to integrate with eclipse is to point the DocumentRoot to your project directory: 
-  DocumentRoot "x:/joomla/htdocs" 
-  <Directory "x:/joomla/htdocs"> 
-    Options Indexes FollowSymLinks Includes ExecCGI 
-    AllowOverride All 
-    Require all granted 
-  </Directory> 
-Alternatively, you can keep the default DocumentRoot and add an alias to your project directory: 
-  <Directory "x:/joomla/htdocs"> 
-    Options Indexes FollowSymLinks Includes ExecCGI 
-    AllowOverride All 
-    Require all granted 
-  </Directory> 
-  <IfModule alias_module> 
-    ScriptAlias /cgi-bin/ "x:/xampp/cgi-bin/" 
-    Alias /joomla "x:/joomla/htdocs/" 
-  </IfModule> 
- 
-To enable SSL, you need to set the DocumentRoot in C:\xampp\apache\conf\extra\httpd-ssl.conf<code>DocumentRoot "x:/joomla/htdocs"</code> 
- 
-==== PHP ==== 
-==== php.ini ==== 
-Review your php.ini:<code>output_buffering=off 
-short_open_tag = On 
-max_execution_time=120 
-max_input_time=150 
-max_input_vars = 2000 
-memory_limit = 512M 
-error_reporting=E_ALL & ~E_DEPRECATED & ~E_STRICT 
-display_errors=On 
-post_max_size = 32M 
-sys_temp_dir = "/tmp" 
-upload_tmp_dir = "/tmp" 
-upload_max_filesize=128M 
-date.timezone=Asia/Bangkok</code> 
  
 ===== Eclipse IDE ===== ===== Eclipse IDE =====
Line 67: Line 28:
   * [[https://wiki.eclipse.org/FAQ_How_do_I_increase_the_heap_size_available_to_Eclipse%3F|How do I increase the heap size available to Eclipse?]]   * [[https://wiki.eclipse.org/FAQ_How_do_I_increase_the_heap_size_available_to_Eclipse%3F|How do I increase the heap size available to Eclipse?]]
  
-==== XDebug for PHP 7.2 ==== 
-To activate the debugger, you need to add the following lines to the bottom of x:/xampp/php/php.ini:<code> 
-[XDebug] 
-zend_extension = "C:\xampp\php\ext\php_xdebug-2.6.1-7.2-vc15.dll" ; IMPORTANT: Windows does not find the dll if the drive letter is missing! 
-xdebug.remote_autostart = 1 
-xdebug.profiler_append = 0 
-xdebug.profiler_enable = 0 
-xdebug.profiler_enable_trigger = 0 
-xdebug.profiler_output_dir = "\xampp\tmp" 
-;xdebug.profiler_output_name = "cachegrind.out.%t-%s" 
-xdebug.remote_enable = 1 
-xdebug.remote_handler = "dbgp" 
-xdebug.remote_host = "127.0.0.1" 
-xdebug.remote_log = "\xampp\tmp\xdebug.txt" 
-xdebug.remote_port = 9000 
-xdebug.trace_output_dir = "\xampp\tmp" 
-xdebug.remote_cookie_expire_time = 36000</code> 
-  * Other options can be left at default values. Check the settings have been recognized by checking phpinfo. 
-  * XAMPP does not contain the correct php_xdebug.dll, download it from  [[https://gist.github.com/odan/1abe76d373a9cbb15bed|here]] and put it into folder x:/xampp/php/ext. 
-  * Make sure you have Visual C++ 2017 installed. 
  
-  * Download and install: [[https://gist.github.com/odan/1abe76d373a9cbb15bed|Installing Xdebug for XAMPP with PHP 7.x]] and [[https://support.microsoft.com/en-us/help/2977003/the-latest-supported-visual-c-downloads|The latest supported Visual C++ downloads]] 
-  * Check phpinfo: [[https://xdebug.org/wizard.php|Tailored Installation Instructions]] 
- 
-==== XDebug for PHP 5.6 ==== 
-To activate the debugger, you need to add the following lines to the bottom of x:/xampp/php/php.ini: 
-  [Xdebug] 
-  zend_extension=H:\xampp\php\ext\php_xdebug.dll 
-  xdebug.remote_enable = 1 
-  xdebug.remote_port = 9000 
-  xdebug.trace_output_dir = "\xampp\tmp" 
-Other options can be left at default values. Check the settings have been recognized by checking phpinfo. xampp comes with the correct php_xdebug.dll file already located in x:/xampp/php/ext. 
- 
-=== Links === 
-  * [[https://wiki.eclipse.org/Debugging_using_XDebug|Debugging using XDebug]] 
-  * [[http://www.eclipse.org/pdt/documents/XDebugGuideForPDT2.0.pdf|XDebug Guide]] 
-  * [[https://xdebug.org/docs/remote|XDEBUG EXTENSION FOR PHP - DOCUMENTATION]] 
-  * [[https://xdebug.org/wizard.php|Xdebug Support: Tailored Installation Instructions]] 
  
 ==== JavaScript ==== ==== JavaScript ====
Line 134: Line 58:
   - Add or Edit **Debug Configurations...**. If you pointed the DocumentRoot to your workspace, then you can leave the URL on "Auto Generate", otherwise you must modify the URL.{{ :web:debug.jpg?100 |Debug Configuration}}   - Add or Edit **Debug Configurations...**. If you pointed the DocumentRoot to your workspace, then you can leave the URL on "Auto Generate", otherwise you must modify the URL.{{ :web:debug.jpg?100 |Debug Configuration}}
   - **Window --> Preferences --> PHP --> Code Style --> Formatter**. Select "PHP Conventions" as active profile.{{ :web:phpconvention.jpg?100 |PHP Formatter}}   - **Window --> Preferences --> PHP --> Code Style --> Formatter**. Select "PHP Conventions" as active profile.{{ :web:phpconvention.jpg?100 |PHP Formatter}}
 +  - **Window --> Preferences --> General --> Editors --> Text Editors**. Uncheck "Use find/replace overlay" (see [[https://stackoverflow.com/questions/79012836/eclipse-2024-09-is-there-a-way-to-get-the-old-find-replace-window-back|Eclipse 2024-09 Is there a way to get the old Find/Replace window back?]])
   - If you have existing projects   - If you have existing projects
     * either select the project directory as workspace when first starting up the new eclipse, or     * either select the project directory as workspace when first starting up the new eclipse, or