Removing Login Fields From Justin Kliens WP-Facebook-Autoconnect

First of all I would like to say thanks to Justin for the plugin, it saved me some time :)
You can find his easy to use plugin at his personal blog site: http://www.justin-klein.com/projects/wp-fb-autoconnect/

This modification will work with Version 1.3.10

After about half an hour I was able to find the code that was causing a second duplicate login and password field. I am sure Justin was thinking ahead with the login fields but in some cases it actually interferes with the blog design/UI. The other problem was the welcome and edit profile links once logged in.

The block of code is found in 2 sections within Widget.php

The First NULLED section will remove the Welcome and Edit profile links once a user is logged in.
The Second NULLED section of code will remove the login fields.

Widget.php
Note: you can copy and past this entire code onto your Widget.php file to update it or download the file directly from the link at the bottom of this post.
[cc lang=”php”]
WP_Widget( false, “WP-FB AutoConnect”, array( ‘description’ => ‘A sidebar Login/Logout form with Facebook Connect button’ ) );

}

//////////////////////////////////////////////////////

//Output the widget’s content.

function widget( $args, $instance )

{

//Get args and output the title

extract( $args );

echo $before_widget;

$title = apply_filters(‘widget_title’, $instance[‘title’]);

if( $title ) echo $before_title . $title . $after_title;

//If logged in, show “Welcome, User!”

$userdata = wp_get_current_user();

if( $userdata->ID ):

?>


########################################################################
########################################################################
########################################################################

NULLED TO PREVENT THE WELCOME MESSAGE ONCE THE USE IS LOGGED IN–>

display_name?>!

|

## END OF NULL <-- */?>

/wp-login.php’ method=’post’>

“;?>

‘>

##END OF NULL <-- */?>

If this too much code for you and you just want the login fields gone download the following files and replace the ones in your x:/wp-content/plugins/wp-fb-autoconnect folder.

Download Files