<?php 

extract(shortcode_atts( array(
	'classes' => ''
), $atts ) );	

$columns = explode( '[pricing_column', $content );
$columnsNum = count( $columns );
$columnsNum = $columnsNum - 1;

switch ( $columnsNum ) {
	case '2' :
		$column_class = 'pricing-columns-2';
		break;
	case '3' :
		$column_class = 'pricing-columns-3';
		break;
	case '4' :
		$column_class = 'pricing-columns-4';
		break;	
	case '5' :
		$column_class = 'pricing-columns-5';
		break;
}

echo '<div class="pricing-table '. $column_class . ' ' . $classes . '">' . do_shortcode($content) . '</div>';

?>