{"id":2686,"date":"2026-10-20T08:35:27","date_gmt":"2026-10-20T07:35:27","guid":{"rendered":"https:\/\/wpgeodirectory.com\/documentation\/article\/own-login-and-registration-pages\/"},"modified":"2026-10-20T08:40:41","modified_gmt":"2026-10-20T07:40:41","slug":"own-login-and-registration-pages","status":"publish","type":"gd_place","link":"https:\/\/wpgeodirectory.com\/documentation\/article\/how-tos\/own-login-and-registration-pages\/","title":{"rendered":"How to use your own login and registration pages with GeoDirectory"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">GeoDirectory has no login or registration pages of its own. When a logged-out visitor opens the add listing page, GeoDirectory shows &#8220;You must login to post.&#8221; with Login and Register buttons, and those buttons use the standard WordPress login and registration URLs. Whatever controls those URLs on your site also decides where GeoDirectory sends people.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Using UsersWP or another login plugin<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\"><a href=\"https:\/\/userswp.io\/\">UsersWP<\/a>, our free user plugin, points the WordPress login and register links at its own pages, so the GeoDirectory buttons go there with no extra setup. Choose the pages at UsersWP &gt; Settings &gt; General &gt; Pages. Other login plugins that change the WordPress login URL work the same way.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Pointing the links at your theme&#8217;s login page<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">If your theme has a login page that does not change the WordPress login URL, redirect the links with the standard WordPress filters. Replace <code>\/login\/<\/code> and <code>\/register\/<\/code> with your own pages, then add the code with the <a href=\"https:\/\/wpgeodirectory.com\/documentation\/article\/useful-plugins\/code-snippets-plugin\/\">Code Snippets plugin<\/a>:<\/p>\n\n\n\n<pre class=\"wp-block-prismatic-blocks\"><code class=\"language-php\">\/\/ Send WordPress (and GeoDirectory) login links to your own login page.\nadd_filter( &#039;login_url&#039;, &#039;my_custom_login_url&#039;, 20, 3 );\nfunction my_custom_login_url( $login_url, $redirect, $force_reauth ) {\n\t$url = home_url( &#039;\/login\/&#039; ); \/\/ Change to your login page.\n\n\tif ( ! empty( $redirect ) ) {\n\t\t$url = add_query_arg( &#039;redirect_to&#039;, urlencode( $redirect ), $url );\n\t}\n\n\treturn $url;\n}\n\n\/\/ Send register links to your own registration page.\nadd_filter( &#039;register_url&#039;, &#039;my_custom_register_url&#039;, 20 );\nfunction my_custom_register_url( $register_url ) {\n\treturn home_url( &#039;\/register\/&#039; ); \/\/ Change to your registration page.\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">This changes the login link everywhere WordPress uses it, not only in GeoDirectory. Your login page needs to support <code>redirect_to<\/code> if you want people taken back to the add listing form after they log in.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Register link missing or going to the wrong page<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>The Register button only appears when WordPress allows sign-ups. Tick &#8220;Anyone can register&#8221; at Settings &gt; General.<\/li>\n\n\n\n<li>If a menu link such as &#8220;Register&#8221; opens your homepage, the menu item points at the wrong page or one that no longer exists. Fix it at Appearance &gt; Menus.<\/li>\n\n\n\n<li>With UsersWP, check that the Login and Register pages are both set in its settings.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">More checks are in <a href=\"https:\/\/wpgeodirectory.com\/documentation\/article\/troubleshooting\/why-can-my-users-not-register\/\">Why can my users not register?<\/a>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Letting visitors post without an account<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">To let visitors add a listing before they have an account, go to GeoDirectory &gt; Settings &gt; General, click Show Advanced, and tick &#8220;Allow posting without logging in?&#8221;. The add listing form then asks for a name and email. &#8220;Anyone can register&#8221; must be on for this as well.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>GeoDirectory has no login or registration pages of its own. When a logged-out visitor opens the add listing page, GeoDirectory shows &#8220;You must login to post.&#8221; with Login and Register buttons, and those buttons use the standard WordPress login and registration URLs. Whatever controls those URLs on your site also decides where GeoDirectory sends people. [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"article\/tags":[],"article\/categories":[211,432],"class_list":["post-2686","gd_place","type-gd_place","status-publish","hentry","gd_placecategory-tips-tricks-more","gd_placecategory-how-tos"],"_links":{"self":[{"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/article\/2686","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/article"}],"about":[{"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/types\/gd_place"}],"author":[{"embeddable":true,"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/comments?post=2686"}],"version-history":[{"count":1,"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/article\/2686\/revisions"}],"predecessor-version":[{"id":2828,"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/article\/2686\/revisions\/2828"}],"wp:attachment":[{"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/media?parent=2686"}],"wp:term":[{"taxonomy":"gd_place_tags","embeddable":true,"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/article\/tags?post=2686"},{"taxonomy":"gd_placecategory","embeddable":true,"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/article\/categories?post=2686"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}