$val){ if(1 == $p[$key]){ $template->setCurrentBlock('__Okonomi__'); $template->setVariable('terms',$val); $template->parseCurrentBlock(); $template->setCurrentBlock('__HiddenParamYes__'); $template->setVariable('name',$key); $template->parseCurrentBlock(); $template->setCurrentBlock('__HiddenParamNo__'); $template->setVariable('name',$key); $template->parseCurrentBlock(); $okonomi_count++; } } //お好み設定がない場合の処理 if(0 == $okonomi_count){ $template->setCurrentBlock('__Okonomi__'); $template->setVariable('terms','特になし'); $template->parseCurrentBlock(); } //避けたい食材内容表示処理 foreach($terms_arr['saketai'] as $key => $val){ if(1 == $p[$key]){ $template->setCurrentBlock('__Saketai__'); $template->setVariable('terms',$val); $template->parseCurrentBlock(); $template->setCurrentBlock('__HiddenParamYes__'); $template->setVariable('name',$key); $template->parseCurrentBlock(); $template->setCurrentBlock('__HiddenParamNo__'); $template->setVariable('name',$key); $template->parseCurrentBlock(); $saketai_count++; } } //避けたい食材がない場合の処理 if(0 == $saketai_count){ $template->setCurrentBlock('__Saketai__'); $template->setVariable('terms','特になし'); $template->parseCurrentBlock(); } $template->show(); } okazu_conf( $p ); ?>