Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I am making a login form in WordPress and i want to have a validation on it, so i tried to look at the wp-login.php to see how they validate things. But i did not find what i am looking for. I would like to know how they validate things or what input do they need to validate things. I tried to search the WordPress forums all i can find is plugin, plugin and more plugin. I don't want a plugin. I want to hard code it. So please help me.

I want to know where you can find the part that searches for the user's username and password. Or if not, know what is needed for a successful login. example username or password or others. by the way here is the wp-login.php. Thanks

share|improve this question
    
Just to let you know, no one here will tell you how to hardcode it into WordPress Core. Hacking core is a bad idea. Any code we give you will be in the form of a plugin. –  EAMann Feb 14 '12 at 16:32
    
When you say hard code it, do you mean within your theme? –  Brian Fegter Feb 14 '12 at 17:32
1  
Yes, my theme. any ideas?? –  tomexsans Feb 14 '12 at 17:36
    
Just to clear up some confusion - it does not appear that he is trying to edit a core file. Rather you can have a wp-login.php file in your theme. –  Sterling Hamilton Feb 14 '12 at 17:50

3 Answers 3

up vote 0 down vote accepted

Look in wp-includes/general-template.php at the function wp_login_form(). Follow the functions called there. I’d say: just use wp_login_form(). It does probably everything you need, and you can customize it.

share|improve this answer
    
i had a hard time locating these files, do you know a site or a linke that has a directory mapping of these files. nice tip though –  tomexsans Feb 14 '12 at 18:06
    
I use Eclipse and the WordPress core as a separate project. Then I just through this project. –  toscho Feb 14 '12 at 18:17

Don't edit wp-login.php file. Instead create a new page for your login. If you don't have any coding knowledge use readymade plugins. There are many plugins available to create frontend login form.

For example check this Profile builder plugin.

Also check Theme my login plugin

share|improve this answer
    
thank you i will follow your advice. –  tomexsans Feb 14 '12 at 18:04
    
You are welcome.. –  Giri Feb 14 '12 at 19:10

I would use this in your situation:

http://wordpress.org/extend/plugins/theme-my-login/

Yes - it's a plugin: You then just drop wp-login.php as a page template in your theme.

Note - try it without the plugin - it may not even be needed at this point.


Here are some tutorials that do it without a plugin:

http://www.problogdesign.com/wordpress/custom-wordpress-login-screen/

http://wplift.com/how-to-create-a-custom-login-page-for-your-wordpress-theme

share|improve this answer
    
thanks for the tuts, it will be handy –  tomexsans Feb 14 '12 at 18:06

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.