0 Replies Last post: Feb 20, 2013 9:11 PM by Cheng Wang  
Cheng Wang Newbie 1 posts since
Feb 20, 2013
Currently Being Moderated

Feb 20, 2013 9:11 PM

Help of reformatting code

1. move "elseif" to new line (can be done by Preferences -> Code Style -> PHP -> Wrapping and Braces -> "if" statement -> 'else' on new line)

2. move comment after "elseif" to top of "elseif" (What should I do?)

 

 

example

======================

 

original code:

 

if( $a === TRUE ){

    $b = $c + $d;

}elseif{ //comment

    $b = $c + $e;

}

 

 

===============> expect code

 

if( $a === TRUE ){

    $b = $c + $d;

}

//comment

elseif{

    $b = $c + $e;

}

More Like This

  • Retrieving data ...