Use named modules instead of filenames

I.E., use rewrite_module instead of mod_rewrite.h
Sumbodule update to core

Apply Windows path fixes to pages class.
Simplify detecting if __DIR__ is DOCUMENT_ROOT

Turns out to be slightly shorter to do str_replace(rtrim()) than to do
rtrim(str_replace())