Developing a website in Flex is actually pretty easy, as far as all the extra files you may not be used to using, your only interested in uploading all the files in the output folder generated when you build projects, this is usually named bin. Upload all those files to your remote server. For the pure basics, the simplest way is to have your main application mxml file as your home page and load in other pages which you create separately as mxml components. You then store each page for your website (which is a separate component) in something like a ViewStack. You navigate through a view stack using a LinkBar component, thats basically the raw nuts and bolts to start, these building blocks will get the site up and running. Code example:
home.mxml: THIS IS THE MAIN WEBSITE PAGE WHICH LOADS INFORMATION PAGE <?xml version="1.0" encoding="utf-8"?> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" xmlns:v = "views.*"> <mx:Style source="assets/css/site.css" /> <mx:ApplicationControlBar width="720" height="110" x="50" y="10"> <mx:HBox> <mx:Image source="assets/images/header.png" /> </mx:HBox> </mx:ApplicationControlBar> <mx:LinkBar dataProvider="{siteContent}" color="#999999" x="65" y="125" /> <mx:Dissolve id="contentTransition" duration="600"/> <mx:ViewStack id="siteContent" x="50" y="150" paddingBottom="0" paddingLeft="0" paddingRight="0" paddingTop="0" resizeToContent="true"> <v:Home id="home" label="Home" showEffect="contentTransition"/> <v:Information id="information" label="Information" showEffect="contentTransition"/> </mx:ViewStack> </mx:Application> information.mxml: HERE IS THE INFORMATION PAGE <?xml version="1.0" encoding="utf-8"?> <mx:VBox xmlns:mx="http://www.adobe.com/2006/mxml" verticalGap="8"> <mx:HBox> <mx:Image source="assets/images/image.jpg" /> <mx:VBox> <mx:Text fontSize="13" width="385" color="#000000"> <mx:text> Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Vivamus interdum elementum urna. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Etiam eget mi. Cras ac quam. Etiam rhoncus laoreet nibh. Proin dapibus. Morbi ultrices vulputate dui. Donec sit amet neque. Aenean lacinia, dui ac pellentesque pellentesque, metus mauris vulputate odio, et pharetra mauris orci at ligula. Nulla mauris sem, faucibus sollicitudin, blandit eget, lobortis a, diam.. </mx:text> </mx:Text> </mx:VBox> </mx:HBox> </mx:VBox> If you want any more pages then just create another component and add it to the view stack... Cheers Simon On 9 Jun 2007, at 18:29, krisda arum wrote: > i developing a website by dreamweaver so long and now i think to > develop a website > by flex,but when i create a website by flex i have so many file > included which not seen in dreamweaver . anybody how method you > work with flex to do a website? > or it a true way to make a information multimedia site by flex? > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Create robust enterprise, web RIAs. Upgrade & integrate Adobe Coldfusion MX7 with Flex 2 http://www.adobe.com/products/coldfusion/flex2/?sdid=RVJP Archive: http://www.houseoffusion.com/groups/Flex/message.cfm/messageid:4213 Subscription: http://www.houseoffusion.com/groups/Flex/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.37
