texte = --047d7b5da5bbe4056d04e247f8b5Content-Type: text/plain; charset=UTF-8Stuart,Hi - last post on this I promise. I just got there using a [shell] scriptas you were suggesting. Final code is below, could be useful for anysituation where an image needs to be stored in a template.- Tom[!][/!][!]------------------------------------### Do processing stuff here ###[/!][!]------------------------------------ ### Check for image and serve it out here ###[/!][showif [fileinfo file=blank.gif][exists][/fileinfo]=F][!][/!][text]blank-gif-base64=R0lGODlhAQABAIAAAP///wAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==[/text][!] [/!][writefile file=blank.gif][shell]echo [blank-gif-base64] | base64--decode[/shell][/writefile][!][/!][/showif][!][/!][text]crlf=[unurl]%0D%0A[/unurl][/text][!][/!][returnRaw binarybody=blank.gif]HTTP/1.0 200 OK[crlf][!][/!]Status: 200[crlf][!][/!]Content-Type: image/gif[crlf][crlf][!][/!][/returnraw]--047d7b5da5bbe4056d04e247f8b5Content-Type: text/html; charset=UTF-8Content-Transfer-Encoding: quoted-printable
Stuart,
Hi - last post on this I promis=e. =C2=A0 I just got there using a [shell] script as you were suggesting. ==C2=A0 Final code is below, could be useful for any situation where an imag=e needs to be stored in a template.
- Tom
[!]<!-- HAS_=WEBDNA_TAGS -->
[/!][!]
=------------------------=------------
### =C2=A0Do process=ing stuff here =C2=A0###
[/!][!]
=
-----------------------------------=-
### =C2=A0Check for image and serve it out he=re =C2=A0###
[/!][showif [fileinfo= file=3Dblank.gif][exists][/fileinfo]=3DF][!]
[/!][text]blank-gif-base64=3DR0lGODlhAQABAIAAAP///wAAACH5BAE=AAAAALAAAAAABAAEAAAICRAEAOw=3D=3D[/text][!]
[/!][writefile file=3Dblank.gif][shell]echo [=blank-gif-base64] | base64 --decode[/shell][/writefile][!]
[/!][/showif][!]=div>
[/!][text]crlf=3D[unurl]%=0D%0A[/unurl][/text][!]
[/!][ret=urnRaw binarybody=3Dblank.gif]HTTP/1.0 200 OK[crlf][!]
[/!]Status: 200[crlf][!]=div>
[/!]Content-Type: image/g=if[crlf][crlf][!]
[/!][/re=turnraw]
--047d7b5da5bbe4056d04e247f8b5--
Associated Messages, from the most recent to the oldest:
--047d7b5da5bbe4056d04e247f8b5Content-Type: text/plain; charset=UTF-8Stuart,Hi - last post on this I promise. I just got there using a
[shell] scriptas you were suggesting. Final code is below, could be useful for anysituation where an image needs to be stored in a template.- Tom
[!][/!]
[!]------------------------------------### Do processing stuff here ###[/!]
[!]------------------------------------ ### Check for image and serve it out here ###[/!][showif [fileinfo file=blank.gif][exists][/fileinfo]=F]
[!][/!]
[text]blank-gif-base64=R0lGODlhAQABAIAAAP///wAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==[/text]
[!] [/!][writefile file=blank.gif]
[shell]echo [blank-gif-base64] | base64--decode[/shell][/writefile]
[!][/!][/showif]
[!][/!]
[text]crlf=
[unurl]%0D%0A[/unurl][/text]
[!][/!][returnRaw binarybody=blank.gif]HTTP/1.0 200 OK[crlf]
[!][/!]Status: 200[crlf]
[!][/!]Content-Type: image/gif[crlf][crlf]
[!][/!][/returnraw]--047d7b5da5bbe4056d04e247f8b5Content-Type: text/html; charset=UTF-8Content-Transfer-Encoding: quoted-printable