Click to See Complete Forum and Search --> : I figured out how to include Java Script with Kool Moves

10-13-2000, 04:47 PM
It works the same way that it does in Swish. I noticed before that the two actions were about the same.

Put your Javascript commands in the Get URL command.

make sure that you include this "Javascript:" at the front of the tag.

Brad it would be possible to keep score now using this knowledge. In Fact I whipped something up post the example latter and will post it latter.

Also MonkeyPants, a moderator over in the Swish Forum is wrong: You can manipulate variables in this statement. My example will demonstrate just that.

10-13-2000, 06:47 PM
Thanks Johnie, I didn't think monkeypants was right on that either. Glad I have proof now. Good Work ;)

10-13-2000, 08:59 PM
Great find Johnie, looking forward to an example:)


10-13-2000, 09:32 PM
My monitor has been on the fritz for the last week or two and it finally died today.

I bought a new one about 45 mins ago.

here is the example

When You click on one circle it will send a +"B" to the text box when you click on the other one it will put Yay in the text box.

For those of you who are saying now what good is that?

Well if you had a game you could use that to keep score.

You could right a quiz and then have the results sent to your E-mail.

The possibilities are endless.

10-13-2000, 10:06 PM
Yeah I saw the thread in the Swish forum:) Looks like a great discovery:) Can't wait to try it out, could you send my the .fun file, I want to see exactly what you did.


10-13-2000, 11:48 PM
I'll send it monday.

10-13-2000, 11:49 PM
I changed my mind- I'll work up score keeper and HTML for you get it to you this Sunday.

10-14-2000, 01:40 PM
Well I certainly hope that you had a proper funeral for the monitor :D

10-14-2000, 03:55 PM
10 story drop?


10-14-2000, 04:13 PM
2 meter hurl into the dumpster- I live on the first floor of my apartment building.

10-14-2000, 05:21 PM
Here it is the first ever Kool-Moves Javascript counter.


Click on the circle to make the count go up.

Brad now you can keep Score.

I'm zipping and sending it to you now.

10-14-2000, 05:26 PM
I'm gonna write a flashkit tutoriol about it and get me some sound loops.

10-14-2000, 10:10 PM
Sweet, this will work great, and just think what we can do now with our little RPG plan, by the way Johnie, got any ideas of what you want to do?


10-15-2000, 02:14 AM
Not yet,

Demons wrote an all Flash RPG but its all in some asian languge and I can't read it.

I had some ideas about altering the script that loads the SWF. If we declare it as a var in the header we could alter it from the SWF. Your little missle game then could have random missles and a score.

Using cookies people could save the RPG or a list of high scores. I only wish I could find a way to send scripts into the SWF instead of just out of it. I think there is a way, we could ask around.

I want to get that intro animation and my other tut done before moving on to too many new projects.

10-15-2000, 10:32 AM
Yeah I know how busy is, I have a bunch of projects backed up, including getting my homepage up and running.....going to get the email and the forums up on KoolKit, and make a tutorial, and finish the splash page, and get your stuff up, and then :) I think I can start on other things.


10-15-2000, 03:38 PM
I wrote a tutoriol for Flash Kit on this one- What they'll do with it I don't know. Brad and Bob I'm sending you both copies of this also.

10-15-2000, 09:43 PM
Thanks, oh and I got the score files thanks, I see exactly what you did, surprising that it works that way, wouldn't have thought of doing that.


Bob Hartzell
10-16-2000, 12:19 PM
Johnie, this is a very interesting tutorial. I tried to post it on the koolmoves website but ran into problems because there are a lot of relative paths to the flashkit site in the html. It there an absolute url for the tutorial on the flashkit site?

I mentioned it to my partner who did the game on the koolmoves site (I posted a new update this morning). He is leaving the country in several days (to Israel of all places, his wife is Israeli) so he will not have time to incorporate it.

The Artexer
10-16-2000, 01:42 PM
Great work you are doing...

But please could you explain how to set up a page counter.


10-16-2000, 02:10 PM
It is not up on Flash Kit yet. I am not sure they will even post it. I am going to write an HTML primer and general JavaScript Tut next- it has been requested. Bob-I can send you a plain one without the Flash kit stuff.

