>  기사  >  개발 도구  >  중단점 디버깅을 배우는 데 도움이 되는 문서

중단점 디버깅을 배우는 데 도움이 되는 문서

咔咔
咔咔원래의
2020-07-01 10:20:374207검색

개발 과정에서 알 수 없는 오류가 발생할 수 있습니다. 조금씩 디버깅하지 않도록 지정하세요. 이 글은 Atom을 사용하여 프로그램을 디버깅하는 데 도움이 될 것입니다. 궁금한 점이 있으면 답장을 보내주세요.

1. 아톰에 php-debug를 설치하세요

파일->설정중단점 디버깅을 배우는 데 도움이 되는 문서을 클릭하세요. 그런 다음 설치를 클릭하고 여기에 검색되지 않으면 php-debug를 검색하세요. 일어나, 방법을 찾아야 해! 우리는 과학적으로 인터넷 서핑을 배워야 합니다! 중단점 디버깅을 배우는 데 도움이 되는 문서성공적인 설치는 이렇습니다중단점 디버깅을 배우는 데 도움이 되는 문서

2. Xdebug 다운로드

다운로드 주소: https://xdebug.org/download, 주소를 열면 확장 프로그램을 볼 수 있습니다. 여기에 설치된 Kaka는 php7.3 여기에 이미지 설명 삽입하지만 선택할 수 있는 php7.3이 두 개 있습니다! PHP 환경을 열면 상자에서 vc15를 볼 수 있습니다여기에 그림 설명 삽입그런 다음 다운로드한 파일을 D:phpstudy_proExtensionsphpphp7.3.4ntsext 카카 주소입니다. 자신의 PHP 환경에 넣기만 하면 됩니다. 여기에 이미지 설명 삽입https://xdebug.org/download,打开地址后可以看到扩展,咔咔这里安装的是php7.3的중단점 디버깅을 배우는 데 도움이 되는 문서但是有俩个php7.3选择那个呢!打开你的PHP环境可以看到框里的vc15중단점 디버깅을 배우는 데 도움이 되는 문서然后把下载的文件放到D:phpstudy_proExtensionsphpphp7.3.4ntsext,这里是咔咔的地址。就是放到你们自己的PHP环境里边即可。중단점 디버깅을 배우는 데 도움이 되는 문서

三、配置

然后找到你的php.ini文件,将下面的配置复制进去。记得需要修改zend_extension

중단점 디버깅을 배우는 데 도움이 되는 문서

