TF: Fix code errors, missing tags, add layout to subpages