I think in layout files, we prefer HTML tags to be outputted directly and not using `echo`. Also please leave the `if` with the alternative writing using a colon `:`.
So this lines were actually correct the way they were.