Minor change to some files

Removed trailing whitespaces in some files
Fixed the message sent in the flashbag when changing language
Deleted some unused views
Fixed bug causing words not to be written in the correct locale

Fixed a bug causing words not to be written in the correct files ; fixed
by injecting the session when instanciating the class
Fixed default locale by using a locale mentioned in the config.yml file,
required
Fixed some issues in older PHP versions with the ternary "if"
statements.
Added a touch + chmod to the file before writing in it, to keep the
access to the file when modifying it.