02Geek HTML5 and JavaScript, TypeScript, React, Flash, ActionScript online School
Previous VideoNext Video

Publish Settings Recap

The first step to write a program is to create a file in which the code is to be written. Normally, when you are dealing with Flash, you can see the menu section CREATE FILE. In this section, you can find various file types but remember to click on Flash File (Action Script 3.0). Some users might not see the welcome panel when they start. In that case, you must select 'New' from the drop down menu of either Flash or File located at the top left of the window. Remember to select Action Script 3.0 again while selecting the file type in the pop-up window. Now your Flash file is created and you must save it in the source folder before proceeding further. You must always save the file with the .fla extension and don't forget to use the 'save as' option.

Now it is the time to learn about publish settings, but first you must gain some knowledge about different file extensions such as .html and .swf files. However, for now you don't need to go deeply into this – just focus on the publish settings. You can find the option for publish settings, when you click on the File option. When the dialog box is opened for publish settings, you'll see that the Flash and HTML check boxes are checked by default. You will find that Flash files have the .swf extension and HTML have the .html extension. These files are saved in the folder where we previously saved our .fla file: the source folder.

Here we need to change the publish settings because we want the compiled files to be in the deploy folder. This can be performed by typing ../ before the file name for both Flash and html files. Typing these symbols moves the file one folder back without much strain to the user. However, if we want to move the present file to a specific folder directly from publish settings, we must type ../target folder/ before the file name. In most of the cases, the target folder is the deploy folder and hence, typing ../deploy/ before main.swf will move the main.swf file to the deploy folder.

Learning how to work with the publish settings is not of a step necessary for every programing language: other languages such as javascript don't even need them. This step is focused on getting you aware of the work flow in Flash rather than a general step in programing.

Video Transcript

00:00your interface might look a little bit different than mine so I'm going to show
00:03you two ways of getting to create your new AS file. If your panel your welcome
00:09panel is open up and you have the option of creating a new flash file you could
00:14just click on it and it would create a new AS3 file just make sure that
00:18you're creating an AS3 file. If you can't see it try going through your file or
00:25flash really depending on and what's going on here and I don't know why but Apple
00:39sometimes has focusing issues so it's like when you grab the window move it
00:43around and then it remembers that you're in that application. Let's click on file
00:49new and in file new you're going to see an array of options and make sure you're
00:53in the general. We're not interested in the templates right now and we're going
00:57to select flash file action script 3.0. I'm going to click OK. As soon as I click
01:03OK my new flash file is going to be created. We're not going to do anything
01:07inside of our FLA immediately besides saving it. So if I click on file save as
01:14I'm going to go to the directory of my source files which is sitting on my
01:18desktop coding basics source and I'm going to save my FLA and call it main.
01:25Now that I have my FLA saved up I want to make sure that my deployed files
01:32my compiled files are going into the right directory which I wanted to go
01:38into the deploy folder. So if you click on file and we go down to publish
01:43settings in the publish settings we're going to see that flash is by
01:47automatically by default going to publish a flash a SWF and an HTML file
01:54and by default it's going to save it into the same directory where our FLA is.
01:59Currently our FLA is sitting if we look in our source it's sitting in our source
02:04folder so if we don't make any changes to the publish settings our file is
02:09going to be saved our HTML and SWF file are going to be saved into the same
02:13folder but we don't really want that to happen. We want them to be saved into
02:17the deploy folder. For that to happen we're going to go back into our
02:20publish settings and we're going to change the folder path by typing
02:24dot dot slash before our main SWF and again back back slash to our main.html
02:32as well which that will make sure that our SWF when it gets compiled is going to
02:37be published into the folder before the folder it was in but now
02:43that's not really enough because if we look into our folder structure we're
02:46going to see that we're going to save our SWF's into the coding basics folder
02:49where we actually wanted to go into the deploy folder. Now we're going to add
02:54another path we're going to add deploy and a slash again and we're going to do
03:01the same thing for the HTML one and slash and now if we try and publish the
03:07file out if we click on publish and we go back into our folder we're going to
03:12see that our deploy folder now published two files an HTML file and a
03:16SWF file. Now we're not going to work too much or worry about the deploy file
03:20because we're going to work all internally inside of flash in this
03:23video so we're going to jump ahead and continue immediately even though we're
03:27just going to practice this until we get a little bit deeper and understand a
03:30little bit more in the surrounding environment if we don't know it
03:34already. So let's click on OK and now that I clicked OK I'm going to save my
03:40file

Ready to Level Up Your Skills?

Join thousands of learners on 02GEEK and start your journey to becoming a coding expert today!

Enroll Now for Free!