I have also had a request for a CSS positioning tutorial- With CSS In IE you could have a Flash Movie overlay an animated GIF or embedded Real-MS media object and have the two play at the same time making that the background.

The two also have game making applications. With CSS, JavaScript, and Cookies one could write an interactive game using SWF for characters and background animation while allowing the CSS and JavaScript to handle the programming side. Cookies could be used to save the game data.

The Java script could also be used for other things like form scripts etc.

The page counter thing can be done but would require a cgi-bin and a Pearl script. It would work the way most page counters in DHTML would except that instead of Gifs you would have 10 SWFs. What you would do is declare the var in the heading and then in the write document section refer to that var.

I might write a Tut on that one also- give me time though.

Bob Hartzell
10-16-2000, 02:16 PM
It would be great if you could strip out the references to FlashKit in the html. I will post it then. The other tutorial sounds interesting also.

10-16-2000, 03:35 PM
I'll get the Java Script one to you tonight. I'm not done with the CSS one yet.

10-16-2000, 05:03 PM
Okay, I have an example running right now on my desktop of a Kool Moves generated SWF with a GIF Background.

Brad, I'm going to write the tut on this one tonight and it might hold up the Kool Kit template;

I will get both my example and tut up tonight.

For now here is a peak for the HTML to acomplish this;


<style TYPE="text/css">
.a{ position: absolute; left: 100px; top: 43px;z-index=2 }
.b{ position: absolute; left: 120px; top: 43px;z-index=1 }

