Count arrays comma separated values

后端 未结 3 814
迷失自我
迷失自我 2021-01-25 01:40

I\'m using this function to get an array of custom meta fields in WordPress

$my_var = get_meta_values( \'keywords\' );
if( !empty( $my_var ) ) {
    $meta_counts         


        
3条回答
  •  北海茫月
    2021-01-25 02:36

    you can get 13 words or phrases by this

    $words = array_map('trim', explode(',', implode(',', array_keys($meta_counts))));
    

提交回复
热议问题