Snippets: Conditionally Alter Portfolio Post Grid Links

function myprefix_vcex_shortcode_loop_atts( $atts ) {

	// Target portfolio grid
	if ( isset( $atts['base'] )
		&& 'vcex_portfolio_grid' == $atts['base']
	) {
		$atts['post_permalink'] = 'http://www.wpexplorer.com/';
	}

	// very important
	return $atts;

}
add_filter( 'vcex_shortcode_loop_atts', 'myprefix_vcex_shortcode_loop_atts' );

Version Required:3.5.3+

Snippet Type: PHP

Posted Under: Portfolio

All PHP snippets should be added via a child theme's functions.php file.