Results 1 to 4 of 4
  1. #1
    Join Date
    Apr 2008
    Posts
    133
    Plugin Contributions
    1

    Default missing php closing tags

    I don't know that it matters, since v1.5.5f seems to work, but I have noticed missing closing php tags in several files while customizing my templates.

    For example, take a look at includes/languages/english/login.php.

    There is an opening php tag at the top; there is NOT a closing tag at the bottom.

  2. #2
    Join Date
    Dec 2009
    Location
    Amersfoort, The Netherlands
    Posts
    2,846
    Plugin Contributions
    25

    Default Re: missing php closing tags

    That is by design. The last closing bracket is optional

  3. #3
    Join Date
    Jul 2012
    Posts
    16,732
    Plugin Contributions
    17

    Default Re: missing php closing tags

    Quote Originally Posted by Design75 View Post
    That is by design. The last closing bracket is optional
    Part of the design consideration has reported to be that when the closing tag has been included, there have been too many occurrences of an extra character that might inadvertently get added after the closing tag (like a space) which causes problems when trying to execute the code.

    To maintain some sanity for upgrading, the developers have generally been removing or supporting removal of the closing php tag if the file has been otherwise updated for execution. This is instead of just removing it from every file. Removal from all files makes it look like every file has been edited and requires replacement which isn't really a true need with the current fileset.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  4. #4
    Join Date
    Apr 2008
    Posts
    133
    Plugin Contributions
    1

    Default Re: missing php closing tags

    I see. Thanks for explaining this. Now I know that I should not be putting them back in to my edited templates!

 

 

Similar Threads

  1. Replies: 0
    Last Post: 1 Dec 2013, 03:11 PM
  2. Replies: 1
    Last Post: 17 Mar 2013, 10:16 PM
  3. v150 [Fixed v1.5.1] extra closing head in admin profiles.php
    By torvista in forum Bug Reports
    Replies: 2
    Last Post: 19 Sep 2012, 03:55 AM
  4. v150 Closing php bracket question
    By Ryan in forum Upgrading to 1.5.x
    Replies: 2
    Last Post: 29 Jan 2012, 12:33 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR