Comments and Comment Blocks in PHP 의견이나 코멘트를 차단 php

PHP supports C language, C++ programming language and Unix shell-style (Perl style) comments. php를 지원 c 언어, c + + 프로그래밍 언어와 유닉스 쉘 - 스타일 (펄 스타일) 코멘트합니다. In PHP, // or # is used to make a single-line comment or /* and */ to make a large comment block that spans several lines. 이 php, / / 또는 #을 사용하여 단일 - 라인 코멘트를 만들 또는 / *와 * /를 여러 라인에 걸쳐있는 대형 코멘트를 블록이있습니다.

For example: 예를 들면 :

<?php <함수

echo ‘This is a test’; //This is a single-line C++ style comment 에코 '이것은 테스트'; / / 이것은 단일 - 라인 c + + 스타일 주석
echo ‘This is another test’;#This is another single-line shell-style comment 에코 '이것은 다른 테스트'; #이 자체가 또 다른 하나 - 라인 쉘 - 스타일 코멘트
/* This is a multi line comment / * 이것은 다중 라인 주석
Second line of comment */ 두 번째 줄에의 주석을 * /

?>

The “one-line” comment styles comment to the end of the line or the current block of PHP code, whichever comes first. "한 - 선"코멘트 스타일 주석의 끝에 라인이나 현재의 블럭의 코드, 둘 중 먼저 해당합니다. This means that HTML code after the PHP script block (PHP mode broken with ?> and returns to HTML mode after end of PHP code block) will be printed. 즉, html 코드를 php 스크립트 블록 (php 모드로 부서지는가?>을 반환 코드를 html 모드로 후에 마지막 블록)가 인쇄합니다. If the asp_tags configuration directive is enabled, it behaves the same with // %> and # %>. asp_tags 구성 지시문이 활성화된 경우에, 그것과 같은 행동을 / / "%>와 #"%>. However, the </script> tag doesn’t break out of PHP mode in a single-line comment. 그러나이 </ 스크립트> 태그를 벗어나려하지 않습니다 php 모드에서 단일 - 라인 코멘트를합니다.

For example, 예를 들면,

<h1>This is an <?php # echo ’simple’;?> example.<h1> <h1> 이것은 <함수 # 에코 '단순';?> 예. <h1>
<p>The header above will say ‘This is an example’.</p> <p> 이상의 헤더가 말하는 '이것은 예입니다'. </ p>

C or C++ style comments end at the first */ encountered. c 또는 c + + 스타일 주석 끝에 첫 번째 * / 발생합니다. Any nested /* and */ style comments will cause error, and it’s pretty easy to make this mistake if you are trying to comment out a large block of code. 중첩된 / * 및 * / 스타일의 코멘트가 원인 오류, 그리고 아주 간단하게 실수를하려고하는 경우 대형 블럭의 코드를 주석으로 처리합니다.

<?php <함수

/* / *
echo ‘This is a test’; /* This comment will cause a problem */ 에코 '이것은 테스트'; / *이 코멘트에 문제가 발생 * /
*/ * /

?>

The PHP comments is useful when you want to comment or disable a large portion of HTML. the php 의견은 코멘트를하거나 사용하지 않도록하려는 경우에 유용합니다 큰 부분을 html합니다. Instead comment the HTML code line by line, put the whole HTML block into PHP code block (ie, add <?php and ?>) and comment with /* and */. 대신에 주석의 코드 한줄씩, 그 전체 html 블록을 코드 블록 (즉, 추가 <함수 그리고?>)와 코멘트와 함께 / *와 * /합니다.

IMPORTANT : This is a machine translated page which is provided "as is" without warranty. 중요 사항 : 이것은 기계 번역 페이지는 "있는 그대로"제공하지 않고 보증합니다. Machine translation may be difficult to understand. 기계 번역을 이해하기 어려울 수있습니다. Please refer to 를 참조하시기 바랍니다 original English article 기존 영어 자료 whenever possible. 언제 수있습니다.

