getCurVal() ) { $html .= ''; } $html .= ''; $html .= ''; if ( $this->getCurVal() ) { $html .= '
'; } return $html; } function lPost() { if ( substr( $this->attr_name, -8 ) == '_preview' ) { return; } $tmpObj = new cobject( '_sys_files' ); $file = $_FILES[$this->attr_name]; $nn = md5(microtime(true)); if ($_POST[$this->attr_name . '_del']) { $this->obj->set( $this->attr_name, '' ); }elseif ($_POST[$this->attr_name]) { $this->obj->set( $this->attr_name, $_POST[$this->attr_name] ); } if (!$file['error']) { $this->obj->set($this->attr_name, 'data:'.$file['type'].';base64,' . base64_encode(file_get_contents($file['tmp_name'])) ); } } function render_text( $crop = false ) { if ($crop) { if ( $this->getCurVal() ) { $val = $this->getCurVal(); } else { $val = ''; } } else { $val = $this->getCurVal(); } return $val; } } ?>