diff --git a/GeneanetForGramps.py b/GeneanetForGramps.py index d018c81..fbbe1de 100755 --- a/GeneanetForGramps.py +++ b/GeneanetForGramps.py @@ -1188,7 +1188,7 @@ def random_headers(): if verbosity >= 2: print(_("Sex:"), self.g_sex) try: - bstring = '//div[@id="perso"]//ul[0]/li[0]' + bstring = '//div[@id="perso"]/ul[0]/li[0]/text()' if verbosity >= 3: print("bstring: "+bstring) birth = tree.xpath(bstring) @@ -1198,7 +1198,7 @@ def random_headers(): if verbosity >= 3: print(_("birth")+": %s"%(birth)) try: - dstring = '//div[@id="perso"]//ul[0]/li[1]' + dstring = '//div[@id="perso"]/ul[0]/li[1]/text()' if verbosity >= 3: print("dstring: "+dstring) death = tree.xpath(dstring)