Fix etag missing headers

Same as in @devayes PR. but with less modifications (I leave those apache function) and also with minor code stamdartization (whitespaces, braces, enters).

But anyway most important is to fix etag php ASAP.