Beispiel #1
0
         <p>Imagen 5</p>
         <div class="controls">
             <?php 
 if ($Image5 != '') {
     $Set_Picture = $Image5;
 } else {
     $Set_Picture = \SKT_URL_BASE . '_FileSystems/avatar.png';
 }
 $FieldName5 = $User->username . '_Image5_' . \RAND_GLOBAL_INSTANCE;
 $Foto = new \CmsDev\CustomControl\ImageUpload\ImageUpload_Control();
 $FieldRand = $Foto->Set_Random(md5(rand(9, 999999) . microtime()));
 $Foto->Set_fileType(array('image/jpeg', 'image/jpg', 'image/png'));
 $Foto->Set_fileTypeNames('JPG o PNG sin transparencia, con fondo blanco preferentemente.');
 $Foto->Set_TextButton('Cargar imagen');
 if ($Image5 != '') {
     $Foto->EnablePictureDefault();
 }
 $Foto->SizeW(800);
 $Foto->SizeH(600);
 $Foto->ResizeSize(true);
 $Foto->CropSize();
 $Foto->ShowDelete('Quitar imagen');
 $Foto->Set_Max_Dimension_And_FileSize(1280, 900, 2097152);
 $Foto->Set_Picture($Set_Picture);
 $Foto->Set_Directory('_FileSystems' . \DS . 'Products' . \DS);
 $Foto->Set_Name($User->username . '_' . $FieldName5 . md5(microtime()));
 $Foto->Set_FieldName($FieldName5);
 $Foto->RealName('Image5');
 $Foto->Make();
 ?>
         </div>