View Single Post
Old 12-23-2011, 12:17 PM  
fris
Too lazy to set a custom title
 
fris's Avatar
 
Industry Role:
Join Date: Aug 2002
Posts: 55,219
Quote:
Originally Posted by AAB View Post
Donncha's "No Ad for Friends" was last updated in 2007 and doesn't work. Does anybody know of a plugin that would block display of ads for logged in members?
actually if you are using a text widget, you could run a filter on the widget to only show it to non members.

Code:
add_filter( 'widget_text', 'non_members' );

function non_members($content = null ) {

	/* If the user is logged in, return nothing. */
	if ( is_user_logged_in() || is_null( $content ) )
		return '';

	/* Return the content. */
	return do_shortcode( $content );
}
__________________
Since 1999: 69 Adult Industry awards for Best Hosting Company and professional excellence.


WP Stuff
fris is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote