Check if Page Slug Exists, then display that Page’s Title
looking at MySQL query in the function it becomes clear that though it matches the post_name and returns true or false. What you want to find is, if a page exists by its slug. So, in that case, the function you have chosen is wrong. To get the page by title you can simply use: … Read more