Printing plain/preformatted html code

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Printing plain/preformatted html code

Ole Voß
Hi all,

I am interfacing two applications, one written in perl and one in smalltalk. I need to read and output already formatted html code (written to the filesystem by the perl code) using the smalltalk and seaside. I have all the code for finding the file and reading the html-text, unfortunately I can't find a way to output this plain html using seaside. Obviously this won't work:

html text: myhtmlfilecontents.

Scanning WAHtmlCanvas didn't bring up anything either.

Can somebody point me in the right direction?

Thank & many regards,

Ole._______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Printing plain/preformatted html code

Philippe Marschall
2009/11/28 Ole Voß <[hidden email]>:
> Hi all,
>
> I am interfacing two applications, one written in perl and one in smalltalk. I need to read and output already formatted html code (written to the filesystem by the perl code) using the smalltalk and seaside. I have all the code for finding the file and reading the html-text, unfortunately I can't find a way to output this plain html using seaside. Obviously this won't work:
>
> html text: myhtmlfilecontents.
>
> Scanning WAHtmlCanvas didn't bring up anything either.
>
> Can somebody point me in the right direction?

If you just want to output a some HTML without escaping you can use:
html html: myhtmlfilecontents

If you have a full HTML document you can try something along the lines of:

self session returnResponse: (WAResponse new
                contentType: 'text/html;
                nextPutAll: myhtmlfilecontents;
                yourself)

Cheers
Philippe
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Printing plain/preformatted html code

Ole Voß
Great, that helped.

Thank you!

On Nov 28, 2009, at 12:29 PM, Philippe Marschall wrote:

> 2009/11/28 Ole Voß <[hidden email]>:
>> Hi all,
>>
>> I am interfacing two applications, one written in perl and one in smalltalk. I need to read and output already formatted html code (written to the filesystem by the perl code) using the smalltalk and seaside. I have all the code for finding the file and reading the html-text, unfortunately I can't find a way to output this plain html using seaside. Obviously this won't work:
>>
>> html text: myhtmlfilecontents.
>>
>> Scanning WAHtmlCanvas didn't bring up anything either.
>>
>> Can somebody point me in the right direction?
>
> If you just want to output a some HTML without escaping you can use:
> html html: myhtmlfilecontents
>
> If you have a full HTML document you can try something along the lines of:
>
> self session returnResponse: (WAResponse new
> contentType: 'text/html;
> nextPutAll: myhtmlfilecontents;
> yourself)
>
> Cheers
> Philippe
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside