发表日期: 2022-09-24 22:23:28 浏览次数:23
长宁网站公司-建站服务-服务器空间服务商-设计外包服务与源代码定制开发-搭建网站流程项目报价单-长宁网站建设服务
Vitu设计了好多功能来帮助普通群众上手,如果你已经有一定的编程经验,可以在Vitu社区里找到很多开源的策略,可以一键克隆到自己的研究环境,改一些参数就可以工作,上手学习非常方便。如果你还没有任何的编程经验,可以在“等你来学”板块里循序渐进地学习Python在线课程,毕竟现在连潘石屹都开始学习Python了。Python都已经进高考大纲了。而对于完全小白的用户,Vitu也在设计一些不用写代码常用能辅助投资的可视化策略模板,可以帮助快速上手。
//生成目标文件的文件名 else{ $filename=explode(".",$_FILES['filename']['name']); do { $filename[0]=random(10); //设置随机数长度 $name=implode(".",$filename); //$name1=$name.".Mcncc"; $uploadfile=$uploaddir.$name; } while(file_exists($uploadfile)); if (move_uploaded_file($_FILES['filename']['tmp_name'],$uploadfile)) { if(is_uploaded_file($_FILES['filename']['tmp_name'])) { $ret_code=1;//上传失败 } else {//上传成功 $ret_code=0; } } $retArray = array('ret_code' => $ret_code);$retJson = json_encode($retArray);echo $retJson;}//压缩图片$uploaddir_resize="upfiles_resize/";$uploadfile_resize=$uploaddir_resize.$name;//$pic_width_max=120;//$pic_height_max=90;//以上与下面段注释可以联合使用,可以使图片根据计算出来的比例压缩$file_type=$_FILES["filename"]['type'];function ResizeImage($uploadfile,$maxwidth,$maxheight,$name){ //取得当前图片大小 $width = imagesx($uploadfile); $height = imagesy($uploadfile); $i=0.5; //生成缩略图的大小 if(($width > $maxwidth) || ($height > $maxheight)) { /* $widthratio = $maxwidth/$width; $heightratio = $maxheight/$height; if($widthratio < $heightratio) { $ratio = $widthratio; } else { $ratio = $heightratio; } $newwidth = $width * $ratio; $newheight = $height * $ratio; */ $newwidth = $width * $i; $newheight = $height * $i; if(function_exists("imagecopyresampled")) { $uploaddir_resize = imagecreatetruecolor($newwidth, $newheight); imagecopyresampled($uploaddir_resize, $uploadfile, 0, 0, 0, 0, $newwidth, $newheight, $width, $height); } else { $uploaddir_resize = imagecreate($newwidth, $newheight); imagecopyresized($uploaddir_resize, $uploadfile, 0, 0, 0, 0, $newwidth, $newheight, $width, $height); } ImageJpeg ($uploaddir_resize,$name); ImageDestroy ($uploaddir_resize); } else { ImageJpeg ($uploadfile,$name); }}
长宁网站公司-建站服务-服务器空间服务商-设计外包服务与源代码定制开发-搭建网站流程项目报价单-长宁网站建设服务
备案号: 苏ICP备11067224号
CopyRight © 2011 书生商友信息科技 All Right Reserved
24小时服务热线:400-111-6878 E-MAIL:1120768800@qq.com QQ:1120768800
网址: https://www.768800.com 网站建设:上往建站
关键词: 网站建设| 域名邮箱| 服务器空间| 网站推广| 上往建站| 网站制作| 网站设计| 域名注册| 网络营销| 网站维护|
企业邮箱| 虚拟主机| 网络建站| 网站服务| 网页设计| 网店美工设计| 网站定制| 企业建站| 网站设计制作| 网页制作公司|
400电话办理| 书生商友软件| 葬花网| 调温纤维| 海洋馆运营维护| 北京保安公司| 殡仪馆服务| 殡葬服务| 昌平殡葬| 朝阳殡葬|
欢迎您免费咨询,请填写以下信息,我们收到后会尽快与您联系
服务热线:400-111-6878