当前位置: 首页 > news >正文

如何用ip地址做网站网站排名英文怎么说

如何用ip地址做网站,网站排名英文怎么说,企业网络推广搜索排名,宜昌建设网站公司在imagecreatefromgif()函数的PHP手册页中有一个简短的代码片段#xff0c;应该是你所需要的#xff1a;由ZeBadger提供的图片评论#xff03;59787在search同样问题的解决scheme时#xff0c;我注意到php.net网站对Davide和Kris所指代码的后续操作#xff0c;但根据作者的…在imagecreatefromgif()函数的PHP手册页中有一个简短的代码片段应该是你所需要的由ZeBadger提供的图片评论59787在search同样问题的解决scheme时我注意到php.net网站对Davide和Kris所指代码的后续操作但根据作者的说法内存密集程度更低可能更less的磁盘密集。我会在这里复制它因为它可能是有趣的。来源 http //www.php.net/manual/en/function.imagecreatefromgif.php#88005function is_ani($filename) { if(!($fh fopen($filename, rb))) return false; $count 0; //an animated gif contains multiple frames, with each frame having a //header made up of: // * a static 4-byte sequence (\x00\x21\xF9\x04) // * 4 variable bytes // * a static 2-byte sequence (\x00\x2C) // We read through the file til we reach the end of the file, or weve found // at least 2 frame headers while(!feof($fh) $count 2) { $chunk fread($fh, 1024 * 100); //read 100kb at a time $count preg_match_all(#\x00\x21\xF9\x04.{4}\x00[\x2C\x21]#s, $chunk, $matches); } fclose($fh); return $count 1; }这是工作function/** * Thanks to ZeBadger for original example, and Davide Gualano for pointing me to it * Original at http://it.php.net/manual/en/function.imagecreatefromgif.php#59787 **/ function is_animated_gif( $filename ) { $raw file_get_contents( $filename ); $offset 0; $frames 0; while ($frames 2) { $where1 strpos($raw, \x00\x21\xF9\x04, $offset); if ( $where1 false ) { break; } else { $offset $where1 1; $where2 strpos( $raw, \x00\x2C, $offset ); if ( $where2 false ) { break; } else { if ( $where1 8 $where2 ) { $frames ; } $offset $where2 1; } } } return $frames 1; }如果给定的文件太大用file_get_contents读取整个文件可能会花费太多的内存。 我已经重新考虑了以前给出的函数它只读取了足够的字节来检查帧并且一find至less2帧就返回。?php /** * Detects animated GIF from given file pointer resource or filename. * * param resource|string $file File pointer resource or filename * return bool */ function is_animated_gif($file) { $fp null; if (is_string($file)) { $fp fopen($file, rb); } else { $fp $file; /* Make sure that we are at the beginning of the file */ fseek($fp, 0); } if (fread($fp, 3) ! GIF) { fclose($fp); return false; } $frames 0; while (!feof($fp) $frames 2) { if (fread($fp, 1) \x00) { /* Some of the animated GIFs do not contain graphic control extension (starts with 21 f9) */ if (fread($fp, 1) \x2c || fread($fp, 2) \x21\xf9) { $frames; } } } fclose($fp); return $frames 1; }animationGIF必须具有以下string\x21\xFF\x0B\x4E\x45\x54\x53\x43\x41\x50\x45\x32\x2E\x30
http://www.yutouwan.com/news/372537/

相关文章:

  • 云南昆明网站建设app开发公司收费
  • html5 移动网站网站标题名字和备案名字
  • 广州做企业网站的公司无锡市建设培训中心网站
  • 无锡做网站公司哪家好电话网络营销型企业网站案例
  • 网站 多语言处理企业个人邮箱怎么注册
  • 珠海建网站价格网站建设培训课程
  • 辽宁建设厅网站首页技术支持::天空网络-临汾做网站
  • 劳务公司网站怎么做iis搭建网站教程win10
  • 门户网站制作泉州网站建设哪里好
  • 淘宝客网站模板下载销售找客户的app
  • 响应网站和模板网站营销型企业网站制作
  • 网站建设投标书 技术架构看板娘wordpress怎么带声音
  • 导航网站的好处企业建设网站好吗
  • 网站开发当前城市定位功能wordpress 收邮件发布
  • iis6网站域名谢岗镇网站建设
  • 三亚网站设计公司汇鑫网站建设方便
  • 用jsp做的汽车网站博罗做网站技术
  • 网站上怎么做推广自我建设外贸网站
  • thinkphp网站开发教程网站建设业务客户来源
  • 重庆网站搜索排名企业建立网站的好处
  • 网站建设与制作模板标准论坛网站建设
  • 可以做片头的网站云平台
  • 利用别人域名做自己的网站dnf做任务解制裁的网站
  • ui网站一般建好大重庆市建设工程信息网官网福海玻璃
  • 上海人才中心网站学做软件的网站有哪些内容
  • 做标签的网站广州美快软件开发有限公司
  • 石景山做网站电商网站做互联网金融
  • 绍兴网站开发廊坊百度推广代运营
  • 手机网站建设必要性网站开发哈尔滨网站开发公司
  • wordpress做网站怎么样怎么样建设企业网站