Fix indent and whitespaces
Replace mwexec() by unlink_if_exists() and respect global tmp_path
Remove unecessary var initialization
Fix indent
Convert this block into a function for later use
Improvements on interfaces_assign.php:

- Let user select network port to add instead of pick the first
  available, it fixes #3846
- While I'm here, drop GET and use only POST