Web Technology II
Semester IV · BCA 255 · 3 credits
0 / 8
chapters done
-
The syllabus asks for
- Client-side versus server-side scripting
- Variables, constants and types
- Control structures
- Arrays
- Functions
- Including files and running from the command line
- Seeing the ideas: from request to running PHP
Key points
- PHP runs on the server, generates HTML dynamically and can reach files and databases; the browser never sees the source.
- The language is loosely typed, with strict mode and type declarations available; use ===.
- Arrays are the universal data structure; functions can take defaults, references, variadics and named arguments.
- Files are shared with include/require; the command line and the built-in server make testing easy.
-
The syllabus asks for
- Receiving form data
- Validation, sanitising and escaping
- Dates, including files
- File handling
- Cookies
- Sessions
- Sending e-mail
- Seeing the ideas: how data travels between browser and server
Key points
- Form data arrives in GET and _POST; it must be validated and escaped because it comes from an untrusted user.
- PHP reads and writes files and CSV, handles dates and uploads, but each of these needs defensive checks.
- Cookies keep small data in the browser; sessions keep state on the server and identify the user with a random ID.
-
The syllabus asks for
- MySQL basics and data types
- Querying: SELECT, WHERE, ORDER BY
- Updating and deleting
- Aggregate functions, GROUP BY and HAVING
- Subqueries and joins
- Administration notes
- Seeing the ideas: how MySQL stores, filters and joins data
Key points
- MySQL stores web data in tables; types, keys and constraints describe and protect it.
- A handful of statements (SELECT, INSERT, UPDATE, DELETE) with WHERE, grouping, subqueries and joins covers most web needs.
- The server enforces constraints with clear errors, so design them into the schema.
-
The syllabus asks for
- Connecting and closing
- Running queries: insert, select
- Prepared statements: the only safe way
- Complete CRUD
- PDO, errors and transactions
- Error handling and good practice
- Seeing the ideas: PHP talking to MySQL
Key points
- PHP talks to MySQL through mysqli or PDO: connect, query, fetch, close, with exceptions for errors.
- Prepared statements separate SQL from data and are the defence against SQL injection.
- CRUD, pagination and transactions are small patterns repeated across every web application.
-
The syllabus asks for
- Classes, objects, constructors and destructors
- Visibility and encapsulation
- Inheritance, overriding and polymorphism
- Abstract classes, interfaces and traits
- Static members, constants and class methods
- Exceptions
- Seeing the ideas: classes, objects and contracts
Key points
- PHP objects bundle state and behaviour, with constructor promotion and visibility modifiers for encapsulation.
- Inheritance, abstract classes and interfaces give polymorphism and contracts; traits reuse code.
- Static members and the singleton pattern share state; exceptions make errors explicit.
-
The syllabus asks for
- JSON in PHP
- A PHP endpoint and a real HTTP request
- AJAX from the browser
- AJAX with PHP and MySQL
- Seeing the ideas: AJAX, JSON and REST
Key points
- AJAX updates part of a page using a background request; JSON is the usual data format.
- A PHP endpoint decodes input, validates it, uses prepared statements, and returns JSON with correct headers and status codes.
- The browser side uses fetch or XMLHttpRequest (or jQuery); output inserted into the page must be escaped.
-
The syllabus asks for
- SQL injection
- Cross-site scripting (XSS)
- Cross-site request forgery (CSRF)
- Passwords: hashing, never encryption
- A complete registration and login flow
- A security checklist
- Seeing the ideas: attacks, defences and the three factors
Key points
- Injection, XSS and CSRF all come from trusting input; each has a standard defence.
- Passwords are stored as slow salted hashes; the login flow regenerates the session ID and reveals nothing about which part failed.
- Security is a checklist applied to every form, query and output, not a feature added at the end.
-
The syllabus asks for
- What is a CMS?
- The MVC pattern
- Frameworks and tooling
- Seeing the ideas: CMS layers, MVC, hooks, autoloading and deployment
Key points
- A CMS lets non-programmers manage content; WordPress and Joomla differ in structure but share themes/templates, plugins/extensions and an admin panel on PHP and MySQL.
- MVC structures applications into model, view, controller and router; frameworks like Laravel provide the plumbing.
- Deployment adds HTTPS, secure configuration and backups.
No chapter matches. Try another word.
The paper
TU assessment: 60% final examination set by the university, 40% internal (assignments, lab work, attendance). Confirm the split in your college's notice.
Where the hours go
Teaching hours are the board's guide to how much of the paper each part carries.
- Unit 1 · Server-Side Scripting and PHP Fundamentals8 h
- Unit 2 · Forms, Files, Sessions and Cookies7 h
- Unit 3 · MySQL for Web Applications7 h
- Unit 4 · Connecting PHP to MySQL7 h
- Unit 5 · Object-Oriented Programming in PHP7 h
- Unit 6 · AJAX, JSON and Web APIs6 h
- Unit 7 · Web Application Security and Authentication4 h
- Unit 8 · Content Management Systems and PHP Frameworks4 h