ABCpdf를 사용하여 이미지가 포함 된 웹 페이지를 PDF 문서로 렌더링하려고합니다. 이 작업은 웹 응용 프로그램에서 수행됩니다.ABCpdf가 IIS6의 웹 응용 프로그램에서 이미지를 렌더링하지 않습니다.
IIS5에서 개발 컴퓨터에서 응용 프로그램을 실행할 때 모든 것이 정상입니다. IIS6에서 응용 프로그램을 배포하면 이미지가 pdf에 나타나지 않습니다.
문제를 재현하기 위해 간단한 웹 페이지에서 PDF 파일을 렌더링하는 간단한 웹 응용 프로그램을 만들었으며 로컬이 아닌 이미지가 pdf에없는 파일이라는 것을 알았습니다. ABCpdf와 상호 작용
관련 코드는 다음과 같습니다
Doc theDoc = new Doc();
theDoc.Rect.Inset(18, 18);
theDoc.HtmlOptions.PageCacheEnabled = false;
theDoc.HtmlOptions.PageCacheClear();
theDoc.HtmlOptions.UseNoCache = true;
theDoc.HtmlOptions.Timeout = 60000;
int theID = theDoc.AddImageUrl(theUrl);
while (true)
{
if (!theDoc.Chainable(theID)) break;
theDoc.Page = theDoc.AddPage();
theID = theDoc.AddImageToChain(theID);
}
for (int i = 1; i <= theDoc.PageCount; i++)
{
theDoc.PageNumber = i;
theDoc.Flatten();
}
theDoc.Save(location);
theDoc.Clear();
내가 테스트를 위해 사용하고 HTML 페이지는 이것이다 : 그래서
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><title>Test page</title></head>
<body>
<p>This is a local image</p>
<img src="http://myserver/test/images/testimage.gif" />
<p>This is a remote image</p>
<img src="http://l.yimg.com/a/i/ww/beta/y3.gif" />
</body>
</html>
나는의 페이지를 렌더링하기 위해 노력하고있어 이 URL : http://myserver/test/testpage.html (위의 코드)을 pdf로 가져 오십시오.
IIS6에서 두 번째 이미지 (서버에서는 로컬이 아님)는 pdf에 표시되지 않습니다.
액세스 권한에 문제가있는 것 같지만 이해할 수 없습니다.
감사합니다.
문제점의 해결책 찾기 – sptremblay
아니요. 어쨌든 프로젝트는 중단되었습니다 ... – Paul