<body BGcolor="#000000" text="#ffffff">
<div class="a">
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" id="test4" width="550"
<param name="movie" value="test6.swf">
<param name="quality" value="high">
<param name="play" value="true">
<param name="loop" value="true">
<param name="bgcolor" value="#000000">
<param name="Wmode" value="transparent"><script LANGUAGE="JavaScript">
var ShockMode = 0;
if (navigator.mimeTypes && navigator.mimeTypes["application/x-shockwave-flash"] && navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin) {
if (navigator.plugins && navigator.plugins["Shockwave Flash"])
ShockMode = 1;
} if (ShockMode ) {
document.write('<embed src="test6.swf"');
document.write(' width=550 height=300 bgcolor="#000000" quality="high" loop="true"');
document.write(' TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/shockwave/download/">');
} else if (!(navigator.appName && navigator.appName.indexOf("Netscape")>=0 && navigator.appVersion.indexOf("2.")>=0)) { document.write('<IMG SRC="nonflash.gif" width=550 height=300');

</script><noembed><IMG SRC="nonflash.gif" width=550 height=300 BORDER=0></noembed><><img SRC="nonflash.gif"
width="550" height="300" BORDER="0"></>
</div><div class="b">
width="550" height="300" alt="animated.gif (89002 bytes)">

The funny thing is that you don't have to use an animated Giff for this. You could put anything into Div B like an embbedded Realplayer movie for this to work. The other funny thing is by altering the z-index you could have it on top of it.

The even funnier thing is that by using this and some DHTML you could have a SWF playing on top of an SWF and have it move.

for you eager beavers out there you can copy my HTML and use it as/is just remember that the animated GIF is called animated.gif and the SWF is test6. If you know your HTML you could change the names ansd set the background color to whatever you want.

10-16-2000, 05:13 PM

I forget to tell you guys something- This example only works in IE 3.0 and higher becuse of how I used WMODE. Did Andrew ever tell us how he got WMODE to work in Netscape?

I would really like it if he would share that with us.

10-16-2000, 06:00 PM
Nice, now aren't you a busy fella. Good Work!
When you get the template up, I will post it, good job, did you, are you sending the javascript tutorial KoolKit's way, would be a good addition. I am going to make a simple tutorial on how to make a banner, we haven't seemed to get any attention on the contest, I may place KoolKit on Site check, and get it on some search engines, to draw some attention to KoolMoves and KoolKit, also trying to get my site, done in KoolMoves up, sigh, wish I had time to play with javascripts for KoolMoves, will try to incorportate some in my site.


10-16-2000, 06:11 PM
Yes, I'll send you the stripped Javascript tutorial also.

I thought I sent you the Flash Kit version also- If you didn't get it then that's okay. I'll resend and post to the I-drive.

10-16-2000, 08:02 PM
I sent the stripped tut out. If you don't have it E-mail me.

10-16-2000, 08:27 PM
This is the example


10-16-2000, 10:21 PM
I wrote the CSS Tut and sent it out. I sent Stripped versions to Brad and BOB.

10-17-2000, 09:44 AM
Thank you


Bob Hartzell
10-17-2000, 10:21 AM
I posted both tutorials on the koolmoves tutorial page. I also updated the animations in the top frame. Check out games level.

10-17-2000, 11:02 AM
I like level 42.

I have an idea on how to create a movable animation (IE it moves when keys are depressed) Using Java Script and CSS- I am almost 100% sure that it will work.

I'll whip something up after I Iget those templates done.

I also noticed that I can't spell- OOPs!.

02-08-2001, 07:14 PM
Originally posted by johnie
I'll get the Java Script one to you tonight. I'm not done with the CSS one yet.


Johnie, I realise that this is an ancient thread to you guys,but I'm working my way through the forum. did you ever get the javascript tut done?

I couldn't find anything on flashkit.

if you could post a link or mail to me at
mail@shaunleahy.co.uk would be greatly appreciated.

02-08-2001, 08:55 PM
Yes, It is on the Kool Moves web site. Flashkit never published it or gave a reason why they didn't.

02-08-2001, 08:57 PM
Yes, It is on the Kool Moves web site. Flashkit never published it or gave a reason why they didn't.

The tut can be found at http://www.koolmoves.com

02-09-2001, 05:13 AM
Thanks johnie.

If I had bothered to notice that the thread was 2 pages long I'd have seen that Bob had already said it was there.


02-09-2001, 11:58 PM
I am trying to create a html browser pop-up window with no menus, buttons, non-resizing etc... I do want the scroll bars!

Seeing that javascript can be put in the "get url" in KoolMoves"....

What code would I use to open a browser (no menus-buttons) kinda like the "openwindow()" javascript command???


02-12-2001, 02:32 PM
Look in the scripting in backend section as this question has been asked and answered many many many times there (Just be careful becuase a lot of people in the scripting and backend forum do not know what they are doing and will twell you to do somethig unnescary).

Pretty much with V 1.85 you do not need to use the Get URL box anymore. Just select Javascript from the actions. Take extra care though that you do not erase the javascript: next to the code dialog heading.

the command will be window.open(attributes);void(0); Check http://www.webmonkey.com to see how to set the attributes.

I may post get around to making a tut on this as I have some spare time tonight.

02-12-2001, 06:14 PM
How about some more DHTML?
You can use some cool scripts from Dynamic Drive. (http://www.dynamicdrive.com/)
And how about using DIV layers for the gif behind flash?
Instead, of all the style sheet scripting.
Doc'Ree James

02-12-2001, 08:26 PM
Well... DHTML is nothing more than Style Sheet manipulation with Javascript using the DOM. Sometimes (Often) DHTML is confused with just plain Javascript. In all honesty I have posted several "DHTML" scripts to the forum that could be used with JKool Moves including a Java (the applet language- not javascript) intergration example which uses Javascript from a SWF to manipulate a Java Applet.

Also when you get into DHTML you run into Cross Browser Issues. Netscape and most other Web Browsers out there conform to ECMA script (The decided on standard for web browser scripting) and the W3C DOM Model where as Microsoft implemented its own standard and own DOM model that is not compatible with Netscape or the rest of the worlds but which will display the standard corectly in most cases. This is important to remember becuase it makes other browsers appear to be "buggy" when in fact they are not. To make matters worse MS FP and other web authoring tools will write "IE Optimized Pages that will only work in Internet Explorer" (Direct quote from the Microsoft Press edition of Liquid Motion by design) and the MS web authoring tools have deligtfull function calls that only work on Microsoft servers (chances are pretty darn good- 45% that your server is not a Microsoft server). So what does this have to do with DHTML. It has everthing to do with DHTML. Look at the Dynamic Drive and see how many effects are only possible with IE. My position is why make something that will only run in IE?

The Css Tut that I posted before does use a Div layer for the Gif. It just has the Style Defined so that it would work in both NS or IE. The only problem is that it only works with WMode being turned on. NS (And IE) will place the SWF over the Div no matter how you set it if you don't use WMode.