0 && $clsConfig->langMulti) { echo '
'.$af['lbl'].'
    '; foreach($clsConfig->lang as $key => $lang) { $af2 = $af; $af2['cls'] = isset($af2['cls']) ? $af2['cls'] : '' ; //$af2['Name'] = $af['Name'].($key>0 ? '_'.$lang : ''); $af2['Name'] = $af['Name'].($lang != 'tc' ? '_'.$lang : ''); $tabs .= '
  • '.strtoupper($lang).'
  • '; if(strpos($af2['cls'],'otherLang')===false) { //$af2['cls'] .= $key>0 ? ' otherLang' : ''; //$af2['cls'] .= $lang != 'en' ? ' otherLang' : ''; $af2['cls'] .= $lang != $lang3Default ? ' otherLang' : ''; } $content .= '
    '.showInput($af2,$data,$crop_image_index).'
    '; } echo $tabs.'
'.$content; echo '
'; } elseif ( $af['type'] == 'subTitle' ) { echo '
'.$af['lbl'].'
'; } else { echo '
'.$af['lbl'].'
'. showInput($af,$data,$crop_image_index).'
'; } if ($af['type'] == 'image') { $crop_image_index = $crop_image_index + 1; } } } } if(!function_exists('showInput')) { function showInput($af,$data,$crop_image_index=1) { global $ACT,$db, $strSesName, $index; if($ACT=='view' && ( !isset($af['customView']) || !$af['customView'] ) ) { if($af['type']=='image') { $path = '../'.end(explode('|',$data[$af['Name']])); //return ''; $htmlIMG = ''; if ( $path != '../' ) { $htmlIMG = file_exists($path) ? '' : $htmlIMG; $htmlIMG = file_exists(img_path($path)) ? '' : $htmlIMG; } return $htmlIMG; } elseif($af['type']=='file') { return ''; } elseif($af['type']=='multiupload') { /* ********** ********** Load Attachment ********** ********** ********** */ $sql = "SELECT * FROM attachment WHERE a_ref_id = '".$GLOBALS['id']."' AND a_ref_type = '".$af['ref_type']."' ORDER BY a_sort_id, a_crt_dt DESC"; $query = $db->execSQL($sql); while($a = $db->fetchAry($query)) { if(file_exists('../'.img_path($a['a_path'],'thumb'))) { $fPath = img_path($a['a_path'],'thumb'); } else { $fPath = $a['a_path']; } $uploaded_file .= '
'; } return '
'.$uploaded_file.'
'; /* ********** ********** ********** ********** ********** ********** ********** */ } elseif($af['type']=='custom') { eval('$input = '.$af['loopFunction'].';'); return $input; } else { if( isset($af['option']) && $af['option']) { $val = showOption($af['option'],$data[$af['Name']],$af['type']); } else { $val = $data[$af['Name']]; } if ( isset($af['FldType']) ) { switch($af['FldType']) { case 'DATE': case 'TIME': $val = substr( $val , 0 , $af['Len'] ); switch( $val ) { case '0000-00-00': case '00:00:00': case '0000-00-00 00:00:00': $val = ''; break; } break; } } return $af['type']=='textarea' ? '' : ''; } } if ( !isset($af['type']) ) { $af['type'] = 'text'; } switch($af['type']) { case 'label': $input = isset($data[$af['Name']]) ? $data[$af['Name']] : ''; $input = nl2br(htmlspecialchars( $input )); $input = '
'.$input.'
'; if ( isset($af['lblDesc']) && $af['lblDesc']) { $input.= $af['lblDesc']; } return $input; break; case 'textarea': $input = '