Welcome Guest, Not a member yet? Register   Sign In
User Guide Examples and Closing PHP tag

The Style Guide mentions that the closing php tag should not be used.

However, I've noticed the controller examples for things like the File Uploading Class and the Form Validation Class have the closing PHP tag.

I'm still learning CodeIgniter so I just want to verify that we should indeed use the closing comment version of the file rather than a closing PHP tag.

Use the closing comment, not the closing PHP tag.

The Form Validation and Upload class don't have a PHP closing tag in CI 1.7.2, which version are you using?


Will close my controllers with the comment.

Thanks for the reply Smile

A lot of people get this wrong!

As stated above use the colosing comments,
the reason you see some the old way is because
its old code that has not been updated etc.


Theme © iAndrew 2016 - Forum software by © MyBB