13 Replies Latest reply on Aug 22, 2011 12:03 PM by Jay_Armstrong

    Button file opens in saved location, but won't open in new location.

    swydell$$ Level 1

      I created a simple button that displays an error messeage: "error opening 'url" when I test the movie, but does play and opens in browser after publishing. However, it won't open in the browser in a different location. I pasted the html code in a web page but it doesn't work there nor opens in the browser in a differnet location from where it was originally published and saved. Why is that?

        • 1. Re: Button file opens in saved location, but won't open in new location.
          Ned Murphy Adobe Community Professional & MVP

          It is hard to understand what you have tried to explain.  If you used code for a button, show the code and explain what about that code does not work as expected.  If you are having some kind of problem testing with a browser, you should test using a server.

          • 2. Re: Button file opens in saved location, but won't open in new location.
            swydell$$ Level 1

            This is the code that was automatically created when I published it in Flash:<div id="flashContent">
                        <object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="468" height="60" id="Banner" align="middle">
                            <param name="movie" value="Banner.swf" />
                            <param name="quality" value="high" />
                            <param name="bgcolor" value="#ffffff" />
                            <param name="play" value="true" />
                            <param name="loop" value="false" />
                            <param name="wmode" value="window" />
                            <param name="scale" value="showall" />
                            <param name="menu" value="true" />
                            <param name="devicefont" value="false" />
                            <param name="salign" value="" />
                            <param name="allowScriptAccess" value="sameDomain" />
                            <!--[if !IE]>-->
                            <object type="application/x-shockwave-flash" data="Banner.swf" width="468" height="60">
                                <param name="movie" value="Banner.swf" />
                                <param name="quality" value="high" />
                                <param name="bgcolor" value="#ffffff" />
                                <param name="play" value="true" />
                                <param name="loop" value="false" />
                                <param name="wmode" value="window" />
                                <param name="scale" value="showall" />
                                <param name="menu" value="true" />
                                <param name="devicefont" value="false" />
                                <param name="salign" value="" />
                                <param name="allowScriptAccess" value="sameDomain" />
                            <!--<![endif]-->
                                <a href="http://www.adobe.com/go/getflash">
                                    <img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" />
                                </a>
                            <!--[if !IE]>-->
                            </object>
                            <!--<![endif]-->
                        </object>
                    </div>

            I mistakenly called it a button, sorry about that. This banner opens where it was originally saved when it was published in Flash CS5, as3. Yet, when I moved it to my desk top it wouldn't open. I wanted to it to open in a web page I created. But it wouldn't do either, open there nor on the desk top. It wouldn't test either when I tested the movie in Flash. But it would play. Strange. Now, how would I open it in the server that you mentioned?

            • 3. Re: Button file opens in saved location, but won't open in new location.
              Ned Murphy Adobe Community Professional & MVP

              Make sure you have any supporting files loaded with the file.  If you look in the html page it probably specifies a javascript file that needs to be planted per whatever path is specified.  If your file happens to load other file, then targeting those files needs to be done as if the swf is in the same folder as the html page that loads it.

              • 4. Re: Button file opens in saved location, but won't open in new location.
                swydell$$ Level 1

                There is no other files. The html for the banner is the only file, unless you're referring to the as3 file. Like I said, the banner movie plays when I open it where it was originally saved. When I moved the html file of the banner to another location it wouldn't play. But I kind of see your point now. No matter what I need to keep all the files in the same folder for the banner to work. That's why it plays where it was originally saved with the as3 file. Is that what you mean? But what about it not testing when I test the movie? I get the error message that I stated earlier. Some of my as3 movies test, others do not. But they all play. What makes the difference?

                • 5. Re: Button file opens in saved location, but won't open in new location.
                  Ned Murphy Adobe Community Professional & MVP

                  For the page you tested that works okay when you view it, look in the head section of the html.  Is there a javascript file specified?  If so, that's the javascript file I was talking about.

                  • 6. Re: Button file opens in saved location, but won't open in new location.
                    swydell$$ Level 1

                    I looked and there is no javascript file. I'll send you a html copy and you

                    can see for yourself. But for some weird reason you won't be able to view

                    the source code in Firefox, that's what I got. But you can see it in a html

                    editor program. I made another mistake here. You can view it in Firefox when you view the email I sent you. I'm fascinated by what I'm learning here. I can view the source code in the view option of the email ( I sent one to myself) but from my desktop I can't view the source code of the html file when I open the publish version in Firefox. If that makes sense. It doesn't to me.

                    • 7. Re: Button file opens in saved location, but won't open in new location.
                      ggshow Level 2

                      html is not the only file.

                      you'll need to put your published Banner.swf together with your html.

                      1 person found this helpful
                      • 8. Re: Button file opens in saved location, but won't open in new location.
                        swydell$$ Level 1

                        That was my point. The banner.html and banner.swf were created when I

                        published the banner.fla file. But I still get the 'error opening url 'file'

                        message in the output panel. There is no java script in the file. You can

                        take a look for yourself. Click on the html. Please let me know if you see a

                        solution.

                        • 9. Re: Button file opens in saved location, but won't open in new location.
                          Ned Murphy Adobe Community Professional & MVP

                          You haven't provided anything for anyone to check except for the embedding code you posted earlier.

                          • 10. Re: Button file opens in saved location, but won't open in new location.
                            swydell$$ Level 1

                            My bad. I thought I had sent the complete published file, which was

                            archived.

                            I sent an attachment in gmail, but I don't know how to do that in the forum. I don't see where I can attach files. I thank everybody for their input. I don't see how I can show the problem without presenting the files. I inserted the html code. But that's not the fla file, which is the crux of the problem. It won't test, but ironically it plays.

                            • 11. Re: Button file opens in saved location, but won't open in new location.
                              swydell$$ Level 1

                              Thanks. My whole question was mistated. Actually, I had 2 problems going and I put it into 1 question, which was misleading. The fla opened when I put it in the same folder as the html and swf files. The other part, the fla file doesn't test when I test movie, but it will play. That was the other problem and I'm confused about why it won't test.

                              • 12. Re: Button file opens in saved location, but won't open in new location.
                                Ned Murphy Adobe Community Professional & MVP

                                Maybe you should start over and post separately for each problem.  Your last entry is still confused because you don't play an fla, you play an swf.  You use fla's to create swf's.  An fla doesn't really need to be with any other files unless it is coded to be loading them when you test it.

                                 

                                If you need to show an html page, then you can either paste all the code in your posting or put the file on a server and provide a link to it.

                                • 13. Re: Button file opens in saved location, but won't open in new location.
                                  Jay_Armstrong Level 2

                                  Also, regarding the issue of the SWF not playing in the browser when you move the file to your desktop:

                                   

                                  Remember that since your HTML code only identifies the SWF by its filename, Banner.swf, that means that the SWF must be in the *same folder* as the HTML file. If you move the SWF to the desktop, you must also move the html file.

                                   

                                  Otherwise, the identifier for the SWF file in the HTML code must also provide the path the the SWF, either an absolute path or the path relative to the HTML file's location, e.g."../../myStuff/FlashWork/Banner.swf" or something analogous to that.

                                   

                                  See this TechNote for further explanation: http://kb2.adobe.com/cps/415/tn_4150.html