View Issue Details

IDProjectCategoryView StatusLast Update
0014748mantisbtprintingpublic2014-12-08 02:07
Reporterphyllisl Assigned Todregad  
PrioritynormalSeveritycrashReproducibilityalways
Status closedResolutionfixed 
Product Version1.3.0dev 
Target Version1.3.0-beta.1 
Summary0014748: XML Parse Error when having jpg image as attachment in summary report in HTML
Description

There is an error happening when having a attachment of jpg image in 1.3. When generating summary report in HTML, it breaks on line 194, col 194:

<td class="print" colspan="5">
    Error#504.jpg (116,726) <span class="italic">2012-09-25 16:33</span>

http://10.96.99.119/mantisbt/file_download.php?file_id=1&type=bug [^]
<img src="file_download.php?file_id=1&type=bug" alt="jpg" />

It outputs fine after I changed the '&' before "type=bug" alt="jpg" />
" to '&'.

Steps To Reproduce

Upload one jpg image as attachment->summary->print report->HTML->Error

TagsNo tags attached.
Attached Files
source code for XML parsing error on &.txt (5,996 bytes)   
<?xml version="1.0" encoding="utf-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en" ><head>
	<link rel="stylesheet" type="text/css" href="http://10.96.99.119/mantisbt/css/default.css" />
	<link rel="stylesheet" type="text/css" href="http://10.96.99.119/mantisbt/css/jquery-ui-1.8.20.custom.css" />
	<link rel="stylesheet" type="text/css" href="http://10.96.99.119/mantisbt/css/common_config.php" />
	<link rel="stylesheet" type="text/css" href="http://10.96.99.119/mantisbt/css/status_config.php" />
	<meta http-equiv="Content-type" content="application/xhtml+xml; charset=UTF-8" />
	<meta http-equiv="Pragma" content="no-cache" />
	<meta http-equiv="Cache-Control" content="no-cache" />
	<meta http-equiv="Pragma-directive" content="no-cache" />
	<meta http-equiv="Cache-Directive" content="no-cache" />
	<meta http-equiv="Expires" content="Wed, 26 Sep 2012 16:40:52 GMT" />
	<link rel="shortcut icon" href="/mantisbt/images/favicon.ico" type="image/x-icon" />
	<link rel="search" type="application/opensearchdescription+xml" title="MantisBT: Text Search" href="http://10.96.99.119/mantisbt/browser_search_plugin.php?type=text" />
	<link rel="search" type="application/opensearchdescription+xml" title="MantisBT: Issue Id" href="http://10.96.99.119/mantisbt/browser_search_plugin.php?type=id" />
	<title>MantisBT</title>
	<script type="text/javascript" src="/mantisbt/javascript_config.php"></script>
	<script type="text/javascript" src="/mantisbt/javascript_translations.php"></script>
	<script type="text/javascript" src="/mantisbt/javascript/jquery-1.7.2.min.js"></script>
	<script type="text/javascript" src="/mantisbt/javascript/jquery-ui-1.8.20.custom.min.js"></script>
	<script type="text/javascript" src="/mantisbt/javascript/common.js"></script>
</head>
<body>
<div id="mantis">
<br />
<table class="width100" cellspacing="1">
<tr>
	<td class="form-title" colspan="3">
		View Issue Details	</td>
</tr>
<tr>
	<td class="print-spacer" colspan="6">
		<hr />
	</td>
</tr>
<tr class="print-category">
	<td class="print" width="16%">
		ID:	</td>
	<td class="print" width="16%">
		Category:	</td>
	<td class="print" width="16%">
		Severity:	</td>
	<td class="print" width="16%">
		Reproducibility:	</td>
	<td class="print" width="16%">
		Date Submitted:	</td>
	<td class="print" width="16%">
		Last Update:	</td>
</tr>
<tr class="print">
	<td class="print">
		1	</td>
	<td class="print">
		[Test] Test	</td>
	<td class="print">
		minor	</td>
	<td class="print">
		have not tried	</td>
	<td class="print">
		2012-09-25 16:32	</td>
	<td class="print">
		2012-09-25 16:33	</td>
</tr>
<tr>
	<td class="print-spacer" colspan="6">
		<hr />
	</td>
