[Geomoose-users] Adding a photo to a feature report (Geomoose 2.0)

Len Kne lkne at houstoneng.com
Mon Oct 19 18:09:34 EDT 2009


Adding a photo is possible, but may be hard to work with if the images are not all the same size.  In the feature report template you define where and how big to make a space for the map and attributes.  If the image is going to vary in size, you would have to leave space for the largest possible image or resize images to fit the space you create for it.  Your shapefile would need to have an attribute with the image name.

Once it is defined in the template, you would need to modify print.php (or feature_report.php) to process the image.  You could work for the lines for the map image:

                $map_info = $template_info->getElementsByTagName('map')->item(0);
                $imageW = round(((float)$map_info->getAttribute('w'))*72);
                $imageH = round(((float)$map_info->getAttribute('h'))*72);
                $imageX = round(((float)$map_info->getAttribute('x'))*72);
                $imageY = round(((float)$map_info->getAttribute('y'))*72);
                $pdf->Image($tempDir.$uniqueId.'_pdf.jpg', $imageX, $imageY, $imageW, $imageH);

Len

From: Matthew D. Syvertson [mailto:msyvertson at co.richland.nd.us]
Sent: Monday, October 19, 2009 4:18 PM
To: geomoose-users at lists.sourceforge.net
Subject: [Geomoose-users] Adding a photo to a feature report (Geomoose 2.0)


OK everyone.  I know how to put the map into a feature report, and text, and also dynamic information from the shapefile.  Now comes the difficult part, I think.  How do I put an image onto the report?  I can put a hyperlink into the report fairly easily, but I want the actual image to be on the page if possible.

Any ideas?

Matt Syvertson

Richland County GIS Coordinator

418 2nd Ave N
Wahpeton, ND 58075

msyvertson at co.richland.nd.us<mailto:matthews at co.richland.nd.us>

Voice: 701-642-7860  Fax: 701-642-7746
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/geomoose-users/attachments/20091019/f12b1538/attachment.html


More information about the Geomoose-users mailing list