3.Configuration🎜🎜🎜🎜🎜그런 다음 php.ini 파일을 찾아 다음 구성을 변경하세요. 안에. 위치. 🎜🎜이 위치는 PHP 위치와 관련되어 있습니다. 🎜🎜<pre class="custom" data-tool="mdnice编辑器" style="margin-top: 10px; margin-bottom: 10px; border-radius: 5px; box-shadow: rgba(0, 0, 0, 0.55) 0px 2px 10px;">&lt;span style=&quot;display: block; background: url(https://imgkr.cn-bj.ufileos.com/97e4eed2-a992-4976-acf0-ccb6fb34d308.png); height: 30px; width: 100%; background-size: 40px; background-repeat: no-repeat; background-color: #282c34; margin-bottom: -7px; border-radius: 5px; background-position: 10px 10px;&quot;&gt;&lt;/span&gt;&lt;code class=&quot;hljs&quot; style=&quot;overflow-x: auto; padding: 16px; color: #abb2bf; display: -webkit-box; font-family: Operator Mono, Consolas, Monaco, Menlo, monospace; font-size: 12px; -webkit-overflow-scrolling: touch; letter-spacing: 0px; padding-top: 15px; background: #282c34; border-radius: 5px;&quot;&gt;[Xdebug]&lt;br/&gt;zend_extension = D:\phpstudy_pro\Extensions\php\php7&lt;span class=&quot;hljs-number&quot; style=&quot;color: #d19a66; line-height: 26px;&quot;&gt;.3&lt;/span&gt;&lt;span class=&quot;hljs-number&quot; style=&quot;color: #d19a66; line-height: 26px;&quot;&gt;.4&lt;/span&gt;nts\ext\php_xdebug&lt;span class=&quot;hljs-number&quot; style=&quot;color: #d19a66; line-height: 26px;&quot;&gt;-2.9&lt;/span&gt;&lt;span class=&quot;hljs-number&quot; style=&quot;color: #d19a66; line-height: 26px;&quot;&gt;.6&lt;/span&gt;&lt;span class=&quot;hljs-number&quot; style=&quot;color: #d19a66; line-height: 26px;&quot;&gt;-7.3&lt;/span&gt;-vc15-nts-x86_64.dll&lt;br/&gt;xdebug.remote_enable = On&lt;br/&gt;xdebug.remote_host = localhost&lt;br/&gt;xdebug.remote_port = &lt;span class=&quot;hljs-number&quot; style=&quot;color: #d19a66; line-height: 26px;&quot;&gt;9000&lt;/span&gt;&lt;br/&gt;xdebug.remote_handler = dbgp&lt;br/&gt;xdebug.idekey=xdebug-atom&lt;br/&gt;&lt;/code&gt;</pre><p data-tool="mdnice编辑器" style="padding-top: 8px; padding-bottom: 8px; line-height: 26px; margin-top: 10px; margin-bottom: 10px; font-size: 14px; word-spacing: 2px;">이 위치를 결정하는 방법! 새 버전을 사용하는 경우<code style="overflow-wrap: break-word; margin: 0px 2px;font-family: " operator mono consolas monaco menlo monospace word-break: break-all rgb rgba>phpstudy, D:phpstudy_proExtensionsphpphp7.3.4ntsext그 위치입니다여기에 이미지 설명 삽입phpstudy의 이전 버전을 사용하는 경우 <img src="https://img-blog.csdnimg.cn/20200701022653739.png" alt="여기에 이미지 설명 삽입" style="max-width:90%"><code style="overflow-wrap: break-word; margin: 0px 2px; font-family: " operator mono consolas monaco menlo monospace word-break: break-all color: rgb background: rgba display: inline-block padding: border-radius: height: line-height:>phpstudyD:phpstudy_proExtensionsphpphp7.3.4ntsext那就是这个位置중단점 디버깅을 배우는 데 도움이 되는 문서如果你是旧版本的phpstudy位置在C:phpStudyPHPTutorialphpphp-7.1.13-ntsext중단점 디버깅을 배우는 데 도움이 되는 문서

四、测试

以上工作完成之后切记需要重启一下环境。

这个时候需要做俩件事。

第一打开atom的debug중단점 디버깅을 배우는 데 도움이 되는 문서

第二在地址栏输上地址http://localhost/index.php?XDEBUG_SESSION_START=1

4. 테스트

위 작업을 완료한 후 환경을 다시 시작하는 것을 잊지 마세요.

중단점 디버깅을 배우는 데 도움이 되는 문서이번에는 두 가지 작업을 완료해야 합니다. 중단점 디버깅을 배우는 데 도움이 되는 문서

첫 번째 오픈 아톰 디버그여기에 이미지 설명 삽입🎜🎜둘째, 주소 표시줄에 주소를 입력하세요.http://localhost/index.php?XDEBUG_SESSION_START= 1 /code>여기서 다음 매개변수에 주의하세요. 🎜🎜이때 팝업창이 뜨는데, 프로젝트 경로에 해당 주소를 입력하시면 됩니다🎜이때 디버깅 패널이 나오며, 우리의 변수값이 출력된 것을 보실 수 있습니다. 🎜지금까지 중단점 디버깅이 완료되었습니다. 🎜<h1 data-tool="mdnice编辑器" style="margin-top: 30px; margin-bottom: 15px; padding: 0px; color: black; font-size: 25px;"> <span class="prefix" style="color: rgb(64, 184, 250); display: none;"></span><span class="content" style="display: inline-block; color: rgb(64, 184, 250);"> 5. 요약 </span><span class="suffix" style="display: inline-block; color: rgb(64, 184, 250);"></span> </h1> <p data-tool="mdnice编辑器" style="padding-top: 8px; padding-bottom: 8px; line-height: 26px; margin-top: 10px; margin-bottom: 10px; font-size: 14px; word-spacing: 2px;">중단점을 구성하는 중요한 단계에 대한 요약입니다. </p> <ul data-tool="mdnice编辑器" style="margin-top: 8px; margin-bottom: 8px; padding-left: 25px; font-size: 15px; color: #595959; list-style-type: circle;"> <li><section style="margin-top: 5px; margin-bottom: 5px; line-height: 26px; font-size: 14px;">atom php-debug 다운로드</section></li> <li><section style="margin-top: 5px; margin-bottom: 5px; line-height: 26px; font-size: 14px;">xdebug를 다운로드하여 해당 PHP 확장 프로그램에 넣어주세요</section></li> <li><section style="margin-top: 5px; margin-bottom: 5px; line-height: 26px; font-size: 14px;">주소 표시줄에 접근할 때 가져와야 합니다<code style="overflow-wrap: break-word; margin: 0px 2px; font-family: " operator mono consolas monaco menlo monospace word-break: break-all color: rgb background: rgba display: inline-block padding: border-radius: height: line-height:>?XDEBUG_SESSION_START=1
  • Atom 경로 구성 시 꼭 프로젝트 경로가 전방 경사를 사용한다고 낙관합니다. Rod
  • 위 내용은 중단점 디버깅을 배우는 데 도움이 되는 문서의 상세 내용입니다. 자세한 내용은 PHP 중국어 웹사이트의 기타 관련 기사를 참조하세요!

    성명:
    본 글의 내용은 네티즌들의 자발적인 기여로 작성되었으며, 저작권은 원저작자에게 있습니다. 본 사이트는 이에 상응하는 법적 책임을 지지 않습니다. 표절이나 침해가 의심되는 콘텐츠를 발견한 경우 admin@php.cn으로 문의하세요.