Siksha Sarovar

Siksha Sarovar (sikshasarovar.com) is a free educational web application that helps students in India learn programming and prepare for academic and competitive exams. The platform offers structured coding courses (C, C++, Python, Java, HTML, CSS, PHP, Power BI, AI, Machine Learning, Data Science), complete university curriculum notes for BCA/MCA students with previous year question papers, Class 10 and Class 12 CBSE/HBSE school notes, and dedicated preparation material for SSC, UPSC, Banking, Railway and other government exams. Browsing the site is completely free and requires no account. Users may optionally sign in with Google solely to save their learning progress, quiz scores and personal preferences across devices.

Privacy Policy | Terms of Service | Contact Siksha Sarovar | About Siksha Sarovar

v4.0.9 · PWA
Siksha Sarovar logo
Siksha Sarovar
Your Learning Universe

Siksha Sarovar is a free e-learning platform for coding courses, BCA university notes and competitive exam preparation. Optional Google sign-in saves your learning progress across devices.

Initializing knowledge base…
Compiling modules 0%

Unit 2: Important Questions

Lesson 19 of 36 in the free Web Based Programming notes on Siksha Sarovar, written by Rohit Jangra.

Important Questions: Unit 2 – Functions, Forms & State Management

Short Answer Questions (2-5 Marks)

  1. What is a PHP function? Distinguish between function definition and function call.
  2. Explain the difference between passing arguments by value vs. by reference in PHP.
  3. What is a Recursive function? Give one example with output.
  4. Distinguish between Cookies and Sessions in PHP with a comparison table.
  5. What is the significance of HTTP being a stateless protocol? How does state management solve this?
  6. Compare GET and POST form submission methods.

Long Answer Questions (10-15 Marks)

  1. Discuss variable scope in PHP in detail — Local, Global, and Static — with code examples and a comparison table.
  2. Explain how PHP handles HTML forms in detail. Discuss GET, POST, and $_REQUEST superglobal. Include code for a form and its PHP handler.
  3. Describe all four State Management techniques (Cookies, Sessions, URL Rewriting, Hidden Fields) with examples and a comparison table.
  4. Explain PHP Error types (Notice, Warning, Fatal, Parse) and discuss how to handle them programmatically.