Clean up

I'm doing some clean up to all files that need it. This mostly consists of validating the HTML and keep all files consistent.

It is still work in progress. I hope to finish it tomorrow.
> Flagged and library are separate query parameters.

Does this part mean you are pointing out a bug?