Skip to main content

JavaScript Source Code

Free JavaScript Source Code. Download 10 latest JavaScript with source code for free here.

Eyes following the mouse using Javascript

In this tutorial, I am going to teach you how to make a xavier eye or eyes following the eye using javascript. Just follow the instructions below. Instructions Writing our javascript code and name it as jseyes.js /* jseyes.js The classic Xeyes in JavaScript (c) PROPIX Ltd, Written by Pintér Gábor Székesfehérvár, Kriványi u. 15. H-8000, HUNGARY Tel: +36 30 3489752 Fax: +36 22 304326 Email: propix

Cursor Sparkle Effect using Javascript

In this chapter we are about to learn how to make a sparkle effect in your mouse cursor. You can download and use this in your projects or systems. Just follow the instructions below. Instructions Writing our css code BODY{ overflow-x:hidden; } .s1 { position : absolute; font-size : 10pt; color : blue; visibility: hidden; } .s2 { position : absolute; font-size : 18pt; color : red; visibility

Neon text effect using Javascript

In this tutorial, We will learn how to create a neon text effect that you can use in you projects or systems. Just download the source code bellow and follow the instructions. INSTRUCTIONS Copy this code and save it as index.php body { background-color: black; } var message="Welcome to Sourcecodester!" var neonbasecolor="white" var neontextcolor="yellow" var flashspeed=100 //in milliseconds ///No

Date of Birth Counter Using Javascript

In this chapter, You will learn to make a Date of birth counter into days, hours and time. Just follow the tutorial below and download the source code. DIRECTIONS Creating our HTML code Date of birth: You are days old: Plus hours old: Plus minutes old: Creating our javascript code You have now created a date counter that counts days, hours and minutes between the date today and the date you

Disable Textbox in 3 Failure Login Attempts in Javascript

In this tutorial we are going to learn how to disable text box in 3 failure login attempts. The user is only given 3 chances to enter the correct username and password. Username: test Password: test You can modify the username and password inside the script. table{ margin:auto; } input{ border:1px solid #888; padding:5px; } var count = 2; function validate() { var un = document.myform.username

Hangman Game Using Javascript

In this tutorial, we are going to make a simple hangman game using javascript and html. Just follow the instructions below and download the source code. You can you this in your projects or systems. Instructions Writing our html code Score : Fails (6): Writing our Javascript Code /* Script by Mike Mcgrath- http://website.lineone.net/~mike_mcgrath Featured on JavaScript Kit (http://javascriptkit

MP3 Player Using Javascript

In this tutorial, I will teach you how to make a mp3 player using javascript and html. just download the code to use it in your projects or systems. Instructions Creating our index.php page Audio PLayer 00:00| 00:00 Creating our style.css page. /* CSS Document */ body{ background:#f5f5f5; } #container{ width:730px; margin:50px auto; padding:5px; background:#000; } #playpausebtn{ background:url(

Simple Scientific Calculator using javascript

In this project we are going to learn how to create a simple scientific calculator using javascript. Here's the script for scientific calculator. Javascript Code: function addChar(input, character) { if(input.value == null || input.value == "0") input.value = character else input.value += character } function cos(form) { form.display.value = Math.cos(form.display.value); } function sin(form) {

Snake Game using Javascript

In this tutorial, I am going to teach on how to create a snake game in javascript. Just download the source code and follow the instructions below. DIRECTIONS HTML Code snake[i-1].xx) { context.drawImage(snakeTailImage, (snake[i].xx * 32), (snake[i].yy * 32) ); } //following right else if(snake[i].xx snake[i-1].yy) { drawRotatedImage(snakeTailImage,(snake[i].xx * 32), (snake[i].yy * 32), 90); } /

Snow Effect Using Javascript

This is a simple program that will teach on how to create a snow effect using javascript. You can use this in your projects or systems. Just download the source code below. Instructions HTML Code Snow Demo body { padding:0; margin:0; } #demo { display: block; width: 100%; } /** * This function takes 2 arguments * First is the path to the directory with snowflake images * Second is the maximum