Thanks Bill and Tom for your suggestions !
But the real reason was that I had forgot to put <@purgeresults>
before <@var request$tiff encoding=none> at the last call.

There is no need for Content-Length header to make it work.


Cheers

Bengt Bredin
-----------------------------------------------------------------------
LabIT Solutions AB
Fagerstagatan 18 A
163 94 Stockholm
SWEDEN
mail : [EMAIL PROTECTED]
-----------------------------------------------------------------------

-----Ursprungligt meddelande-----
Fr�n: Bill Conlon [mailto:[EMAIL PROTECTED] 
Skickat: den 2 april 2004 19:26
Till: Witango-Talk
�mne: Re: Witango-Talk: http and tiff image

I see you aren't using the Content-Length header, but one problem can be

caused if the content-length is incorrect.  I'm speculating that the 
problem I've seen is caused when the source file is uploaded into the db

using some MacOS9 browsers.  (I think it must insert an extra Carriage 
Return or Line Feed).  Anyway if you download one of these problem
files, 
(save target as) you see the file length being one byte less than 
recorded during the upload.  If it's re-uploaded using a different 
browser, such as OS X Mozilla os XP IE, the problem disappears, and the 
length of the uploaded file is now one byte less. 

>Hey list !
>
>I' am struggling with a http problem 'again'. 
>I'll  bring out an tiff blob from the db and put it into
>
>
><@ASSIGN request$tiff '@@request$resultSet[1,data]'>
> 
>then set up the http (yes it's one row)
> 
><@assign request$encodeResults false>
><@ASSIGN request$httpHeader "HTTP/1.1 <@HTTPSTATUSCODE>
><@HTTPREASONPHRASE> <@crlf>
>Date: <@CURRENTTIMESTAMP FORMAT='datetime:http'><@crlf>Server: Witango
><@version> <@crlf>
>MIME-Version: 1.0<@crlf>Content-Type: image/tiff<@crlf><@crlf>">
> 
>And then calls 
>
>
><@var request$tiff encoding=none>
> 
>The Imaging software starts up in the browser alright but I get the
>error:
>Can't open the document. The document format is not supported !!!
>
>If I first get it out from the db and stores it as a file and through
>the browser open the file its works, so it's stored correctly in the
db.
>The size of the blob or file is 21569 bytes.
>
>I use the same procedure for pdf files with Content-Type:
>application/pdf and it works fine.
>I have tried the HTTPLook but I can't se any problem.
>
>
>//W2K, SQL Server 2K, IIS, Witango 5.0 (049), Witango 5.0 Studio//
>
>
>Any ideas ?
> 
> 
>Cheers
>
>Bengt Bredin
>-----------------------------------------------------------------------
>LabIT Solutions AB
>Fagerstagatan 18 A
>163 94 Stockholm
>SWEDEN
>mail : [EMAIL PROTECTED]
>-----------------------------------------------------------------------
> 
>
>_______________________________________________________________________
_
>TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf


Bill Conlon

To the Point
345 California Avenue Suite 2
Palo Alto, CA 94306

office: 650.327.2175
fax:    650.329.8335
mobile: 650.906.9929
e-mail: mailto:[EMAIL PROTECTED]
web:    http://www.tothept.com


________________________________________________________________________
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf

________________________________________________________________________
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf

Reply via email to