Share and contribute or get technical support and help at 를 공유하고 기술 지원 및 도움을 공헌하지 않는다면 My Digital Life Forums 내 디지털 라이프 공개 토론 . 합니다.



2 Responses to “Comments and Comment Blocks in PHP” 2 개의 응답을 "코멘트와 코멘트를 차단 php"

  1. E-Volution IT » Blog Archive » Windows Genuine Advantage circumvention 이메일 - 선회 그것»블로그 아카이브»창 정품 혜택 우회
    July 26th, 2006 06:45 2006년 7월 26일 06:45
    1

    [...] http://www.mydigitallife.info/2006/04/26/dis… . 합니다. [...]

  2. How to Comment Code in WordPress Templates 템플릿 코드에 코멘트를하는 방법을 wordpress
    December 10th, 2007 01:30 2007년 12월 10일 01:30
    2

    [...] tip of the hat to My Digital Life for his article - Comments and Comment Blocks in PHP. [...] 빙산의 모자를 내 디지털 라이프에 대한 그의 기사 - 의견이나 코멘트를 차단 php합니다. By Alec Tags: [...] 알렉 의해 태그 : [...]

Leave a Reply 남길 회신

You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> 이러한 태그를 사용할 수있습니다 : <a href="" title=""> <acronym title=""> <abbr title=""> <blockquote cite=""> <b> <cite> <code> <델 날짜 = ""> <em> <i> <strike> '<q cite="">

Subscribe without commenting 논평없이 구독 신청
이메일


Custom Search

New Articles 새로운 기사

Incoming Search Terms for the Article 이 문서에 대한 검색어를 수신

comment out php 주석 php - - php comment out php 주석 - - comentario em php comentario 안에 php - - comentário em php 코멘트 안에 php - - comment out in php 주석의 php - - how to comment out php 주석으로 처리하는 방법을 php - - comentario php comentario php - - comment out php code 주석 코드 - - php coments php coments - - php comment php 코멘트 - - php coment php coment - - how to comment out PHP code 주석으로 처리하는 방법을 코드 - - commenting out in php 논평에서 php - - free coments 무료 coments - - php comment block of code php 코멘트를 블록으로 코드를 - - myspace comment blocks myspace 코멘트를 차단 - - coment php coment php - - remark out php 비고 아웃 php - - php comment blocks php 코멘트를 차단 - - comentario no php comentario 아니오 php - - comentário php 의견 php - - comment blocks for myspace 코멘트를 차단 myspace - - PHP comentario php comentario - - comment out a block of code in unix 유닉스의 블록을 코드에 주석으로 처리 - - como comentar em PHP 코모 comentar 안에 php - - myspace comment bocks myspace 코멘트를 bocks - - comment out a block of php 주석의 블록을 php - - php comment out blocks php 주석 블록 - - php commenting php 논평 - - php commenting out php 논평 아웃 - - php comment a block of code php 코멘트를 한 블록의 코드 - - comment out block of php 주석 블록을 php - - php comment block php 코멘트를 차단 - - comment block in unix 코멘트를 차단 유닉스 - - coment in php coment에 php - - comment blocks on myspace 코멘트를 블록을 myspace - - hOW TO coment in PHP coment하는 방법에 php - - "comentario em php" "comentario 안에 php" - - comentários em php 코멘트 안에 php - - comentario en php comentario 엉 php - - php coments code php coments 코드를 - - php block of comment php 블럭의 코멘트 - - PHP commenting out a block of code php 논평 밖에서 한 블록의 코드 - - free coments on internet 인터넷에 무료 coments - - comment block for myspace myspace 블록에 대한 의견 - - comentar php comentar php - - comments tag block in pHP 코멘트 태그를 차단 php - - italian coments about life 이탈리아어 coments의 삶에 대해 - - PHP + commenting php + 논평 - - norsk comments code norsk 코멘트 코드를 - -