Home | Contact Us | Log In | Help
HOME NEW LISTING MOST POPULAR HIGHEST RATED SCRIPTS ADD SCRIPT DOWNLOADS FORUM
Tutorials
  ASP.Net & C#
  ASP
  Perl and PHP
  Java Scripts
  C and C++
  Ajax Tutorials
  J2ee, J2Me, Java
  Python & Ruby Rail
  Crystal Report
  Sap
  CGI
  XML
  Cold Fusion & CFML
  HTML, DHTML & CSS
  Dreamweaver
  FLASH
  Photoshop/Web Designing
  Tools & Utilities
  Oracle/D2K
  Sql Server
  MySql
  Domain Name Registration
  Remotely Hosting
  Web/Server Application
  Hotel Marketing
  Internet and Law
   Search Engine Optimization/SEO
E-Commerce
Interview Questions
previous< 12 13 14 15 16 17 18 19 20 21 21 22 > Next
JAVA SCRIPT 18
Javascript Tutor

As I said before, Javascript is plenty powerful. We can go in any one of a dozen directions with this. What I'm going to do is wander around here and there, trying to touch on as many basic things as I can. I'll try to explain a little as we go.

So, what now? Let's add a prompt box to ask our name and then spit out a personalized Hello message.

Events

Events are how we trigger our functions to run. The easiest example is a button, whose definition includes the words onClick="run_my_function()". The onClick event, as its name implies, will run the function when the user clicks on the button. Other events include OnMouseOver, OnMouseOut, OnFocus, OnBlur, OnLoad, and OnUnload

Two-dimensional Arrays in JavaScript

The following example shows you how a two-dimensional array can be produced in JavaScript. You can enter a value in the box labelled 'Person ID', which is the first number of a two-dimensional array, and then select one of two numbers in the Name/Profession box. Then you need to press the go button to see the results.

For instance, if you choose the number '0' for the Person ID, and Name (0) in the Name/Profession drop down, then you get the name of the person with the ID of '0'. If you choose the Profession (1) option then you get the profession of that person. The first name is 'Tom' and he is a scientist.

Calling the Array Function

In order to use the array, we have to call it somewhere. In this page, it is called in the body:

This is done as shown below by called CreateMultiArray() in some JavaScript tags.

How to Make Windows - without any carpentry knowledge at all

In my browser, I get a menu. This is called a control in computer-speak, because the open window can open other sites while staying in existence itself. Drag the control menu over to where you want it, and resize this window so you can view both. And click on some links. The links appear in this window. There is also a close button. Click the close button and the window closes, as expected. This page is then reloaded. I think this is a very neat and useful technique!

previous< 12 13 14 15 16 17 18 19 20 21 21 22 > Next
  Copyright 2000-2006 © SoloScript.com, All rights reserved.