当前位置: 首页>>代码示例>>PHP>>正文


PHP image::getInfo方法代码示例

本文整理汇总了PHP中image::getInfo方法的典型用法代码示例。如果您正苦于以下问题:PHP image::getInfo方法的具体用法?PHP image::getInfo怎么用?PHP image::getInfo使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在image的用法示例。


在下文中一共展示了image::getInfo方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: hotlinkimage

 function hotlinkimage($cat_id, $type, $imgid, $key)
 {
     global $mosConfig_live_site, $my;
     $gallery = new gallery($cat_id, false);
     if (!$key) {
         $key = $gallery->getImageKey($imgid);
     } else {
         $imgid = $gallery->_images[$key]->_id;
     }
     $image = new image($imgid);
     $image->getInfo();
     if ($this->_CONFIG['hotlinkProtection']) {
         $params = "uid=" . $my->id . "&catid=" . $cat_id . "&key=" . $key . "&type=" . $type;
         $params = $this->encrypt($params);
         return $mosConfig_live_site . "/components/com_zoom/www/image.php?q=" . $params;
     } else {
         if ($type == '0') {
             return $mosConfig_live_site . "/" . $this->_CONFIG['imagepath'] . $gallery->_dir . "/" . $image->_viewsize;
         } elseif ($type == '1') {
             return $mosConfig_live_site . "/" . $this->_CONFIG['imagepath'] . $gallery->_dir . "/" . $image->_filename;
         } else {
             return $image->_thumbnail;
         }
     }
 }
开发者ID:BGCX261,项目名称:zoom-gallery-svn-to-git,代码行数:25,代码来源:zoom.class.php

示例2: comGenerateVideo

 function comGenerateVideo()
 {
     require_once 'include/class/image.php';
     $image = new image(false);
     $image->video = 'flv';
     $image->id = $this->data['id'];
     $image->getCacheName();
     $image->getInfo();
     $image->generate();
     $this->html = ' setVideoGenerated()';
     $xml = '<?xml version="1.0" encoding="UTF-8" ?>
   <RESPONSE>
     <INFO>
       <COMMAND>' . $this->command . '</COMMAND>
       <ID>' . $this->data['id'] . '</ID>
       <PID>' . $this->data['pid'] . '</PID>
     </INFO>
   </RESPONSE>';
     $xml = preg_replace('/(\\s*)(.*)\\n/', "\\2\n", $xml);
     $xml = preg_replace('/>(\\s*)\\n(\\s*)</', "><", $xml);
     $this->html = $xml;
 }
开发者ID:Ashaan,项目名称:phpgallery,代码行数:22,代码来源:ajax.php

示例3: VALUES

     $rating = "Explicit";
 } else {
     if ($rating == "q") {
         $rating = "Questionable";
     } else {
         $rating = "Safe";
     }
 }
 if ($userc->check_log()) {
     $user = $checked_username;
 } else {
     $user = "Anonymous";
 }
 $ip = $db->real_escape_string($_SERVER['REMOTE_ADDR']);
 $thumb = $image->thumbnail($iinfo[0] . "/" . $iinfo[1]);
 $isinfo = $image->getInfo();
 $query = "INSERT INTO {$post_table}(creation_date, hash, image, title, owner, height, width, ext, rating, tags, directory, source, active_date, ip) VALUES(NOW(), '" . md5_file("./images/" . $iinfo[0] . "/" . $iinfo[1]) . "', '" . $iinfo[1] . "', '{$title}', '{$user}', '" . $isinfo[1] . "', '" . $isinfo[0] . "', '{$ext}', '{$rating}', '{$tags}', '" . $iinfo[0] . "', '{$source}', '" . date("Ymd") . "', '{$ip}')";
 if (!is_dir("./thumbnails/" . $iinfo[0] . "/")) {
     $image->makethumbnailfolder($iinfo[0]);
 }
 if (!$thumb) {
     print "Thumbnail generation failed! A serious error occurred and the image could not be resized.<br /><br />";
 }
 if (!$db->query($query)) {
     print "failed to upload image.";
     print $query;
     unlink("./images/" . $iinfo[0] . "/" . $iinfo[1]);
     $image->folder_index_decrement($iinfo[0]);
     $ttags = explode(" ", $tags);
     foreach ($ttags as $current) {
         $tclass->deleteindextag($current);
开发者ID:logtcn,项目名称:gelbooru-fork,代码行数:31,代码来源:post_add.php


注:本文中的image::getInfo方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。