Jump to content

higuy001

Members
  • Content Count

    14
  • Joined

  • Last visited

Community Reputation

0 Neutral

About higuy001

  • Rank
    Newbie

Previous Fields

  • Languages
    Java, HTML, CSS, JavaScript, Cocoa (a little)

Contact Methods

  • Website URL
    http://
  • ICQ
    0

Profile Information

  • Location
    LMAO!
  1. I have some applets i made with java processing, but when I try to view them on the web, i get the error: "applet xxxxx notinited."Does anyone know how to make the applet init for the web?Thanks.HiGuy
  2. Ok. Now to the Java board (I think) for my notinited problem. (Notinited? Why not just "not initiated"?)Thanks!
  3. All of my applets I keep in the path /Applets/Applets/ (the second one is because the first folder has 1, 2, and 3 folders in it.)I have the code:function otherJava() {hideApplet();var div = document.getElementById("content");hideHelp();var txt = "<hr style=\"max-width: 750px;\"><a href=\"#\" onclick=\"applet('applet','Coolio.class');\">Coolio</a><br>";div.innerHTML = txt;}function applet(id,file,folder) { var div = document.getElementById(id); var txt = '<!--[if !IE]>-->'; txt += '<object id="applet" width="300" height="300"' txt += 'classid="java:' + file + '" type="application/x-java-applet">'; txt += '<!--<![endif]-->'; txt += '<object id="Hey" classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93" width="300" height="300">'; txt += '<param id="code" name="code" value="Applets/Applets/' + file + '" />'; txt += '</object>'; txt += '<!--[if !IE]>-->'; txt += '</object>'; txt += '<!--<![endif]-->'; div.innerHTML = txt;} but it doesn't seem to be right.I focus on these lines: txt += '<param id="code" name="code" value="Applets/Applets/' + file + '" />'; var txt = "<hr style=\"max-width: 750px;\"><a href=\"#\" onclick=\"applet('applet','Coolio.class');\">Coolio</a><br>"; I used to have: var txt = "<hr style=\"max-width: 750px;\"><a href=\"#\" onclick=\"applet('applet','Applets/Applets/Coolio.class');\">Coolio</a><br>"; but that wouldn't work.Now I get the error: "Applet Coolio notinited."What does that mean?
  4. 1. Yes I am executing the function:index.html: <a href="#" onMouseOver="midSet();" onClick="divOther();">Other</a>    MakeMeGo.js: function divOther() {var div = document.getElementById("header");hideContent();var txt = "<h2>Other</h2><hr style\"max-width: 875px;\"<a href=\"#\" onClick=\"otherWidgits()\">Widgits</a>\ \ <a href=\"#\" onClick=\"otherJava()\">Applets (Java)</a>";div.innerHTML = txt;hideHelp();}function otherJava() {var div = document.getElementById("content");hideHelp();var txt = "<hr style=\"max-width: 750px;\"><a href=\"#\" onclick=\"otherAppletCircle();\">Circle</a><br>";div.innerHTML = txt;}function otherAppletCircle() { var div = document.getElementById("applet");var txt = "<!--[if !IE]>--><object id=\"applet\" width=\"300\" height=\"300\" classid=\"java:file.class\" type=\"application/x-java-applet\"><!--<![endif]--><object id=\"Hey\" classid=\"clsid:8AD9C840-044E-11D1-B3E9-00805F499D93\" width=\"300\" height=\"300\"><param name=\"code\" value=\"Applets/1/circle.class\" /></object> <!--[if !IE]>--></object><!--<![endif]-->";div.innerHTML = txt;} 2. Because if I used HTML, I would have quite a few HTML files which take longer to load than a single script (I think).Plus, the script, once loaded, will be instant, rather than the web pages, which take time.Edit: Would it work if I put the code: <!--[if !IE]>--><object id="applet" width="300" height="300" classid="java:file.class" type="application/x-java-applet"><!--<![endif]--><object id="Hey" classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93" width="300" height="300"><param id="code" name="code" value="" /></object> <!--[if !IE]>--></object><!--<![endif]--> in the HTML, without the value"url.class" then used: var applet = document.getElementById("code");applet.value = "url.class"; ?
  5. New code: function otherAppletCircle() { var div = document.getElementById("applet");var txt = "<!--[if !IE]>--><object id=\"applet\" width=\"300\" height=\"300\" classid=\"java:file.class\" type=\"application/x-java-applet\"><!--<![endif]--><object id=\"Hey\" classid=\"clsid:8AD9C840-044E-11D1-B3E9-00805F499D93\" width=\"300\" height=\"300\"><param name=\"code\" value=\"Applets/1/circle.class\" /></object> <!--[if !IE]>--></object><!--<![endif]-->";div.innerHTML = txt;} But this doesn't work...The innerHTML of the div tag doesn't change.Is there a script that will modify it?
  6. How would I use js to make a java applet on the page?I have some code, but it's not working.index.html: <div id="applet"></div> MakeMeGo.js: function otherAppletCircle() { var div = document.getElementById("applet");var txt = "<object classid=\"clsid:8AD9C840-044E-11D1-B3E9-00805F499D93\" width=\"200\" height=\"200\"> <param name=\"code\" value=\"Applets/1/circle.class\"></object>";div.innerHTML = txt;} Is something wrong?I'm guessing it has to do with the "classid=\"clsid:8AD9C840-044E-11D1-B3E9-00805F499D93\"" section.Help? HiGuy
  7. Hi. I have a dashcode project with 3 sides.Does anyone know how to make a "ToSide3" (or something like that) event? I tried copying the original code... function showInstruct(event){ var front = document.getElementById("back"); var back = document.getElementById("instruct"); if (window.widget) { widget.prepareForTransition("ToFront"); } front.style.display="block"; back.style.display="none"; if (window.widget) { setTimeout('widget.performTransition();', 0); }} But that doesn't work.Anyone know how?
  8. I just mash return. Mac Safari.
  9. Oh. Never thought of that. (Never heard of it either.)But it works!Thanks!HiGuy
  10. Code: function gmn(event) {var myNum = Math.floor(Math.random()*101);changeText("lo", "0");changeText("hi", "100");changeText("ans", myNum);}function changeText(text, withh) {var textFieldToChange = document.getElementById(text);var newTextFieldText = withh; textFieldToChange.value = newTextFieldText;}function getText(text) {var textAreaValue = document.getElementById(text);return parseInt(textAreaValue.value);}function pInt(thing) {return parseInt(thing);}function alerttext(event) {var gess = getText("guess");gess = pInt(gess);var an = getText("ans");an = pInt(an);//NaN detection: \/if (gess == "NaN") {alert("bad");} else {alert(gess);if (gess < an) {changeText("lo", gess);} else if (gess > an) {changeText("hi", gess);}}changeText("guess", "");}function winn() {alert("YouWin!");} For some reason, when I start it, enter a number, and hit guess, I get an alert "NaN" which means that the NaN detection didn't work correctly.Does anyone know why?HiGuy
  11. Oooohhhhhhhhhhhhhh! :)I SO didn't realize that.Wow.I am dumb. :)Thanks! It works!HiGuy
  12. That doesn't seem to work though.Is anything else wrong?function divMath() {var div = document.getElementById("content");var txt = "<A href=\"http://miniwidgit.webs.com/Math.wdgt.zip\">Math Widgit</A><br><input type=\"button\" value=\"Info...\" onClick=\"att();\"><br><a href=\"http://miniwidgit.webs.com/MathLarge.wdgt.zip\">Math Widgit Large</a>";div.innerHTML = txt;} <a href="#" onClick="divMath();" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('Image1','','TabLeft2.png',1)"><img src="TabLeft.png" name="Image1" width="100" height="50" border="0"></a> <div name="content"></div> HiGuy
  13. Does anyone know the code to change a <div> tag's content? I've tried using function divMath() {var div = document.getElementById("content");var txt = "<A href=\"http://miniwidgit.webs.com/Math.wdgt.zip\">Math Widgit</A><br><input type=\"button\" value=\"Info...\" onClick=\"att();\"><br><a href=\"http://miniwidgit.webs.com/MathLarge.wdgt.zip\">Math Widgit Large</a>";div.value = txt;} but this doesn't work.Am I doing anything wrong? Did I miss a semicolon? Can anyone help? :)HiGuy
  14. Is there a method that pauses the specific method it's in, no others, for a certain # of nanoseconds or milliseconds.I have tried using delay(), but that stops the whole program and it gets on my nerves.Does anyone know of a delay() for only the method it's in? ~~Hi Guy~~
×
×
  • Create New...