mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-15 16:38:54 +00:00
Added an example
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@243713 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
81dc6a8b45
commit
b2d97b104b
1 changed files with 16 additions and 15 deletions
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
<!-- $Revision: 1.1 $ -->
|
||||
<!-- $Revision: 1.2 $ -->
|
||||
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="function.imagick-getimageproperties">
|
||||
<refnamediv>
|
||||
<refname>Imagick::getImageProperties</refname>
|
||||
|
@ -86,36 +86,37 @@
|
|||
</refsect1>
|
||||
-->
|
||||
|
||||
<!-- Use when examples exist
|
||||
<refsect1 role="examples">
|
||||
&reftitle.examples;
|
||||
<para>
|
||||
<example>
|
||||
<title>A <function>Imagick::getImageProperties</function> example</title>
|
||||
<title>Using <function>Imagick::getImageProperties</function>:</title>
|
||||
<para>
|
||||
Any text that describes the purpose of the example, or
|
||||
what goes on in the example should go here (inside the
|
||||
<example> tag, not out
|
||||
An example of extracting EXIF information.
|
||||
</para>
|
||||
<programlisting role="php">
|
||||
<![CDATA[
|
||||
<?php
|
||||
if ($anexample === true) {
|
||||
echo 'Use the PEAR Coding Standards';
|
||||
|
||||
/* Create the object */
|
||||
$im = new imagick("/path/to/example.jpg");
|
||||
|
||||
/* Get the EXIF information */
|
||||
$exifArray = $im->getImageProperties("exif:*");
|
||||
|
||||
/* Loop trough the exif properties */
|
||||
foreach ($exifArray as $name => $property)
|
||||
{
|
||||
echo "{$name} => {$property}<br />\n";
|
||||
}
|
||||
|
||||
?>
|
||||
]]>
|
||||
</programlisting>
|
||||
&example.outputs;
|
||||
<screen>
|
||||
<![CDATA[
|
||||
Use the PEAR Coding Standards
|
||||
]]>
|
||||
</screen>
|
||||
</example>
|
||||
</para>
|
||||
</refsect1>
|
||||
-->
|
||||
|
||||
|
||||
<!-- Use when adding See Also links
|
||||
<refsect1 role="seealso">
|
||||
|
|
Loading…
Reference in a new issue