﻿{"id":840,"date":"2012-05-24T12:23:05","date_gmt":"2012-05-24T04:23:05","guid":{"rendered":"http:\/\/nick.workao.org\/?p=840"},"modified":"2012-05-24T12:23:05","modified_gmt":"2012-05-24T04:23:05","slug":"how-to-configure-eclipse-xdebug-firefox","status":"publish","type":"post","link":"https:\/\/nick.txtcc.com\/index.php\/linux\/840","title":{"rendered":"How to configure Eclipse + XDebug + Firefox"},"content":{"rendered":"<p><strong>This &#8220;howto&#8221; is based on the following model:<\/strong>\n-Ubuntu v 10.04\n-Eclipse v 3.5.2\n-Local LAMP server<\/p>\n<p><strong>Requirements:<\/strong>\n-LAMP already installed\n-Eclipse already installed<\/p>\n<p><strong>Server configuration:<\/strong>\n-Open a terminal\n-run: sudo apt-get install php5-xdebug\n-run: sudo nano \/etc\/php5\/conf.d\/xdebug.ini\n-Don&#8217;t delete the content of this file, just go to the end of the file add 2 blank lines and paste the next configuration:<\/p>\n<p>xdebug.remote_enable=On\nxdebug.remote_host=&#8221;localhost&#8221;\nxdebug.remote_port=9000\nxdebug.remote_handler=&#8221;dbgp&#8221;<\/p>\n<p>-save changes\n-run: sudo service apache2 restart<\/p>\n<p><strong>Eclipse configuration:<\/strong>\n-Open eclipse\n-On the eclipse main menu go to: Help&#8211;> Install New Software&#8230;\n-open the dropDownList &#8220;work with&#8221;\n-select &#8220;&#8211;All Available Sites&#8211;&#8221;\n-On the filter text field put: php\n-Check out: &#8220;Programming Languages&#8221;\n-Check out: &#8220;Web, XML, and Java EE Development&#8221;\n-Follow the wizard instruction until finish\n-On the eclipse main menu go to: Window&#8211;> Preferences\n-Navigate on the tree menu to: PHP&#8211;> Debug\n-open the dropDownList &#8220;work with&#8221;\n-On &#8220;PHP Debugger&#8221; select &#8220;XDebug&#8221;\n-Leave alone &#8220;Server&#8221; and &#8220;PHP Executables&#8221;\n-Save changes and close the window\n-On the eclipse main menu go to: Run&#8211;> Debug configurations&#8230;\n-Do a double click over &#8220;PHP Web Page&#8221; just to add a new setting\n-On the DropDowList &#8220;Server Debugger&#8221; select &#8220;XDebug&#8221;\n-On the file section browse and select the &#8220;index.php&#8221; of your project or whatever file you need to start your application\n-Uncheck &#8220;Break at Fist Line&#8221;\n-Apply changes and close the window\n-On the eclipse main menu go to: Window&#8211;> Web Browser&#8211;> Default System Web Browser<\/p>\n<p><strong>Testing xdebug<\/strong>\n-Open a project with source code that already is hosted in your LAMP server\n-Place a &#8220;break point&#8221; at some point of you script\n-Press &#8220;F11&#8221; to start the debugger\n-Your code should stop at the break point\n-Now move the mouse over variables so watch its values<\/p>\n<p>That is all i hope you enjoy this HowTo\u00a0<img decoding=\"async\" title=\"Wave\" src=\"http:\/\/ubuntuforums.org\/images\/smilies\/smiley-faces-80.gif\" alt=\"\" border=\"0\" \/><\/p>","protected":false},"excerpt":{"rendered":"<p>This &#8220;howto&#8221; is based on the following model: -Ubuntu v 10.04 -Eclipse v 3.5.2 -Local LA&#46;&#46;&#46;<\/p>","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4,15],"tags":[321,322,43,442],"class_list":["post-840","post","type-post","status-publish","format-standard","hentry","category-linux","category-php","tag-aptana","tag-debug","tag-eclipse","tag-php"],"_links":{"self":[{"href":"https:\/\/nick.txtcc.com\/index.php\/wp-json\/wp\/v2\/posts\/840","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/nick.txtcc.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/nick.txtcc.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/nick.txtcc.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/nick.txtcc.com\/index.php\/wp-json\/wp\/v2\/comments?post=840"}],"version-history":[{"count":1,"href":"https:\/\/nick.txtcc.com\/index.php\/wp-json\/wp\/v2\/posts\/840\/revisions"}],"predecessor-version":[{"id":841,"href":"https:\/\/nick.txtcc.com\/index.php\/wp-json\/wp\/v2\/posts\/840\/revisions\/841"}],"wp:attachment":[{"href":"https:\/\/nick.txtcc.com\/index.php\/wp-json\/wp\/v2\/media?parent=840"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/nick.txtcc.com\/index.php\/wp-json\/wp\/v2\/categories?post=840"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/nick.txtcc.com\/index.php\/wp-json\/wp\/v2\/tags?post=840"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}