In general template functions, cast to string then ensure we actually have a template name before proceeding. Affects get_sidebar(), get_header(), get_footer(), get_template_part().

props tivnet for initial patch.
fixes #24714.



git-svn-id: http://core.svn.wordpress.org/trunk@24616 1a063a9b-81f0-0310-95a4-ce76da25c4cd