Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5

Thread: Browser wars...

  1. #1
    New Coder
    Join Date
    Jan 2011
    Posts
    51
    Thanks
    18
    Thanked 0 Times in 0 Posts

    Browser wars...

    For some reason the code below will not display in Firefox or Google Chrome but does display in Internet Explorer. (Literally...blank space in FF and Chrome, perfect in IE.) Can anyone tell why?

    Code:
    <table border="0"> <tbody> <tr> <td width="115">*</td> <td align="center"> 
    <table border="0" width="776"> 
    <tbody id="capabilitiesTable"> <tr> <td valign="top"> 
    <div id="capabilityFile" scrolltop="2">
    	<object codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="776" align="absBottom" height="500" valign="bottom"> <param name="wmode" value="transparent" /> 
    	<param name="allowScriptAccess" value="sameDomain" /> <param name="movie" value="/Portals/0/capabilities/capabilities_2013.swf" /> <param name="quality" value="high" /></object>
    </div> 
    </td> </tr> </tbody> 
    </table> 
    </td> <td width="115">*</td> </tr> </tbody> </table> 
    
    <p><input type="hidden" name="VITCoord" value="0" /><input type="hidden" name="PTCoord" value="0" /></p> 
    <script> //--><![CDATA[//>
    <!-- var qsParm = new Array(); 
    qsParm['capabilityId'] = null; 
    qs(); /** 
    alert('qsParm[capabilityId] = ' + qsParm['capabilityId']); 
    if (qsParm['capabilityId'] != null) { alert('qsParm[capabilityId] = ' + qsParm['capabilityId']); 
    } 
    else { 
    alert('qsParm[capabilityId] = ' + 'null'); } */ 
    
    if (qsParm['capabilityId'] == null) { 
    qsParm['capabilityId'] = 'main'; displayCapabilitiesTableNow(qsParm['capabilityId']); 
    } 
    else { displayCapabilitiesTableNow(qsParm['capabilityId']); 
    } 
    
    function displayCapabilitiesTableNow(capabilityId) { 
    if (capabilityId == 'Cyber') { 
    var x = document.getElementById('capabilityFile'); 
    var s = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="776" height="500" hspace="0" vspace="0" align="absbottom" valign="bottom"> <param name="wmode" value="opaque" /> <param name="allowScriptAccess" value="sameDomain" /> <param name="movie" value="/Portals/0/capabilities/practiceCyber_2013.swf" /> <param name="quality" value="high" /><embed src="/Portals/0/capabilities/practiceCyber_2013.swf" width="776" height="500" quality="high" hspace="0" vspace="0" align="absbottom" allowScriptAccess="sameDomain" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" wmode="opaque"><param name="wmode" value="opaque" /></embed></object>'; 
    x.innerHTML = s; 
    } 
    else if (capabilityId == 'Enterprise') { 
    var x = document.getElementById('capabilityFile'); 
    var s = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="776" height="500" hspace="0" vspace="0" align="absbottom" valign="bottom"> <param name="wmode" value="opaque" /> <param name="allowScriptAccess" value="sameDomain" /> <param name="movie" value="/Portals/0/capabilities/practiceEnterpriseSoft_2013.swf" /> <param name="quality" value="high" /><embed src="/Portals/0/capabilities/practiceEnterpriseSoft_2013.swf" width="776" height="500" quality="high" hspace="0" vspace="0" align="absbottom" allowScriptAccess="sameDomain" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" wmode="opaque"><param name="wmode" value="opaque" /></embed></object>'; 
    x.innerHTML = s; 
    } 
    else if (capabilityId == 'HLT') { 
    var x = document.getElementById('capabilityFile'); 
    var s = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="776" height="500" hspace="0" vspace="0" align="absbottom" valign="bottom"> <param name="wmode" value="opaque" /> <param name="allowScriptAccess" value="sameDomain" /> <param name="movie" value="/Portals/0/capabilities/practiceHumanLang_2013.swf" /> <param name="quality" value="high" /><embed src="/Portals/0/capabilities/practiceHumanLang_2013.swf" width="776" height="500" quality="high" hspace="0" vspace="0" align="absbottom" allowScriptAccess="sameDomain" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" wmode="opaque"><param name="wmode" value="opaque" /></embed></object>'; 
    x.innerHTML = s; 
    } 
    else if (capabilityId == 'PM') { 
    var x = document.getElementById('capabilityFile'); 
    var s = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="776" height="500" hspace="0" vspace="0" align="absbottom" valign="bottom"> <param name="wmode" value="opaque" /> <param name="allowScriptAccess" value="sameDomain" /> <param name="movie" value="/Portals/0/capabilities/practicePM_2013.swf" /> <param name="quality" value="high" /><embed src="/Portals/0/capabilities/practicePM_2013.swf" width="776" height="500" quality="high" hspace="0" vspace="0" align="absbottom" allowScriptAccess="sameDomain" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" wmode="opaque"></embed><param name="wmode" value="opaque" /></object>'; 
    x.innerHTML = s; 
    } 
    else if (capabilityId == 'RealTime') { 
    var x = document.getElementById('capabilityFile'); 
    var s = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="776" height="500" hspace="0" vspace="0" align="absbottom" valign="bottom"> <param name="wmode" value="opaque" /> <param name="allowScriptAccess" value="sameDomain" /> <param name="movie" value="/Portals/0/capabilities/practiceRealTime_2013.swf" /> <param name="quality" value="high" /><embed src="/Portals/0/capabilities/practiceRealTime_2013.swf" width="776" height="500" quality="high" hspace="0" vspace="0" align="absbottom" allowScriptAccess="sameDomain" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" wmode="opaque"><param name="wmode" value="opaque" /></embed> </object>'; x.innerHTML = s; 
    } 
    else if (capabilityId == 'Requirements') { 
    var x = document.getElementById('capabilityFile'); 
    var s = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="776" height="500" hspace="0" vspace="0" align="absbottom" valign="bottom"> <param name="wmode" value="opaque" /> <param name="allowScriptAccess" value="sameDomain" /> <param name="movie" value="/Portals/0/capabilities/practiceReqMan_2013.swf" /> <param name="quality" value="high" /><embed src="/Portals/0/capabilities/practiceReqMan_2013.swf" width="776" height="500" quality="high" hspace="0" vspace="0" align="absbottom" allowScriptAccess="sameDomain" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" wmode="opaque"><param name="wmode" value="opaque" /></embed> </object>'; x.innerHTML = s; 
    } 
    else if (capabilityId == 'Support') { 
    var x = document.getElementById('capabilityFile'); 
    var s = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="776" height="500" hspace="0" vspace="0" align="absbottom" valign="bottom"> <param name="wmode" value="opaque" /> <param name="allowScriptAccess" value="sameDomain" /> <param name="movie" value="/Portals/0/capabilities/practiceSoftSup_2013.swf" /> <param name="quality" value="high" /><embed src="/Portals/0/capabilities/practiceSoftSup_2013.swf" width="776" height="500" quality="high" hspace="0" vspace="0" align="absbottom" allowScriptAccess="sameDomain" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" wmode="opaque"><param name="wmode" value="opaque" /></embed> </object>'; x.innerHTML = s; 
    } 
    else if (capabilityId == 'Deployment') { 
    var x = document.getElementById('capabilityFile'); 
    var s = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="776" height="500" hspace="0" vspace="0" align="absbottom" valign="bottom"> <param name="wmode" value="opaque" /> <param name="allowScriptAccess" value="sameDomain" /> <param name="movie" value="/Portals/0/capabilities/practiceSysInt_2013.swf" /> <param name="quality" value="high" /><embed src="/Portals/0/capabilities/practiceSysInt_2013.swf" width="776" height="500" quality="high" hspace="0" vspace="0" align="absbottom" allowScriptAccess="sameDomain" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" wmode="opaque"><param name="wmode" value="opaque" /></embed> </object>'; x.innerHTML = s; 
    } 
    else if (capabilityId == 'Web') { 
    var x = document.getElementById('capabilityFile'); 
    var s = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="776" height="500" hspace="0" vspace="0" align="absbottom" valign="bottom"> <param name="wmode" value="opaque" /> <param name="allowScriptAccess" value="sameDomain" /> <param name="movie" value="/Portals/0/capabilities/practiceWebTech_2013.swf" /> <param name="quality" value="high" /><embed src="/Portals/0/capabilities/practiceWebTech_2013.swf" width="776" height="500" quality="high" hspace="0" vspace="0" align="absbottom" allowScriptAccess="sameDomain" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" wmode="opaque"><param name="wmode" value="opaque" /></embed> </object>'; x.innerHTML = s; 
    } 
    else if (capabilityId == 'main') { 
    var x = document.getElementById('capabilityFile'); 
    var s = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="776" height="500" hspace="0" vspace="0" align="absbottom" valign="bottom"> <param name="wmode" value="opaque" /> <param name="allowScriptAccess" value="sameDomain" /> <param name="movie" value="/Portals/0/capabilities/capabilities_2013.swf" /> <param name="quality" value="high" /><embed src="/Portals/0/capabilities/capabilities_2013.swf" width="776" height="500" quality="high" hspace="0" vspace="0" align="absbottom" allowScriptAccess="sameDomain" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" wmode="opaque"><param name="wmode" value="opaque" /></embed> </object>'; x.innerHTML = s; 
    } 
    } 
    function qs() { 
    var query = window.location.search.substring(1); 
    var parms = query.split('&'); 
    for ( var i = 0; i < parms.length; i++) { 
    var pos = parms[i].indexOf('='); 
    if (pos > 0) { 
    var key = parms[i].substring(0, pos); 
    var val = parms[i].substring(pos + 1); 
    qsParm[key] = val; 
    } 
    } 
    } //--><!]]> 
    </script>
    Edit: I can even give you the URL: http://proobject.com/Capabilities/ta...6/Default.aspx
    Last edited by hunter1611; 09-09-2013 at 08:47 PM.

  • #2
    Senior Coder Dormilich's Avatar
    Join Date
    Jan 2010
    Location
    Behind the Wall
    Posts
    3,280
    Thanks
    12
    Thanked 342 Times in 338 Posts
    The computer is always right. The computer is always right. The computer is always right. Take it from someone who has programmed for over ten years: not once has the computational mechanism of the machine malfunctioned.
    André Behrens, NY Times Software Developer

  • #3
    New Coder
    Join Date
    Jan 2011
    Posts
    51
    Thanks
    18
    Thanked 0 Times in 0 Posts
    I think that script file has something to do with the CMS being used..and I can't really touch it. (had the website dropped on me so still learning to navigate it)

  • #4
    Supreme Master coder! Old Pedant's Avatar
    Join Date
    Feb 2009
    Posts
    25,438
    Thanks
    75
    Thanked 4,372 Times in 4,337 Posts
    You have this code:
    Code:
    <!-- var qsParm = new Array(); 
    qsParm['capabilityId'] = null; 
    qs();
    And you are getting an error that qsParm is not defined.

    Reason: The <!-- is indeed "hiding" the var declaration, but then it does *NOT* hide the next line!

    This kind of coding, trying to hid JavaScript with <!-- is totally bogus. Not to mention it went out of style when MSIE version 3 (yes *THREE*) died, back about 1997.

    Note: You get the same error in MSIE, so I'm not sure why the results are then different. But start by fixing that code.
    An optimist sees the glass as half full.
    A pessimist sees the glass as half empty.
    A realist drinks it no matter how much there is.

  • Users who have thanked Old Pedant for this post:

    hunter1611 (09-09-2013)

  • #5
    New Coder
    Join Date
    Jan 2011
    Posts
    51
    Thanks
    18
    Thanked 0 Times in 0 Posts
    Annnd that's all it took. Thank you!


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •