X-Git-Url: http://git.harvie.cz/?a=blobdiff_plain;f=wwwroot%2Finc%2Feventz%2Fupload_data_file.inc;h=3af0a9381d2c6d094fcbc8f8a428dd0f44e14454;hb=57dd552c75ca1484ab8f1a8ce349a66e632427cd;hp=ea00274f74a1fcb5f453dbba864a920262d449a2;hpb=33e10d4c5c188b6afdf78b1cb324277a1e61c4db;p=mirrors%2FKyberia-bloodline.git diff --git a/wwwroot/inc/eventz/upload_data_file.inc b/wwwroot/inc/eventz/upload_data_file.inc index ea00274..3af0a93 100644 --- a/wwwroot/inc/eventz/upload_data_file.inc +++ b/wwwroot/inc/eventz/upload_data_file.inc @@ -1,7 +1,5 @@ ".SYSTEM_ROOT."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 > ".SYSTEM_ROOT."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); @@ -90,10 +82,8 @@ function upload_data_file() { copy($_FILES['data_file']['tmp_name'], FILE_DIR.$_SESSION['user_id'].'/'.$node['node_id'].".$suffix"); symlink(FILE_DIR.$_SESSION['user_id'].'/'.$node['node_id'].".$suffix", - SYSTEM_ROOT.'/files/'.$node['node_id']); + FILE_DIR.'/'.$node['node_id']); } - - +*/ } - ?>