PHP´Â ÆÄ½º ¿À·ù¸¦: ±¸¹® ¿À·ù, ÀÇ¿Ü $end

PHP 5¿¡¼­´Â, µÚ¿¡ ¿À´Â °ú½ÇÀº ¾ÆÆÄÄ¡ ¿À·ù ±â·Ï¿¡ ÀÖ´Â °ú½Ç ÀÔÀå ¶Ç´Â °£´ÜÇÏ°Ô PHP À¥ ÆäÀÌÁö¿¡ Àü½Ã·Î ºñ·Ï php_info¸¦ °¡Áø php ¿øº»¿¡ ºÎ¸£´Â °ÍÀÌ () ¿ÏÀüÇÏ°Ô ÀÛµ¿ÇÏ°í ¼º°øÀûÀ¸·Î PHP À±°û¿¡ Á¤º¸¸¦ µ¹·Áº¸³»´õ¶óµµ, ³ªÅ¸³­´Ù ÀÏÁö¸ð¸¥´Ù:

ÆÄ½º ¿À·ù¸¦: ±¸¹® ¿À·ù, ÀÇ¿Ü $end¿¡¼­ ..... ¼±¿¡ scripts.php¡¦

°ú½ÇÀº PHP ¿øº» ÄÚµù¿¡ ÀÖ´Â ¾ø´Â ²¿ºÎ¶óÁø ºÎ·ù¿¡ ÀÇÇØ ÀÏÀ¸Å°´Â ¿øÀÎÀÌ µÇ¾î ÀÏÁö¸ð¸¥´Ù. ÀÇ ¿·¿¡, ±×°ÍÀº Æ´ÀÌ ¹æ¹ý ¼±¾ð ¾È¿¡ ÀÖÀ¸¸é ¾Ê´Â ÇÑ PHP¿¡¼­ °Í°ú °°ÀÌ, Ŭ·¡½º Á¤Àǰ¡ º¹¼ö ÆÄÀÏ, ¶Ç´Â ´Ù¼ö PHP ±¸È¹À¸·Î °¥¶óÁ³´Ù¿Í ¹èºÎÇØ ÀÏ ¼ö ¾ø´Ù, ¶ÇÇÑ Å¬·¡½º Á¤ÀÇ¿¡ ÀÖ´Â PHP ÄÚµù¿¡¼­ ½Ç¼ö·Î ÀÏÀ¸Å°´Â ¿øÀÎÀÌ µÇ¾î ÀÏÁö¸ð¸¥´Ù.

±×·¯³ª ´õ ÀϹÝÀûÀ¸·Î, °ú½ÇÀº PHP¿¡ ÀÖ´Â °£°á ¿­·ÁÀÖ´Â ²¿¸®Ç¥ÀÇ »ç¿ë¿¡ ¼ö½Ã·Î ±âÀÎÇÑ´Ù,

¿­·ÁÀÖ´Â ²¿¸®Ç¥¸¦ ª°Ô ÀÌ¿ëÇϱâ À§ÇÏ¿©´Â, ±×°ÍÀº PHP.INI¿¡¼­ °¡´ÉÇÏ°Ô µÇ¾î¾ß ÇÑ´Ù. PHP.INI¿¡ ÀÖ´Â short_open_tag¸¦ ã°í, À§¿¡¿¡ °¡Ä¡¸¦ ¹Ù²Ù½Ê½Ã¿À. ¼±Àº ¼±À» ºÁ¾ß ÇÑ´Ù:

short_open_tag = À§¿¡

Áß¿äÇÑ: À̰ÍÀº º¸Àå ¾øÀÌ "ÀÖ´Â ±×´ë·Î" Á¦°øµÇ´Â ±â°è ¹ø¿ª ÆäÀÌÁöÀÌ´Ù. ±â°è¹ø¿ªÀº ÀÌÇØÇϱ⠰ï¶õÇÒÁöµµ ¸ð¸¥´Ù. Âü°íÇϽʽÿÀ ¿ø·¡ ¿µ±¹ ±â»ç °¡´ÉÇÑ ¾ðÁ¦µçÁö.

°øÀ¯ÇÏ°í °øÇåÇϰųª ±â¼úÁö¿øÀ» ¾ò°í¿¡ µµ¿ì½Ê½Ã¿À ³ªÀÇ µðÁöÅÐ »ýȰ °ø°³Åä·Ð.



