BBIT 201 INTERNET APPLICATION PROGRAMMING KCA Past Paper

UNIVERSITY EXAMINATIONS: 2016/2017
EXAMINATION FOR DEGREE OF BACHELOR OF BUSINESS IN INFORMATION
TECHNOLOGY
BBIT 201 INTERNET APPLICATION PROGRAMMING
MODE: WEEKEND
DECEMBER.2016 ORDINARY DURATION 2 HOURS
INSTRUCTION: Answer question ONE and any other TWO questions

QUESTION ONE [30 MARKS]
a) Briefly explain how an online application. Give two examples
[6 Marks]
b) Differentiate between an element and an attribute as used in HTML.
[2 Marks]
c) Describe any THREE rules for naming a variable in PHP.
[6Marks]
d) Explain the following statements in JavaScript code below.
1 <script language=”javascript”
type=”text/javascript”>
2 var n= new Array(10)
3 for(i=0;i<10;i++)
4 {
5 n[i]=prompt(“Enter county name: “+i);
6 }
7 for(i=0;i<10;i++)
8 {
9 document.write(n[i]);
10 document.write(“<br>”);
11 }
12 </script>
[7 Marks]
e) Explain the following statements in PHP code below.
1 <?php
2 $a=9;
3 $b=10;
4 $c;
5 echo “<hr noshade=’noshade’ size=’40%’>”;
6 $c=$a+$b;
7 echo “The sum of $a and $b is $c”;
8 echo “<br> End of calculations………..”;
9 ?>
[9 Marks]
QUESTION TWO [20 MARKS]
a) Write an html code to display the table below:

[6 Marks]
b) Explain what each of the following html tags will display:
i. <HR noshade=”noshade” size=”40″ >
ii. <font color=”red” size=”6″ style=”italic” > Internet</font>
iii. <marquee direction=”wobbling” height=”30%” bgcolor=”red” behavior=”scrolling”>
Restaurant</marquee>
[6 Marks]
c) Briefly explain the following form elements.
i. Legend
ii. Fieldset
iii. Menu
iv. Text area
[8 Marks]
QUESTION THREE [20 MARKS]
a) Write a javaScript code to calculate and display average score of pupil’s marks in five subjects. The
interface should be as follows:


[10 Marks]
b) Write a javaScript code to display odd numbers from 3 to 49 using while loop.
[10 Marks]
QUESTION FOUR [20 MARKS]
a) Differentiate between POST and GET methods in a form.
[4 Marks]
b) You are required to develop a simple application that requires the user to key in the order number,
description, quantity and price per unit. The program then calculates the total amount of the bill by
using the formula: total=quantity*price per unit. The front functionality of the application can be
developed in HTML but the backend functionality should be implemented in PHP.
[10 Marks]
c) Write a PHP script to print the following Floyds triangle using DO loop.
* * * * * *
* * * * *
* * * *
* * *
* *
*
[6 Marks]
QUESTION FIVE [20 MARKS]
a) Write an HTML code to display the following form:


[10 Marks]
b). Write a javascript code to validate the following radio option choices.


[10 Marks]

(Visited 113 times, 1 visits today)
Share this:

Written by