IT219 Web Programming II

Web Programming II TU Board 2021 question paper

17 questionsSit this paper (timed)

Tribhuvan University

Bachelor of Information Technology Management

Semester 4 · TU Board 2021

Course Title: Web Programming II (IT219)

Full Marks: 40Pass Marks: 20Time: 2 hrs

Candidates are required to give their answers in their own words as for as practicable.

Group A

Brief Answer Questions(10 × 1 = 10)

  1. 1.

    How do you create 2-D array in PHP?

    1
  2. 2.

    Differentiate between client side and server side scripting language.

    1
  3. 3.

    How do you inspect file permission inPHP?

    1
  4. 4.

    Write a statement to create a 2D array in PHP ?

    1
  5. 5.

    Write the syntax for do .. while loop in PHP ?

    1
  6. 6.

    What do you mean by POST method?

    1
  7. 7.

    How can you prevent SQL injection inPHP?

    1
  8. 8.

    Write a PHP program to display the current date in PHP ?

    1
  9. 9.

    What is the use of mktime()?

    1
  10. 10.

    How can you generate a unique id in PHP?

    1

Group B

Exercise problems(5 × 4 = 20)

  1. 11.

    Write a PHP function that accepts an array of integers and display in ascending order.

    4
  2. 12.

    Write a PHP program to demonstrate that contain a textbox for name , a textbox for age and a textarea for comments. Validate the data before submitting the data to the server. Assume all the required validations and age must be between 1 to 100.

    4
  3. 13.

    Write a PHP program to insert subject code, subject description, credit into database . Make all the required assumptions about the database.

    4
  4. 14.

    Write a PHP program to create a webform with two textboxes (name and age), a radio button for gender and a submit button. When a submit button is clicked, save the data to the file named "Person.txt."

    4
  5. 15.

    Write a program to demonstrate session variable in PHP.

    4

Group C

Comprehensive Answer Questions(2 × 5 = 10)

  1. 16.

    Explain default values in form with example.

    5
  2. 17.

    Write short notes on (any two) a. Variable scope b. Changing the format of Retried rows c. Cross site scripting attack and its prevention

    5

— The End —