`

flex如何通过jsp访问数据库

阅读更多

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" backgroundGradientColors="[#ffffff, #ffffff]" initialize="init();" paddingBottom="10" paddingLeft="10" paddingRight="10" paddingTop="10" horizontalAlign="center" fontFamily="Arial">

    <mx:Script>
        <![CDATA[
            import mx.rpc.http.HTTPService;
            import mx.controls.Alert;
            import mx.rpc.events.ResultEvent;

            private function init() : void
            {
                var feedRequest : HTTPService = new HTTPService();
                feedRequest.url = "http://rss.cnn.com/rss/money_news_economy.rss";
               
                feedRequest.addEventListener(ResultEvent.RESULT,
                    function (event : ResultEvent) : void
                    {
                        Alert.show(event.result.rss.channel.title);
                    }
                )
               
                feedRequest.send();
            }
        ]]>
    </mx:Script>
   
</mx:Application>

本文转自: http://www.riachina.com/showtopic-6635.html

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics