Use URLUtil : URLUtil « Development « Flex

Home
Flex
1.Chart
2.Components
3.Container
4.Data Model
5.Development
6.Effects
7.Event
8.Graphics
9.Grid
10.Style
Flex » Development » URLUtilScreenshots 
Use URLUtil
           
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" creationComplete="parseURL()">
    <mx:Script>
        
            import mx.utils.ObjectUtil;
            import mx.managers.IBrowserManager;
            import mx.managers.BrowserManager;
            import mx.utils.URLUtil;

            private function parseURL() void
            {
                var bm:IBrowserManager = BrowserManager.getInstance();
                bm.init();

                output.text += "URL Port:" + URLUtil.getPortbm.url "\n";
                output.text += "URL Protocol:" + URLUtil.getProtocolbm.url "\n";
                output.text += "URL Server:" + URLUtil.getServerNamebm.url "\n";
                output.text += "URL Server with Port:" + URLUtil.getServerNameWithPortbm.url );
            }

      
    </mx:Script>

    <mx:TextArea id="output" left="10" top="10" bottom="10" right="10"/>

</mx:Application>

   
    
    
    
    
    
    
    
    
    
    
  
Related examples in the same category
1.Serialize Typed ObjectsSerialize Typed Objects
w__w__w_._j__av_a___2___s.c_o_m | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.