google.com, pub-4617457846989927, DIRECT, f08c47fec0942fa0 Learn to enjoy every minute of your life.Only I can change my life.

Saturday, July 13, 2013

Qiuz Try It

Quiz :-

1. What does HTML stand for?
Hyper Text Markup Language
Home Tool Markup Language
Hyperlinks and Text Markup Language


2. Who is making the Web standards?
Google
The World Wide Web Consortium
Microsoft


3.Choose the correct HTML tag for the smallest heading:-
<h6>
<heading>
<h1>


4. What is the correct HTML tag for drawing horizontal line?
<lb>
<br>
<hr>


5.Inside which HTML element do we put the JavaScript?
<script>
<js>
<javascript>


6What is the correct JavaScript syntax to write "Hello World"?
response.write("Hello World");
document.write("Hello World");
echo "Hello World";


7.Where is the correct place to insert a JavaScript?
Both the <head> section and the <body> section are correct
The <head> section
The <body> section


8.C++ is which language?
Object - Oriented Programming Language
Procedure Oriented Programming Language
Both the above


9.The Size of char is _____ bits.
1
4
8


10._____ is unary operator.
+
++
-


11.int is ______ data type
derived
built-in
user-defined



Wednesday, July 10, 2013

Javascript Examples

Example1.html :-

<HTML>
<HEAD>
<SCRIPT LANGUAGE="JavaScript">
function Hello()
{
alert("Hello,Welcome and  have a good day.");
}
</SCRIPT>
</HEAD>
<BODY>
<INPUT TYPE="button" NAME="Button" VALUE="Press me" onClick="Hello()">
</BODY>
</HTML>

Output :-




Example2.html :-


<HTML>
<HEAD>
<SCRIPT LANGUAGE="JavaScript">
function Name()
    {
        var answer = prompt("What is your name?", "");
        if (answer)
        alert("God bless You, " + answer);
    }
</SCRIPT>
</HEAD>
<BODY>
<INPUT TYPE="button" NAME="Button" VALUE="Press me" onClick="Name() ">
</BODY>
</HTML>

Output:-




Example3.html:-

<html>
<body>
<p>This example calls a function which performs a calculation, and returns the result:</p>
<script>
function myFunction(a,b)
{
return a*b;
}
document.write(myFunction(7,8));
</script>
</body>
</html>

Output:-
This example calls a function which performs a calculation, and returns the result:
 12



Example4.html:-
<html>
<body>
<script language="JavaScript">
function confirmFunction()
{
var a;
var b=confirm("You have press a button!Do you want to continue?");
if (b==true)
  {
  a="You have pressed OK to continue!";
  }
else
  {
  a="You have pressed Cancel to go back!";
  }
document.write(a);
}
</script>
<p>Example of Confirm box.Click the button below to display a confirm box.</p>
<button onclick="confirmFunction()">Press Me</button>
</body>
</html>

Output:-
Example of Confirm box.Click the button below to display a confirm box.



Exampe5.html :-
<html>
<body>
<p>Click the button to demonstrate the prompt box.</p>
<button onclick="promptFunction()">Press Me</button>
<script>
function promptFunction()
{
var a;
var b=prompt("Please enter your name","");
if (b!=null)
  {
  a="Hello " + b+ "! How are you today?";
  document.write(a);
  }
}
</script>
</body>
</html>

Output :-
Click the button to demonstrate the prompt box.





Example6.html :-
<html>
<body>
<p> Click the button to wait 3 seconds then greets alert "Welcome"</p>
<script language="JavaScript">
function TimeFunction()
{
setTimeout(function(){alert("Welcome to professional-in-computer.blogspot.com")},3000);
}
</script>
<button onClick="TimeFunction()">Press me</button>
</body>
</html>

Output:-
Click the button to wait 3 seconds then greets alert "Welcome"



अच्छे विचार करे विचार

  पहचान की नुमाईश, जरा कम करें... जहाँ भी "मैं" लिखा है, उसे "हम" करें... हमारी "इच्छाओं" से ज़्यादा "सुन...