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

Website LiveChat Services!

After a couple of hours of configuration and modifications I was able to install a complete LiveChat solution for the client Martian Laser (www.martianlaser.com) located in San Diego, Ca. The Live Chat Solution allows the client to see live online vistors, what page they are viewing and even make real-time suggestions and assistance. The Application also allows the client to determine the source of the visitor via Google’s Geo-location API. A definite tool for any business owner.

Automatic Image Randomization/Rotation Using PHP

Ok here you go, This script simply takes your images inside a chosen folder and then loads a random picture inside that folder.
If you have any questions just Holla at me!

[cc lang=”php”]

5. You can also specify the image to display like this:

This would specify that an image named “gorilla.jpg” located
in the image-rotation folder should be displayed.

That’s it, you’re done.

*/

/* ————————- CONFIGURATION ———————–

Set $folder to the full path to the location of your images.
For example: $folder = ‘/user/me/example.com/images/’;
If the rotate.php file will be in the same folder as your
images then you should leave it set to $folder = ‘.’;

*/

$folder = ‘.’;

/*

Most users can safely ignore this part. If you’re a programmer,
keep reading, if not, you’re done. Go get some coffee, smoke a cig or
do your thang.

If you’d like to enable additional image types other than
gif, jpg, and png, add a duplicate line to the section below
for the new image type.

Add the new file-type, single-quoted, inside brackets.

Add the mime-type to be sent to the browser, also single-quoted,
after the equal sign.

For example:

PDF Files:

$extList[‘pdf’] = ‘application/pdf’;

CSS Files:

$extList[‘css’] = ‘text/css’;

You can even serve up random HTML files:

$extList[‘html’] = ‘text/html’;
$extList[‘htm’] = ‘text/html’;

Just be sure your mime-type definition is correct!

*/

$extList = array();
$extList[‘gif’] = ‘image/gif’;
$extList[‘jpg’] = ‘image/jpeg’;
$extList[‘jpeg’] = ‘image/jpeg’;
$extList[‘png’] = ‘image/png’;

// You don’t need to edit anything after this point.

// ——————— END CONFIGURATION ———————–

$img = null;

if (substr($folder,-1) != ‘/’) {
$folder = $folder.’/’;
}

if (isset($_GET[‘img’])) {
$imageInfo = pathinfo($_GET[‘img’]);
if (
isset( $extList[ strtolower( $imageInfo[‘extension’] ) ] ) &&
file_exists( $folder.$imageInfo[‘basename’] )
) {
$img = $folder.$imageInfo[‘basename’];
}
} else {
$fileList = array();
$handle = opendir($folder);
while ( false !== ( $file = readdir($handle) ) ) {
$file_info = pathinfo($file);
if (
isset( $extList[ strtolower( $file_info[‘extension’] ) ] )
) {
$fileList[] = $file;
}
}
closedir($handle);

if (count($fileList) > 0) {
$imageNumber = time() % count($fileList);
$img = $folder.$fileList[$imageNumber];
}
}

if ($img!=null) {
$imageInfo = pathinfo($img);
$contentType = ‘Content-type: ‘.$extList[ $imageInfo[‘extension’] ];
header ($contentType);
readfile($img);
} else {
if ( function_exists(‘imagecreate’) ) {
header (“Content-type: image/png”);
$im = @imagecreate (100, 100)
or die (“Cannot initialize new GD image stream”);
$background_color = imagecolorallocate ($im, 255, 255, 255);
$text_color = imagecolorallocate ($im, 0,0,0);
imagestring ($im, 2, 5, 5, “IMAGE ERROR”, $text_color);
imagepng ($im);
imagedestroy($im);
}
}

?>

[/cc]

Finally! Something I Actually Want To Work On… My Site!

OMG! its been such a long time since i have began to work on my site. It seems we are always caught up catering to the whining clients needs, like a babysitter dealing with spoiled kids. Although this is sometimes frustrating it has a positive impact on your experience. I am going to be using a lot of source code and ideas that I have used on past clients to make this site a little more exciting. If you dont like it well then thats too freaken bad, go make your own site. bwahahahahah~!

Further Developing WebSymantecs.com…

It has almost been 6 months since the design and data model where first created and it has not stopped. The process of building a company site and delivering to your clients becomes quite the task sometimes feeling vast and never ending. The complications of life never seem to whither away leaving us to fumble in our complexities. Like all great things, they take a while to be done. As development continues to progress on the site the more it seems to come to life. We are getting closer and closer to the launch, this is an exciting time.

Profiles VS Websites for SEO and SEM campaigns, which is better?

DO NOT GO WITH ANY MARKETING COMPANY WHO OFFERS YOU PROFILES ON DIRECTORIES FOR SEO! I cannot tell you how many clients I have had complain to me about their so called online marketing and how its not working at all. This is because Google does not rank a profile as a separate entity but as a whole in that directory, If your marketing company is selling you on exposure through their directory don’t buy into it. No search engine will every give a profile higher ranking than a top level domain (www.yoursite.com) in fact google has taken steps recently to stop this profile boom and its rankings after multiple complaints from people all over the web about scams and what not.