View Issue Details

IDProjectCategoryView StatusLast Update
0012931mantisbtfeaturepublic2014-01-21 18:45
Reportercorin Assigned To 
PrioritynormalSeverityfeatureReproducibilityN/A
Status acknowledgedResolutionopen 
Product Version1.2.4 
Summary0012931: Change one line to add image inline zoom feature
Description

Click the previewed image to zoom it.

Please make following changes:

print_api.php

function print_bug_attachments_list( $p_bug_id )

replace(make as comments):

echo "\n
$t_href_start<img alt=\"$t_title\" $t_preview_style src=\"$t_image_url\" />$t_href_end";

with:

echo "\n
<img alt=\"$t_title\" $t_preview_style src=\"$t_image_url\" onclick=\"if(this.style.maxHeight>'$t_max_height"
. "px'){this.style.maxWidth='';this.style.maxHeight='$t_max_height"
. "px';}else{this.style.maxWidth='800px';this.style.maxHeight='9999px';}\" />";


(Sorry for my english)

TagsNo tags attached.

Activities

dhx

dhx

2011-04-12 05:57

reporter   ~0028599

Last edited: 2011-04-12 05:58

Thanks for the feature request - it sounds like a worthy addition.

Inline Javascript (onclick=, etc) is not allowed in the MantisBT page outputs. The approach we'd use now is to add some jQuery to common.js. The target could either be a new class such as "image-expand" or something more semantic such as: "#attachments img".