13 Responses to ¡°PHP Parse Error: syntax error, unexpected $end¡±

  1. drwael
    May 14th, 2006 23:30
    1

    thanks a lot,
    short_open_tag = On solved that problem for me

  2. Paul
    August 22nd, 2006 22:49
    2

    Thanks for this post¡¦saved me a lot of time!

  3. ike
    December 20th, 2006 04:57
    3

    I saw your posting and made the change to the php.ini file and I¡¯m still getting the error the is being run with Fedora Core 5 with MySql 5.
    Can someone please help

    0)
    {
    while ($row = mysql_fetch_assoc($result))
    {
    print $row(¡¯cust_id¡¯) . ¡®-¡¯ . $row(¡¯cust_url_desc¡¯) ;

    }
    }
    else
    {

    echo ¡®No rows found!¡¯;
    }

    mysql_free_result($result);

    mysql_close($connection);

    ?>

  4. Bruno
    February 5th, 2007 07:41
    4

    Hello. I have a problem with a PHP file that shows the ¡°PHP Parse Error: syntax error, unexpected $end¡± error and I followed the instructions in this page and corrected the php.ini from OFF to ON.
    Now, the file don¡¯t give any feedback when I open it. It only gives me a blank page and no info! O_o
    It¡¯s strange¡¦ Can you help me please? Thanks.

  5. phpcoder
    March 29th, 2007 22:29
    5

    This might be due to a missing quote also

  6. Shawn
    August 30th, 2007 19:39
    6

    Thanks a ton, I¡¯ve been trying to figure this out for the last few hours.

  7. gilbert
    September 15th, 2007 20:20
    7

    thhanx a lot short_open_tag = On solved my problem. ypu are helpful

  8. Hamed
    September 30th, 2007 12:07
    8

    wow! thanks for your useful guidance¡¦

  9. Guy
    October 23rd, 2007 18:52
    9

    Very useful, thanks. I just upgraded to openSuse 10.3 from 10.2 which had reset my php.ini.

  10. Rana
    February 27th, 2008 20:22
    10

    Thanks for your time, But for me Its really didfficult to find a missing curly bracket.

    Is there any easiest way to findout with MISSING CURLY BRACKET. Any editor can do it for us.

    Please Help.
    Rana

  11. sugi
    March 8th, 2008 14:27
    11

    syntax error, unexpected $end in C:\wamp\www\login.php on line 49

  12. Richard
    March 17th, 2008 00:32
    12

    Thank you,

    Been searching for ages for solution to this.

    short_open_tag = On solved that problem for me.

    Finally I can open templates

  13. Raghavendra
    May 10th, 2008 14:10
    13

    Thank you very much ¡¦..

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>

Subscribe without commenting


Custom Search

New Articles

Incoming Search Terms for the Article

php unexpected $end - Parse error: syntax error, unexpected $end - Parse error: syntax error, unexpected $end in - unexpected $end - Parse error: syntax error, unexpected $end - syntax error, unexpected $end - unexpected $end php - php unexpected $end - Parse error: syntax error, unexpected $end in - php "unexpected $end" - syntax error, unexpected $end - syntax error, unexpected $end in - php unexpected end - PHP Parse error: syntax error, unexpected $end - $end php - unexpected $end in php - php $end - Unexpected $end - php unexpected $end in - unexpected $end in - php Parse error: syntax error, unexpected $end - syntax error, unexpected $end in - "Parse error: syntax error, unexpected $end" - PHP Parse error: syntax error, unexpected $end - "syntax error, unexpected $end" - "PHP Parse error: syntax error, unexpected $end" - php $end error - php syntax error, unexpected $end - php end - syntax error, unexpected $end php - php error $end - PHP unexpected $end in - php syntax error, unexpected $end in - PHP Parse error: syntax error, unexpected $end - $end error meaning in php - all - "parse error: syntax error, unexpected $end in" - $end error php - PHP Parse error: syntax error, unexpected $end i - PHP Parse error: syntax error, unexpected $end in - Parse error: syntax error, unexpected $end in C:\wamp\www\ - $end php error - $end error in php - $end in php - Parse error: syntax error, unexpected $end - syntax error, unexpected $end i - php Parse error: syntax error, unexpected $end in - Parse error: syntax error, unexpected $end wordpress - syntax error in php - "$end" php -