8 Replies Latest reply on Mar 17, 2010 8:57 AM by GeoBear

    iWeb to Dreamweaver II: JS Question

    GeoBear Level 1

      I'm using Dreamweaver to publish a website created in iWeb to a Linux server and am having a problem with some JavaScript-driven audio files.

       

      Consider the following code:

       

      <div id="id9" style="height: 68px; left: 161px; position: absolute; top: 380px; width: 144px; z-index: 1; " class="style_SkipStroke_2">

                    <div class="text-content graphic_textbox_layout_style_default_External_144_68" style="padding: 0px; ">

                      <div class="graphic_textbox_layout_style_default">

                        <p style="padding-top: 0pt; " class="Free_Form">E Morio<br /></p>

                        <p class="Free_Form">Traditional<br /></p>

                        <p style="padding-bottom: 0pt; " class="Free_Form">Lyrics By Gilberto Gil</p>

                      </div>

                    </div>

                  </div>

                  <div style="height: 120px; left: 45px; position: absolute; top: 532px; width: 102px; z-index: 1; ">

                    <img style="height: 104px; width: 102px; " src="Music_files/sambatuquecoverart_3.jpg" />

                    <script type="text/javascript"><!--

      writeMovie4();

      --></script>

                  </div>

       

      This is the relevant code from the associated JS file:

       

      function writeMovie3()

      {detectBrowser();if(windowsInternetExplorer)

      {document.write('<object id="id8" classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B" codebase="http://www.apple.com/qtactivex/qtplugin.cab" width="102" height="16"><param name="src" value="Media/06%20E%20Morio.mov" /><param name="controller" value="true" /><param name="autoplay" value="false" /><param name="scale" value="tofit" /><param name="volume" value="100" /><param name="loop" value="false" /></object>');}

      else if(isiPhone)

      {document.write('<object id="id8" type="video/quicktime" width="102" height="16"><param name="src" value="Media/06%20E%20Morio.mov"/><param name="controller" value="true"/><param name="scale" value="tofit"/></object>');}

      else

      {document.write('<object id="id8" type="video/quicktime" width="102" height="16" data="Media/06%20E%20Morio.mov"><param name="src" value="Media/06%20E%20Morio.mov"/><param name="controller" value="true"/><param name="autoplay" value="false"/><param name="scale" value="tofit"/><param name="volume" value="100"/><param name="loop" value="false"/></object>');}}

       

      In a folder named Media is the file 06 E Morio.mov.

       

      When I view the page Music.html locally, I see the standard graphic that's displayed with audio files - a horizontal, metallic-colored thing with a button you can push to start the audio and a little button that slowly moves to the right until the song is finished. But when I view the page online, I don't see anything.

       

      I tried renaming the audio file to 06_E_Morio.mov (replacing spaces with underscores), then replaced every instance of %20 in the JS file code with an underscore as well. But that killed it locally.

       

      I had a lot of problems with links that included capital letters and therefore didn't match with images or JS files that were all lower case. Thus, I'm guessing this problem has to do with either some value that should or should not have a capital letter and/or a space issue - either I need to replace %20 with underscores, or I need to insert underscores in the names of the audio files, etc.

       

      Can anyone offer any suggestions?

       

      Thank you.