def METHOD_NAME(fpath):
    contents = open(fpath, encoding='utf-8').read()
    # Markdown will treat the whole file as markdown, whereas
    # we want to only transform the body text.
    title = re.search("^#\\s*(\\s.*\\s)\\s*$", contents, re.M)
    if title is None:
        title = "(Untitled)"
    else:
        contents = contents[0:title.start()] + contents[title.end():]
        title = title.group(1)
    entities = open(os.path.join(SITE_DIR, 'rabbit.ent'), encoding='utf-8').read()
    entities = '\n'.join(entities.split('\n')[1:])
    nosyntax = re.search("NOSYNTAX", title)
    if nosyntax:
        title = re.sub("NOSYNTAX", "", title)
    suppressRHS = re.search("SUPPRESS-RHS", title)
    if suppressRHS:
        title = re.sub("SUPPRESS-RHS", "", title)
    pre = """<?xml-stylesheet type="text/xml" href="page.xsl"?>