Closed (fixed)
Project:
Zoomify
Version:
5.x-2.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
16 Jul 2008 at 16:38 UTC
Updated:
4 Aug 2008 at 08:53 UTC
The module currently only deals with the first image of multiple-image fields. Applying this patch to zoomify_imagefield.module should mean that all images are processed instead.
As for displaying them, I didn't alter the theme_zoomify method in zoomify.module as I was overriding it anyway with my own theme function. To do this yourself, the following code might be useful (it switches images according to a URL parameter called 'mediaPage', but you could alter this as you see fit):
function mytheme_zoomify($node, $images) {
drupal_set_title($node->title);
$viewer = base_path() . '/' . drupal_get_path('module', 'zoomify') . '/zoomifyViewer.swf';
$fid_key = $_GET['mediaPage'] ? (int)$_GET['mediaPage']-1 : 0;
$fids = array_keys($images);
$fid = $fids[$fid_key];
$image = file_create_url(_zoomify_filepath($node, $fid));
$width = variable_get('zoomify_width', 800);
$height = variable_get('zoomify_height', 600);
$nid = $node->nid;
return <<<EOS
<div class="zoomify zoomify-node-$nid zoomify-file-$fid">
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0" id="theMovie" width="$width" height="$height">
<param name="FlashVars" value="zoomifyImagePath=$image">
<param name="menu" value="false">
<param name="src" value="$viewer">
<embed flashvars="zoomifyImagePath=$image" src="$viewer" menu="false" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" name="theMovie" width="$width" height="$height"></embed>
</object>
</div>
EOS;
}
| Comment | File | Size | Author |
|---|---|---|---|
| zoomify_imagefield_patch.txt | 845 bytes | tristan_roddis |
Comments
Comment #1
infojunkieFixed in latest 2.x-dev. The URL for accessing Zoomify is now node/$nid/zoomify/$index, where $index = 0..count($images)-1. Please try it and let me know.
Comment #2
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.