X-Git-Url: http://git.harvie.cz/?a=blobdiff_plain;f=wwwroot%2Finc%2Feventz%2Fupload_data_file.inc;h=7c21f3ae8b83bd0e84ceba2dffbb3889e0e5fee6;hb=9506a2cb819d240a403a0a10d9acd28428805e91;hp=09aa33eae3bd99a0393b970edbb25205f79ca487;hpb=afe738490837fa1cbc41daaaf6754c2feb2be024;p=mirrors%2FKyberia-bloodline.git diff --git a/wwwroot/inc/eventz/upload_data_file.inc b/wwwroot/inc/eventz/upload_data_file.inc index 09aa33e..7c21f3a 100644 --- a/wwwroot/inc/eventz/upload_data_file.inc +++ b/wwwroot/inc/eventz/upload_data_file.inc @@ -1,7 +1,5 @@ ".SYSTEM_ROOT.SYSTEM_IMAGES.'/nodes/'.substr($datanode_id,0,1)."/".substr($datanode_id,1,1)."/".$datanode_id.".gif"; - } - elseif (stristr($image_name,".gif")) { - $cmd=UTILZ_DIR."/gifsicle --resize ".$width."x_ $image > ".SYSTE_ROOT.SYSTEM_IMAGES.'/nodes/'.substr($datanode_id,0,1)."/".substr($datanode_id,1,1)."/".$datanode_id.".gif"; - } - if ($cmd) { - shell_exec($cmd); - } - // XXX WTF - echo $cmd; - } +# Removed for now, need complete rewrite + +# if ($_POST['gallery']) { +# $node_params['template_id']=DEF_GALLERY_TEMPLATE; +# $image=TMP."/".$_FILES['data_file']['name']."/".$file; +# $image_name=$file; +# $width=NODE_IMAGE_WIDTH; +# +# if (stristr($image_name,".jpg") || +# stristr($image_name,".jpeg") ){ +# +# /// XXX UTILZ_DIR is not set. remove? +# $cmd=UTILZ_DIR."/jpegtopnm $image |".UTILZ_DIR."/pnmscale -width=$width | ".UTILZ_DIR."ppmquant 256 |".UTILZ_DIR."ppmtogif >".SYSTEM_ROOT.SYSTEM_IMAGES.'/nodes/'.substr($datanode_id,0,1)."/".substr($datanode_id,1,1)."/".$datanode_id.".gif"; +# } +# elseif (stristr($image_name,".gif")) { +# $cmd=UTILZ_DIR."/gifsicle --resize ".$width."x_ $image > ".SYSTE_ROOT.SYSTEM_IMAGES.'/nodes/'.substr($datanode_id,0,1)."/".substr($datanode_id,1,1)."/".$datanode_id.".gif"; +# } +# if ($cmd) { +# shell_exec($cmd); +# } +# // XXX WTF +# echo $cmd; +# } } } closedir($handle); @@ -94,8 +94,5 @@ function upload_data_file() { symlink(FILE_DIR.$_SESSION['user_id'].'/'.$node['node_id'].".$suffix", SYSTEM_ROOT.'/files/'.$node['node_id']); } - - } - ?>