{"id":21813201,"url":"https://github.com/webdevstudios/wds-custom-login-page","last_synced_at":"2025-09-08T16:48:16.245Z","repository":{"id":29467192,"uuid":"33003744","full_name":"WebDevStudios/WDS-Custom-Login-Page","owner":"WebDevStudios","description":"Create a custom login page on your WordPress site.","archived":false,"fork":false,"pushed_at":"2017-01-11T00:17:51.000Z","size":36,"stargazers_count":35,"open_issues_count":5,"forks_count":16,"subscribers_count":55,"default_branch":"master","last_synced_at":"2025-03-27T13:45:13.746Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/WebDevStudios.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-03-27T18:56:04.000Z","updated_at":"2024-08-28T18:42:30.000Z","dependencies_parsed_at":"2022-09-06T20:40:44.178Z","dependency_job_id":null,"html_url":"https://github.com/WebDevStudios/WDS-Custom-Login-Page","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WebDevStudios%2FWDS-Custom-Login-Page","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WebDevStudios%2FWDS-Custom-Login-Page/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WebDevStudios%2FWDS-Custom-Login-Page/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WebDevStudios%2FWDS-Custom-Login-Page/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/WebDevStudios","download_url":"https://codeload.github.com/WebDevStudios/WDS-Custom-Login-Page/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248795478,"owners_count":21162779,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-27T14:27:54.270Z","updated_at":"2025-04-13T23:26:32.661Z","avatar_url":"https://github.com/WebDevStudios.png","language":"PHP","readme":"# WDS Custom Login Page\nCreate a custom login page on your WordPress site.\n\n## Usage\nOn plugin activation, Custom Login Page looks for a page with the slug 'login'. If this page doesn't exist, it will create it. If *nothing* else is done at this point, the plugin will work perfectly. It uses a filter to display the login form on a page named 'login' and all requests for wp-login.php will redirect to that login page.\n\nBut maybe you want to use a custom template to handle your login page. That works, too, and there are a couple ways you can do it.\n\n### Option 1: Using a `page-*.php` template\nLet's say you want to create a page template that WordPress knows right off the bat will be the template used for a particular page. The way you'd do this in WordPress is to name your page template `page-*.php`, where the `*` is the slug of the page. In our case, maybe we have a page template named `page-login.php`. This template will be used *by default* by the plugin if the file exists.\n\nBut what about if I don't want to use the 'login' slug for my login page? That's okay, you can name it whatever you want. The only difference is that, if you change the slug, you'll need to hit the Login Page Options and set the page you want to use as the login page. That will tell the plugin not to default to `login` for the page slug and, instead use whatever the slug is for the page you set.\n\n### Option 2: Using a custom page template\nWhat if you don't want to use a `page-*.php` template and you want to name your custom template something else. In this case, you'll need to use the `template-*.php` naming convention. By default -- just like with the `page-*.php` template -- the plugin will look for a `template-login.php` file and use that, if it exists. If it doesn't, you'll need to set it on the options page, just like you did in Option 1. Also like Option 1, the naming convention needs to match -- whatever your page slug is for your login page, needs to be the same for the `*` in the `template-*.php` -- so if you changed your slug to `login-page`, you'll need to have a template named `template-login-page.php`.\n\nIn either case, you need to actually add in the login form. The form *won't* be added automatically for you if you are using a custom template file.\n\n## Manually inserting the login form\nOnce again, there are 2 ways to add the login form to your login page if you're using a custom template and not letting the Custom Login Page plugin do it for you.\n\n### Using the template tag\nAdd this function somewhere in your login page's custom template file:\n\n`wds_login_form( $redirect, $echo )`\n\n`wds_login_form` takes two optional parameters.\n\n#### `$redirect`\n`$redirect` is a custom url to a page you want to redirect the user to after they login. By default, it will try to redirect the user to the page they came from last. The default value is `''`.\n\n#### `$echo`\n`$echo` tells the plugin whether to echo the login form or just return it. It defaults to `false` and just returns the form. If you want to display it directly on a page without having to echo it (and you were setting the redirect to the default), you might use it like this:\n\n`\u003c?php wds_login_form( '', true ); ?\u003e`\n\n### Using the shortcode\nDid I mention there's a shortcode? You can also not worry about all this coding stuff and just insert a login form shortcode in the body of your login page's content. The shortcode is really simple:\n\n`[login_form]`\n\nThe shortcode takes no parameters and just uses the default behavior for redirection.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwebdevstudios%2Fwds-custom-login-page","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwebdevstudios%2Fwds-custom-login-page","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwebdevstudios%2Fwds-custom-login-page/lists"}