$duree_chose = get_post_meta_ordered($post->ID,'_duree_chose'); $to_do = get_post_meta_ordered($post->ID,'_duree_chose'); // je test s'il y a autant de tâches que de durées if(count( $to_do )>0 && count( $to_do )==count( $duree_chose ) ): foreach($to_do as $k => $thing){ ?>