Solved

Flash and Netscape 7+

Posted on 2003-10-21
11
229 Views
Last Modified: 2010-04-03
I'm having trouble with my Flash site in NN7+.

On Windows, the site opens really, really, really small in its window. It should fill it - or at least be bigger! Seems to be okay in IE.

On Mac, I get nothing. A window opens and I see the background color, but no Flash. It does seem to work okay in Safari and IE.

Thanks for the help!

0
Comment
Question by:jtlyonsden
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 3
11 Comments
 
LVL 27

Expert Comment

by:negatyve
ID: 9595792
Could you post here the embedding html code?
0
 

Author Comment

by:jtlyonsden
ID: 9596072
I've implemented the IE browser fix that's been going around, so my embed text is in three places:

This is the EXTERNAL javascript file (browserFix.js):
function browserFix() {
      document.write('<object classid="clsid:000000" codebase="http://download.macromedia.com/pub/ shockwave/cabs/flash/swflash.cab#version=6,0,0,0" id="movie" width="100%" height="100%" align="top">\n');
      document.write('<param name="allowScriptAccess" value="sameDomain" />\n');
      document.write('<param name="movie" value="movie.swf" />\n');
      document.write('<param name="loop" value="false" />\n');
      document.write('<param name="menu" value="false" />\n');
      document.write('<param name="quality" value="high" />\n');
      document.write('<param name="salign" value="t" />\n');
      document.write('<param name="bgcolor" value="#666699" />\n');
      document.write('<embed src="movie.swf" loop="false" menu="false" quality="high" salign="t" bgcolor="#666699" width="100%" height="100%" swLiveConnect=true id="movie" name="movie" align="top" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />\n');
      document.write('</object>\n');
}

This is in the <HEAD> section of the page:
<script src="browserFix.js" language="JavaScript" type="text/javascript"></script>

This is in the <BODY> section of the page:
<script language="JavaScript" type="text/javascript">
      browserFix();
</script>

This works the same as it did before I "fixed" it in IE. It's never worked in Netscape, even before I implemented the "fix."

Thanks for taking a look.
0
 
LVL 27

Expert Comment

by:negatyve
ID: 9597227
Tested with these browser on pc, and always looked as expected :

Opera 7.11
Internet Explorer 6.0.28
Netscape Navigator 7.01
Netscape Navigator 6.0
Netscape(R) Communicator 4.51
Mozilla 1.4

This is a browser, not javascript, problem. Is your Netscape 7 for Mac plugin updated?
0
Instantly Create Instructional Tutorials

Contextual Guidance at the moment of need helps your employees adopt to new software or processes instantly. Boost knowledge retention and employee engagement step-by-step with one easy solution.

 

Author Comment

by:jtlyonsden
ID: 9599439
You asked for it! Here are the two functions that create the HTML text. "_global.transformXML" is called from the click of the "printer-friendly" button. The second function ("replaceChars") replaces all quotes with &quot and all single quotes with \'.

The thing that has really perplexed me is that if I do a trace on the variable "theseItems" and copy and paste the output directly into the javascript statement "window.document.write("HTML text...");", it works. Thanks again.

I know I could just use single quotes instead of all the escape characters, but I was trying everything to get this fixed.

