Search Support

Avoid support scams. We will never ask you to call or text a phone number or share personal information. Please report suspicious activity using the “Report Abuse” option.

Learn More

Lolu chungechunge lwabekwa kunqolobane. Uyacelwa ubuze umbuzo omusha uma udinga usizo.

how to open index.html local file if it contains java scripts, css and swf objects?

  • 9 uphendule
  • 1 inale nkinga
  • 221 views
  • Igcine ukuphendulwa ngu James

more options

I try to open a local file index.html, which contains java script, css formatting and swf objects. Tried to enable java in Firefox 59.0 but still nothing. The file is as follows:

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<script type="text/javascript" src="theme/js/index.js"></script>
<script type="text/javascript" src="theme/js/swfobject.js"></script>
<script>
// main variables
cid="1300000000";
lang1="en";
lang2="none";
pseudolocal = "";
// check the url for other variables
getProperties();
setTitle();
</script>
<style type="text/css">
	/* hide from ie on mac \*/
	html {
		height: 100%;
		overflow: hidden;
	}
	
	#flashcontent {
		text-align: center;
		margin-top: 100px;
	}
	/* end hide */

	body {
		height: 100%;
		padding: 0;
		margin-left: 0px;
		margin-top: 0px;
		margin-right: 0px;
		margin-bottom: 0px;
	}


</style>
</head>
<body bgcolor="#ffffff">
<div id="flashcontent">
<script type="text/javascript">
// <![CDATA[
//var so = new SWFObject("theme/index.swf?indextext=courses/en0500000000/launch.text.xml", "index", "800", "450", "8", "#FFFFFF");
var so = new SWFObject("theme/index.swf?indextext=courses/"+lang1+""+cid+"/launch.text.xml&cid="+cid+"&l1="+lang1+"&l2="+lang2, "index", "800", "450", "8", "#FFFFFF");
so.write("flashcontent");
// ]]>
</script>
</div>
</body>
</html>
I try to open a local file index.html, which contains java script, css formatting and swf objects. Tried to enable java in Firefox 59.0 but still nothing. The file is as follows: <pre><nowiki> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <script type="text/javascript" src="theme/js/index.js"></script> <script type="text/javascript" src="theme/js/swfobject.js"></script> <script> // main variables cid="1300000000"; lang1="en"; lang2="none"; pseudolocal = ""; // check the url for other variables getProperties(); setTitle(); </script> <style type="text/css"> /* hide from ie on mac \*/ html { height: 100%; overflow: hidden; } #flashcontent { text-align: center; margin-top: 100px; } /* end hide */ body { height: 100%; padding: 0; margin-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; } </style> </head> <body bgcolor="#ffffff"> <div id="flashcontent"> <script type="text/javascript"> // <![CDATA[ //var so = new SWFObject("theme/index.swf?indextext=courses/en0500000000/launch.text.xml", "index", "800", "450", "8", "#FFFFFF"); var so = new SWFObject("theme/index.swf?indextext=courses/"+lang1+""+cid+"/launch.text.xml&cid="+cid+"&l1="+lang1+"&l2="+lang2, "index", "800", "450", "8", "#FFFFFF"); so.write("flashcontent"); // ]]> </script> </div> </body> </html></nowiki></pre>

Okulungisiwe ngu cor-el

Isisombululo esikhethiwe

Note the JavaScript in Firefox and the Java Plugin from Oracle are two separate things as JavaScript was originally going to be called LiveScript but Java was the new big thing at time. http://kb.mozillazine.org/JavaScript_is_not_Java

Funda le mpendulo ngokuhambisana nalesi sihloko 👍 0

All Replies (9)

more options

HI, All browsers handle java Script. You do not need to enable java or download it. as for the js files maybe, SWF nobody uses it any more. type="text/javascript"> do not need the word text anymore.

If your doing this for a website you need to re think the SWF, will not rank well with google at all.

Please up load your page to the W3C.org (World Wide Web Consortium) in charge of standards and practices and future development of web pages and web browsers make the rules on code. HTML https://validator.w3.org/ CSS https://jigsaw.w3.org/css-validator/

Please let us know if this solved your issue or if need further assistance.

more options

Please uninstall your Flash 27.0 r0 as it is a security issue Flash Player Version: 29.0.0.171 Current Version https://get.adobe.com/flashplayer/otherversions/ Step 1: Select Operating System Step 2: Select A Version (Firefox, . . . .) Note: Other software is offered in the download. <Windows Only>

Please update to Firefox 60 if not there yet : 3Bar Menu -->Help --> About

more options

Thank you for your answers!

The file is part of an old CISCO course. The complete file is attached. Any ideea how can I open the course? Maybe installing an old version of Firefox will do the job?

more options

I think might need java enabled to open the js files.

this index needs to be in a root the .js needs to be in a sub-folder called themes as does the bottom launch.txt.xml If you do not have the files no launch, not in a sub-folder themes no launch

https://www.quora.com/How-do-I-run-a-JavaScript-file is giving Chrome info to run the scripts.

Ctrl+Shift+K will give the Console in Firefox though the Developer Edition might have more tools. https://developer.mozilla.org/en-US/docs/Tools/Web_Console/Opening_the_Web_Console

Truthfully unless wanting to go through the whole course again for 1 page this is a lot of work to go almost no where with it.

Review or go through this : https://www.w3schools.com

So ya....to actually make it work you would have to install java,'

What ever you decide, make sure you do this 1st and always :

more options

Thank you, Pkshadow,

In the mean time I downloaded another tiny browser (Midori) and managed to open the course. Although I'm a fan of Firefox, I feel frustrated with all the problems I'm having with it. On another computer I have a Firefox which keeps crashing from time to time (several times a day), even after uninstalling-reinstalling it, updating and so on... However, you all do a great job in developing this browser. Thank you all.

more options

Welcome. Keep your Video Card Drivers Updated. Do not be afraid to uninstall and reinstall them. Corrupted Video Card Drivers can cause a wide selection of issues.

G'luck with your course.

more options

Hm, you want to say that Video Card Drivers can cause Firefox to crash????!

more options

Note that Firefox blocks Flash from local files (file: protocol is disabled).

You can modify this pref on the about:config page.

  • plugins.http_https_only = false
more options

Isisombululo Esikhethiwe

Note the JavaScript in Firefox and the Java Plugin from Oracle are two separate things as JavaScript was originally going to be called LiveScript but Java was the new big thing at time. http://kb.mozillazine.org/JavaScript_is_not_Java