Extract attribute values from every shortcode in post
Method #1 If available, I would use the: shortcode_atts_{$shortcode} filter to collect the attributes of a given shortcode. Example: $text=” “; $out = wpse172275_get_all_attributes( ‘gallery’, $text ); print_r( $out ); with the output: Array ( [0] => [1] => Array ( [ids] => 1,2 https://wordpress.stackexchange.com/questions/172275/extract-attribute-values-from-every-shortcode-in-post => file ) [2] => Array ( [ids] => 3 … Read more