Class Definitions

Class declarations have their opening brace on a new line:

<?php
class Foo_Bar
{

    
//... code goes here

}
?>
Function Calls (Previous) Function Definitions (Next)
Last updated: Sat, 16 Feb 2019 — Download Documentation
Do you think that something on this page is wrong? Please file a bug report.
View this page in:
  • English

User Notes:

Note by: user@example.com
If we put a starting braces for control structure on same row,then why not same with classes