</tr>
<tr class="print">
	<td class="print-category">
		Reporter:	</td>
	<td class="print">
		administrator	</td>
	<td class="print-category">
		Platform:	</td>
	<td class="print">
			</td>
	<td class="print" colspan="2">&#160;</td>
</tr>
<tr class="print">
	<td class="print-category">
		Assigned To:	</td>
	<td class="print">
			</td>
	<td class="print-category">
		OS:	</td>
	<td class="print">
			</td>
	<td class="print" colspan="2">&#160;</td>
</tr>
<tr class="print">
	<td class="print-category">
		Priority:	</td>
	<td class="print">
		normal	</td>
	<td class="print-category">
		OS Version:	</td>
	<td class="print">
			</td>
	<td class="print" colspan="2">&#160;</td>
</tr>
<tr class="print">
	<td class="print-category">
		Status:	</td>
	<td class="print">
		new	</td>
	<td class="print-category">
		Product Version:	</td>
	<td class="print">
			</td>
	<td class="print" colspan="2">&#160;</td>
</tr>
<tr class="print">
	<td class="print-category">
		Product Build:	</td>
	<td class="print">
			</td>
	<td class="print-category">
		Resolution:	</td>
	<td class="print">
		open	</td>
	<td class="print" colspan="2">&#160;</td>
</tr>
<tr class="print">
	<td class="print-category">
		Projection:	</td>
	<td class="print">
		none	</td>
	<td class="print-category">
		&#160;
	</td>
	<td class="print">
		&#160;
	</td>
	<td class="print" colspan="2">&#160;</td>
</tr>
<tr class="print">
	<td class="print-category">
		ETA:	</td>
	<td class="print">
		none	</td>
	<td class="print-category">
		Fixed in Version:	</td>
	<td class="print">
			</td>
	<td class="print" colspan="2">&#160;</td>

</tr>
<tr class="print">
	<td class="print-category">
		&#160;
	</td>
	<td class="print">
		&#160;
	</td>
	<td class="print-category">
		Target Version:	</td>
	<td class="print">
			</td>
	<td class="print" colspan="2">&#160;</td>
</tr>
<tr>
	<td class="print-spacer" colspan="6">
		<hr />
	</td>
</tr>
<tr class="print">
	<td class="print-category">
		Summary:	</td>
	<td class="print" colspan="5">
		Test	</td>
</tr>
<tr class="print">
	<td class="print-category">
		Description:	</td>
	<td class="print" colspan="5">
		Test	</td>
</tr>
<tr class="print">
	<td class="print-category">
		Steps To Reproduce:	</td>
	<td class="print" colspan="5">
			</td>
</tr>
<tr class="print">
	<td class="print-category">
		Additional Information:	</td>
	<td class="print" colspan="5">
			</td>
</tr>
<tr class="print">
	<td class="print-category">
		Attached Files:	</td>
	<td class="print" colspan="5">
		Error#504.jpg (116,726) <span class="italic">2012-09-25 16:33</span><br />http://10.96.99.119/mantisbt/file_download.php?file_id=1&amp;type=bug<br /><img src="file_download.php?file_id=1&type=bug" alt="jpg" /><br />	</td>
</tr>

<tr><td colspan="6" class="print">&nbsp;</td></tr>

<tr><td class="print" colspan="6">
<table class="width100" cellspacing="1">
<tr>
	<td class="print" colspan="2">
		There are no notes attached to this issue.	</td>
</tr>

</table>
</td></tr>
</table>


<br /><br />
</div>
</body>
</html>
error.png (18,486 bytes)   
error.png (18,486 bytes)   

Relationships

related to 0014721 closeddregad Error page when generate summary in HTML format 
related to 0015721 closedgrangeway Functionality to consider porting to master-2.0.x 

Activities

grangeway

grangeway

2013-04-05 17:57

reporter   ~0036235

Marking as 'acknowledged' not resolved/closed to track that change gets ported to master-2.0.x branch

Related Changesets

MantisBT: master 65793390

2012-09-26 13:07

dregad


Details Diff
Fix 0014748: XML Parsing Error in print_all_bug_page_word.php

When printing a bug with inline image attachments, an XML parsing error
was triggered due to lack of html encoding of the image's URL.
Affected Issues
0014748
mod - print_all_bug_page_word.php Diff File