Mac+php+xdebug+phpstorm under Apple configuration Xdebug twists

Source: Internet
Author: User
<span id="Label3"></p><p><p>1. Download the Xdebug file</p></p><p><p>http://xdebug.org/wizard.php</p></p><p><p>Copy the source code for Phpinfo () to the text box, Xdebug will prompt you to configure and download which version of Xdebug.</p></p><p><p>All:</p></p><p><p>http://www.xdebug.org/download.php</p></p><pre><span style="color: #000000;"><span style="color: #000000;">instructionsdownload Xdebug</span></span>-<span style="color: #800080;"><span style="color: #800080;">2.3</span></span>.<span style="color: #800080;"><span style="color: #800080;">3</span></span><span style="color: #000000;"><span style="color: #000000;">. Tgzunpack the downloaded</span></span><span style="color: #0000ff;"><span style="color: #0000ff;">file</span></span>With<span style="color: #0000ff;"><span style="color: #0000ff;">Tar</span></span>-xvzf xdebug-<span style="color: #800080;"><span style="color: #800080;">2.3</span></span>.<span style="color: #800080;"><span style="color: #800080;">3</span></span><span style="color: #000000;"><span style="color: #000000;">. TGZRUN:CD Xdebug</span></span>-<span style="color: #800080;"><span style="color: #800080;">2.3</span></span>.<span style="color: #800080;"><span style="color: #800080;">3</span></span><span style="color: #000000;"><span style="color: #000000;">run:phpize (</span> see the FAQ</span><span style="color: #0000ff;"><span style="color: #0000ff;">if</span></span>You don<span style="color: #800000;"><span style="color: #800000;">'</span></span><span style="color: #800000;"><span style="color: #800000;">t have phpize.</span></span><span style="color: #000000;">As part of its <span style="color: #000000;">output it should show:configuring</span></span><span style="color: #0000ff;"><span style="color: #0000ff;"></span> for</span><span style="color: #000000;"><span style="color: #000000;">:... Zend Module Api No:</span></span><span style="color: #800080;"><span style="color: #800080;">20121212</span></span><span style="color: #000000;"><span style="color: #000000;">Zend Extension Api No:</span></span><span style="color: #800080;"><span style="color: #800080;">220121212</span></span><span style="color: #000000;"><span style="color: #000000;">If It does not, you are using the wrong phpize. Please follow this FAQ entry and skip the next Step. Run:.</span></span>/<span style="color: #000000;"><span style="color: #000000;">configurerun:</span></span><span style="color: #0000ff;"><span style="color: #0000ff;"></span> make</span><span style="color: #000000;"><span style="color: #000000;">Run:</span></span><span style="color: #0000ff;"><span style="color: #0000ff;">CP</span></span>modules/xdebug.so/usr/lib/php/extensions/no-debug-non-zts-<span style="color: #800080;"><span style="color: #800080;">20121212</span></span><span style="color: #000000;"><span style="color: #000000;">Edit</span></span>/etc/<span style="color: #000000;"><span style="color: #000000;">php.ini and add the Linezend_extension</span></span>=/usr/lib/php/extensions/no-debug-non-zts-<span style="color: #800080;"><span style="color: #800080;">20121212</span></span>/<span style="color: #000000;"><span style="color: #000000;">Xdebug.sorestart the webserver</span></span></pre><p><p>There are many installation tips on the Xdebug Website. Some of the issues that may arise are:</p></p><p><p>Phpize is not installed: then install brew again, then install autoconf can be described as twists</p></p><p><p>2. Solve the problem of the related components not complete</p></p><pre><pre><span style="font-size: 14px;">Problem description</span><br><span style="font-size: 14px;">When the Mac system is upgraded to 10.9 (mavericks), the PHP extension is installed and the phpize prompts for the following error:</span><br><br><span style="font-size: 14px;">Cannot find Autoconf. Please check your autoconf installation</span><br><span style="font-size: 14px;">and the $PHP _autoconf environment Variable.</span><br><span style="font-size: 14px;">Solutions</span><br><span style="font-size: 14px;">Install homebrew First:<br></span>If the following link is invalid, you can visit the brew Website. http://brew.sh/</pre></pre><pre><pre><code id="selectable">ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"</code></pre></pre><pre><pre><span style="font-size: 14px;">Then install Autoconf:</span><br><br><span style="font-size: 14px;">Brew Install autoconf</span></pre></pre><p><p>3. Configure php.ini</p></p><p><p>The configuration on the Xdebug network can only be configured correctly xdebug but not with phpstorm. Add the following code at the end of the Php.ini:</p></p><pre><pre><span style="color: #000000;">[xdebug]zend_extension</span>=<span style="color: #800000;">"/usr/lib/php/extensions/no-debug-non-zts-20121212/xdebug.so</span><span style="color: #800000;">" </span><span style="color: #000000;"></span><span style="color: #800000;"></span><span style="color: #800000;"></span><span style="color: #800000;"></span><span style="color: #800000;"></span><span style="color: #800000;"></span><span style="color: #800000;"></span> = "dbgp<span style="color: #000000;"></span>" " <span style="color: #000000;"></span> localhost" <span style="color: #000000;"></span> <span style="color: #800080;"></span>9000<span style="color: #000000;"></span>= Phpstrom</pre></pre><p><p>4. Configure Phpstorm</p></p><p><p>Open phpstorm,<br>-enter file>settings>php>servers, here to fill out the server side of the relevant information, name fill localhost,host fill localhost,port fill 80,debugger Choose Xdebug<br>-enter file>settings>php>debug, See xdebug tab, Port fill 9000, other default<br>-enter FILE>SETTINGS>PHP>DEBUG>DBGP proxy,ide Key to fill in the Phpstorm,host fill Localhost,port 80<br>-click OK to exit the Settings.</p></p><p><p>Open the monitor (phone Button) in the Phpstorm.</p></p><p><p>Xdebug Configuration for 5.chrome</p></p><p><p>Configure it as "phpstorm" in IDE key</p></p><p><p>Project Address: Https://github.com/mac-cain13/xdebug-helper-for-chrome</p></p><p><p>well, to this can be configured to complete, if there is a problem can give me a message, we communicate together.</p></p><p><p>6. Other:</p></p><p><p>Restart Apache</p></p><p><p>sudo apachectl restart</p></p><p><p>Modify PHP.ini Permissions</p></p><p><p>sudo chmod 0777 php.ini</p></p><p><p>Edit PHP.ini File</p></p><p><p>sudo vi php.ini (modify i, exit: q, Save Exit: Wq)</p></p><p><p>Mac+php+xdebug+phpstorm under Apple configuration Xdebug twists</p></p></span>

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.