_global.transformXML = function() {
      var theseItems:String = "<html><head>";
      // define styles
      theseItems += "<style type=\\\"text/css\\\">\\n";
      theseItems += "body {font-family:Arial, Helvetica, sans-serif; white-space:none;}\\n";
      theseItems += "div.headline {font-weight:bold; font-size:20px}\\n";
      theseItems += "div.subhead {font-weight:bold; font-size:16px}\\n";
      theseItems += "div.paragraph {font-size:12px;}\\n";
      theseItems += "div.boldParagraph {font-size:12px; font-weight:bold;}\\n";
      theseItems += "div.bullets {font-size:10px;}\\n";
      theseItems += "div.caption {font-size:9px;}\\n";
      theseItems += "</style>\\n";
      theseItems += "<title>Prism Software Corporation</title></head><body>";
      // set this for bulleted list (only one set of <ul> tags)
      var bulletFlag:Boolean = false;
      //
      for (i=0; i<=_global.arrItemsXML.length; i++) {
            switch (_global.arrLabelsXML[i]) {
            case "headline" :
                  theseItems += "<hr>\\n";
                  theseItems += "<!-- HEADLINE -->\\n";
                  theseItems += "<div class=\\\"headline\\\">";
                  theseItems += replaceChars(_global.arrItemsXML[i]);
                  theseItems += "</div><br>\\n";
                  break;
            case "subhead" :
                  theseItems += "<!--SUBHEADING-->\\n";
                  theseItems += "<br><div class=\\\"subhead\\\">";
                  theseItems += replaceChars(_global.arrItemsXML[i]);
                  theseItems += "</div><br>\\n";
                  break;
            case "paragraph" :
                  theseItems += "<!-- PARAGRAPH -->\\n";
                  theseItems += "<div class=\\\"paragraph\\\">";
                  theseItems += replaceChars(_global.arrItemsXML[i]);
                  theseItems += "</div><br>\\n";
                  if (_global.arrLabelsXML[i+1] == "paragraph") {
                        theseItems += "<br>";
                  }
                  break;
            case "boldParagraph" :
                  theseItems += "<!-- BOLD PARAGRAPH -->\\n";
                  theseItems += "<div class=\\\"boldParagraph\\\">";
                  theseItems += replaceChars(_global.arrItemsXML[i]);
                  theseItems += "</div><br>\\n";
                  break;
            case "bullets" :
                  thisBullet = replaceChars(_global.arrItemsXML[i]);
                  if (bulletFlag == false) {
                        theseItems += "<!-- BULLETS -->\\n";
                        theseItems += "<div class=\\\"bullets\\\">";
                        theseItems += "<ul>";
                        theseItems += "<li>"+thisBullet+"</li>";
                        //if only one bullet
                        if (_global.arrLabelsXML[i+1] != "bullets") {
                              theseItems += "</ul>";
                              bulletFlag = false;
                        } else {
                              bulletFlag = true;
                        }
                  } else if (_global.arrLabelsXML[i+1] == "bullets" && bulletFlag == true) {
                        theseItems += "<li>"+thisBullet+"</li>";
                  } else {
                        theseItems += "<li>"+thisBullet+"</li>";
                        theseItems += "</ul>";
                        theseItems += "</div>\\n";
                        bulletFlag = false;
                  }
                  break;
            case "caption" :
                  theseItems += "<br>";
                  theseItems += "<!-- CAPTION -->\\n";
                  theseItems += "<div class=\\\"caption\\\">";
                  theseItems += replaceChars(_global.arrItemsXML[i]);
                  theseItems += "</div><br>\\n";
                  break;
            }
      }
      theseItems += "</body></html>";
      //trace(theseItems);
      getURL("javascript:openPrinterFriendly(\""+theseItems+"\")");
};
// replace " with &quot and ' with \' for proper display
replaceChars = function (thisText) {
      arrParsedText = new Array();
      newText = new String();
      //
      // replace quotes
      //
      arrParsedText = thisText.split("\"");
      if (arrParsedText.length>1) {
            for (j=0; j<arrParsedText.length-1; j++) {
                  newText += arrParsedText[j]+"&quot;";
                  lastOne = j;
            }
            newText += arrParsedText[lastOne+1];
            thisText = newText;
      }
      //
      // replace apostophes
      //
      arrParsedText = thisText.split("\'");
      if (arrParsedText.length>1) {
            newText = "";
            for (j=0; j<arrParsedText.length-1; j++) {
                  newText += arrParsedText[j]+"\\\'";
                  lastOne = j;
            }
            newText += arrParsedText[lastOne+1];
            thisText = newText;
      }
      return thisText;
};
0
 

Author Comment

by:jtlyonsden
ID: 9599444
Sorry, I pasted that message into the wrong problem!
0
 
LVL 27

Expert Comment

by:negatyve
ID: 9605295
ok, what about "this" problem?
0
 

Author Comment

by:jtlyonsden
ID: 9607523
Well, I made sure I was using the latest version of Netscape on my Windows machine and Mac (7.1). Now I have the same problem with both that I was having in Windows - the Flash movie opens really small within the window (which is the correct size). I have a javascript that is called from a couple of buttons in my movie to allow the user to enlarge the window. This works on the actual window, but the content continues to appear really small (about 20% of actual size).

I imagine something has changed in 7.1 in regard to embedded content, but I haven't had the time to look at anything yet. I noticed that you tested in 7.01 - know anything new about 7.1?

Thanks.
0
 

Author Comment

by:jtlyonsden
ID: 9675504
I finally figured out what the problem was. NN 7.1 does not like percentages for width and height. As soon as I changed the values to pixels, my movie opened just fine.

This makes it harder to do my dynamic window sizing, but I'm sure I'll figure out a work around.
0
 

Author Comment

by:jtlyonsden
ID: 12160664
Solved the problem myself. Close the question.
0
 
LVL 1

Accepted Solution

by:
Computer101 earned 0 total points
ID: 12185985
PAQed, with points refunded (250)

Computer101
E-E Admin
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes a solution to a problem of subloading one movie into another when they have different SWF versions. Sometime back, I was working on an ActionScript project while I came across an interesting fact which I would like to share…
I have been doing hardcore actionscripting for some time; and needless to say I have faced a lot of problems in just understanding others' code rather than understanding what the code executes. A programmer's life can become hell when there are a lo…
The goal of the tutorial is to teach the user how to live broadcast using Flash Media Live Encoder and connecting it to YouTube to broadcast. Log into your Youtube account, choose live stream settings, start live stream from Flash Media Live Enc…
This Micro Tutorial will teach to how to utilize bit rate in Adobe Flash Media Live Encoder.

710 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question