[PHP-DOC] cvs: phpdoc /en/reference/image/functions getimagesize.xml From: Erica Douglass (erica <email protected>)
Date: 09/06/02

erica Fri Sep 6 01:48:05 2002 EDT

  Modified files:
    /phpdoc/en/reference/image/functions getimagesize.xml
  Log:
  Fixed grammatical errors.
  
  
Index: phpdoc/en/reference/image/functions/getimagesize.xml
diff -u phpdoc/en/reference/image/functions/getimagesize.xml:1.8 phpdoc/en/reference/image/functions/getimagesize.xml:1.9
--- phpdoc/en/reference/image/functions/getimagesize.xml:1.8 Fri Aug 16 15:56:50 2002
+++ phpdoc/en/reference/image/functions/getimagesize.xml Fri Sep 6 01:48:05 2002
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="iso-8859-1"?>
-<!-- $Revision: 1.8 $ -->
+<!-- $Revision: 1.9 $ -->
 <!-- splitted from ./en/functions/image.xml, last change in rev 1.36 -->
  <refentry id="function.getimagesize">
   <refnamediv>
@@ -26,10 +26,10 @@
    </para>
    <para>
     Returns an array with 4 elements. Index 0 contains the width of
- the image in pixels. Index 1 contains the height. Index 2 a
- flag indicating the type of the image. 1 = GIF, 2 = JPG, 3 =
+ the image in pixels. Index 1 contains the height. Index 2 is a
+ flag indicating the type of the image: 1 = GIF, 2 = JPG, 3 =
     PNG, 4 = SWF, 5 = PSD, 6 = BMP, 7 = TIFF(intel byte order),
- 8 = TIFF(motorola byte order, 9 = JPC, 10 = JP2, 11 = JPX, 12 =
+ 8 = TIFF(motorola byte order), 9 = JPC, 10 = JP2, 11 = JPX, 12 =
     JB2, 13 = SWC, 14 = IFF. These values correspond to the IMAGETYPE
     constants that were added in PHP 4.3. Index 3 is a text string with
     the correct height="yyy" width="xxx" string that can be used
@@ -57,31 +57,31 @@
     </example>
    </para>
    <para>
- With <acronym>JPG</acronym> images, two extras index are returned :
+ With <acronym>JPG</acronym> images, two extra indexes are returned:
     <literal>channels</literal> and <literal>bits</literal>.
- <literal>channels</literal> will be 3 for RGB pictures, and 4 for CMYK
+ <literal>channels</literal> will be 3 for RGB pictures and 4 for CMYK
     pictures. <literal>bits</literal> is the number of bits for each color.
    </para>
    <para>
- Since PHP 4.3 <literal>bits</literal> and <literal>channels</literal>
- are present for other image types, too. But these values or there
- presence can be a bit confusing. As example <acronym>GIF</acronym>
- allways uses 3 channels per pixel but the number of bits per pixel
- cannot be computed for an animated <acronym>GIF</acronym> with a global
- colortable.
- </para>
- <para>
- Some formats may contain no image or multiple images. In such cases
- GetImageSize might not be able to determine the size and returns zero
- for width and height.
- </para>
- <para>
- Since PHP 4.3 GetImageSize() does also return the additional
- <literal>mime</literal> that receives the mime-type of the image.
- This information can be used to deliver images with correct http
- Content-type header if this is unknown:
+ Beginning with PHP 4.3, <literal>bits</literal> and <literal>channels</literal>
+ are present for other image types, too. However, the presence of these values
+ can be a bit confusing. As an example, <acronym>GIF</acronym>
+ always uses 3 channels per pixel, but the number of bits per pixel
+ cannot be calculated for an animated <acronym>GIF</acronym> with a global
+ color table.
+ </para>
+ <para>
+ Some formats may contain no image or may contain multiple images. In these cases,
+ getimagesize() might not be able to properly determine the image size. getimagesize() will
+ return zero for width and height in these cases.
+ </para>
+ <para>
+ Beginning with PHP 4.3, getimagesize() also returns an additional parameter,
+ <literal>MIME</literal>, that corresponds with the MIME type of the image.
+ This information can be used to deliver images with correct HTTP
+ Content-type headers:
     <example>
- <title>getimagesize and mime-type</title>
+ <title>getimagesize() and MIME types</title>
      <programlisting role="php">
 <![CDATA[
 <?php
@@ -91,7 +91,9 @@
   header("Content-type: {$size['mime']}");
   fpassthru($fp);
   exit;
-} else // error
+} else {
+ // error
+}
 ?>
 ]]>
      </programlisting>
@@ -105,16 +107,16 @@
    <para>
     The optional <parameter>imageinfo</parameter> parameter allows
     you to extract some extended information from the image
- file. Currently this will return the different
- <acronym>JPG</acronym> APP markers in an associative Array. Some
- Programs use these APP markers to embed text information in
+ file. Currently, this will return the different
+ <acronym>JPG</acronym> APP markers as an associative array. Some
+ programs use these APP markers to embed text information in
     images. A very common one is to embed <acronym>IPTC</acronym>
     <ulink url="&url.iptc;">&url.iptc;</ulink> information in the
     APP13 marker. You can use the <function>iptcparse</function>
     function to parse the binary APP13 marker into something
     readable.
     <example>
- <title>getimagesize returning IPTC</title>
+ <title>getimagesize() returning IPTC</title>
      <programlisting>
 <![CDATA[
 <?php
@@ -141,7 +143,7 @@
       and <function>exif_thumbnail</function>.
      </simpara>
      <simpara>
- URL support was added in PHP 4.0.5
+ URL support was added in PHP 4.0.5.
      </simpara>
     </note>
    </para>

-- 
PHP Documentation Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php