Hey Alexander Lamb -
>First message to this list... getting back to development after some
>time (previously NeXT / WebObjects :-).
[ah, yes. the gold old days :-]
> 1) figure out what url to give
In the calling (~generated) .html - the link to the flash goes something like ..
http://mahost/mycharting.swf?url=/blahcontext/app?service=page&page=MyChartXML&id=6654321
(The flash/swf just grabs the "url" arg from the querystring in the
ActionScript code, and performs ~GET to request the xml.)
> 2) figure how to return XML data instead of HTML
I think the key is to implement this on MyChartXML.java
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
public ContentType getResponseContentType() {
return new ContentType("text/xml");
}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The MyChartXML.html file .. is vanilla:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
<?xml version="1.0" encoding="ISO-8859-1"?>
<goo>
...
</goo>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
MyChartXML.page is ordinary too.
Cheers,
-Matt
On Wednesday, April 18, 2007, at 03:24AM, "Alexander Lamb" <[EMAIL PROTECTED]>
wrote:
>Hello list,
>
>First message to this list... getting back to development after some
>time (previously NeXT / WebObjects :-).
>
>I am currently developping a Tapestry 4.1 / Cayenne app. Works fine.
>
>Now, I would like to add some Flex components to my HTML page. The
>first attempt is to add charting to my app.
>
>The ideal would be to create a Tapestry component which integrates my
>swf chart. The problem I have is:
>
>- if my chart is getting populated by a HTTPService with XML data, I
>need to:
>
> 1) figure out what url to give
> 2) figure how to return XML data instead of HTML
>
>For point 2, in the target function being called, in WebObjects I
>would have overriden "appendToResponse". I am not certain how to do
>this in Tapestry.
>For point 1, I don't really know what url to pass to the Flex
>component in order to be certain I am staying in my session (visit)
>and calling the correct function in my tapestry component.
>
>Are there some examples somewhere?
>
>Thanks,
>
>Alex
>--
>Alexander Lamb
>Founding Associate
>RODANOTECH Sàrl
>
>26 ch des Tattes
>1222 Vésenaz
>
>Fax: 022 855 06 14
>
>www.rodanotech.ch
>
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]