Followup c232083: use getRelativeTitle for template titles

Otherwise we output stuff like {{Template:Echo|hello}}

Change-Id: Ib6c3996ab40e01a5ddce84b7daffa27a74020ee5
(cherry picked from commit 2ba844a37297bf1f0bf936af175e168952690561)
Followup a86d824: fix reference to this in foreach callback

Bug: 73235
Change-Id: Ib8f877f747df6c8047c7e3d2c152e0e7a9f60b8a
(cherry picked from commit aa84df021ac3af3c5253017e5d8b16080f60bf54)
Merge "Followup c232083: use getRelativeTitle for template titles" into wmf/1.25wmf7
Merge "Followup a86d824: fix reference to this in foreach callback" into wmf/1.25wmf7