## php – how to get sentence values from wordpress shortcode parameter?

Question

I’ve set up a shortcode that gets sentence value from parameter, but it only returns the first word of the sentence. I’ve assumed that the shortcode recognizes values after whitespaces, but when I use double quotes, it breaks the shortcode. is there any workaround on this? thanks in advance.

here is my code:

function summary_items( $atts ,$content = null) {

$defaults = shortcode_atts( array( 'item' => '------', ),$atts );

$output="<li>". esc_attr($defaults['item']) .'</li>';
return \$output;

}


[summary_items item=this is a test] //this outputs "this" only.