CSC101 (1-2 Week)
CSC101 (1-2 Week)
Development
– Good luck
Introduction to Web Development
• Week 1
• What is Web Development?
Week1: Introduction to Web Development
• Web Applications
• Title: What are Web Applications?
• Definition: Applications that run in a web browser,
accessible over the internet.
• Key Features:
– Accessible from any device with internet and a browser.
– No installation required, available immediately via URLs.
– Auto-updates—updates are deployed to the server and are
instantly available to users.
• Examples:
– Google Docs (online word processing)
– Facebook, Twitter (social media)
Week1: Introduction to Web Development
Client-Side Server-Side
Aspect
Programming Programming
Runs on the Runs on the web
Execution
user’s browser server
HTML, CSS, Node.js, PHP,
Languages
JavaScript Python, Ruby
User interface Business logic,
Role
and interaction data management
Depends on the Depends on
Performance
user's device server capacity
Typically more
Vulnerable to
Security secure, server-
client-side attacks
controlled
Form validation Database queries,
Examples
(JS), Animations user login
Week1: Introduction to Web Development
• Summary
– Web development involves building applications that run
on browsers using technologies like HTML, CSS, and
JavaScript.
– Web Applications: Accessible anywhere, no installation
required, and automatically updated.
– Traditional Applications: Installed locally on a device,
require manual updates, and are OS-specific.
– Modern Web Architecture: Client-server model with
APIs, cloud services, and scalable databases.
Week1: Introduction to Web Development
• ASSIGNMENT
– How does web development improve accessibility
compared to traditional applications?
– What are the key reasons businesses and developers are
shifting to web applications over traditional software?
– Can you think of any hybrid applications that work both
offline and online?
Overview of Web Programming Languages
• Week 2
• Overview of Web Programming
Languages
Week 2 – Setting up a Development
Environment
• Setting Up a Web Development Environment
• Text Editors:
– Choose a powerful text editor to write and manage your
code.
– Popular options:
• Visual Studio Code: Free and feature-rich with extensions.
• Sublime Text: Lightweight and customizable.
• Atom: Open-source with GitHub integration.
• Browsers for Testing:
– Use modern browsers for development:
• Google Chrome: Includes Chrome Developer Tools for debugging.
• Firefox: Developer-friendly features.
• Safari and Edge: Additional testing for compatibility.
Week 2 – Basic Structure of HTML, CSS,
JavaScript
• HTML (Hypertext Markup Explanation
Language) is used to structure
content on the web. <!DOCTYPE html>: Declares the
• Basic Structure of an HTML document type.
Document: <html>: Root element of the
• <!DOCTYPE html> page.
<html>
<head> <head>: Contains meta-
<title>My First Web Page</title> information, such as the title.
<style></style> <body>: Contains the visible
<script></script>
content (e.g., headings,
</head>
<body> paragraphs).
<h1>Welcome to My Website</h1>
<p>This is my first paragraph.</p>
</body> </html>
Week 2 – Basic Structure of HTML, CSS,
JavaScript
Week 2 – Running Your HTML, CSS, and
JavaScript in Browsers
• How to Run HTML, CSS, and JavaScript:Create a New HTML
File:
– Save your HTML code with a .html extension (e.g., index.html).
• Open in a Web Browser:
– Open the .html file in your browser (double-click the file or right-
click and choose Open with).
• Link CSS and JavaScript:
– CSS: Add a <style> tag in the <head> section.
– JavaScript: Use a <script> tag at the bottom of the <body> section.
• Check the Results:
– Observe how HTML structures the content, CSS styles it, and
JavaScript adds interactivity.
Week 2 – Overview of Web Programming
Languages
• Core Web Programming Languages
• Example
• HTML (Hypertext Markup
Language): • HTML: <h1>Welcome
– Structures the content of web pages.
– Defines elements like headings, to My Website</h1>
paragraphs, images, and links.
• CSS (Cascading Style Sheets): • CSS: h1 { color: blue;
– Adds styling and layout to HTML
content.
text-align: center;}
– Controls colors, fonts, spacing, and
positioning.
• JAVASCRIPT:
• JavaScript: document.getElement
– Adds interactivity and dynamic
features to web pages.
ById("demo").innerHT
– Manipulates HTML and CSS in real-
time.
ML = "Hello World!";
Week 2 – Role of HTML in Web
Development
• HTML: The Structure of Web Pages
• Purpose:
– Defines the structure and content of web pages.
– HTML elements are the building blocks of web pages.
• Common HTML Elements:
Headings: <h1> to <h6>
Paragraphs: <p>
Images: <img>
Links: <a>
Lists: <ul>, <ol>, <li>
Tables: <table>
Week 2 – HTML, CSS, JavaScript, Running and
Testing Code in Browsers
• Writing Code in CSS Explanation;
• CSS (Cascading Style Sheets) • Selectors (e.g., h1, p): Target
is used to style HTML HTML elements to apply
content.
styles.
• Basic CSS Example:
h1 {
• Properties (e.g., color, font-
color: blue; family, text-align): Specify the
font-family: Arial, sans-serif; styles.
text-align: center;
}
• Values (e.g., blue, Arial,
p{ center): Define the specific
font-size: 16px; style settings.
line-height: 1.5;
Week 2 – Role of JavaScript in Web
Development
document.addEventListener('DOMCon
tentLoaded', function() {
Week 2 – Testing Code in Web Browsers
• What is Debugging?
• Debugging is the process of finding and fixing errors (bugs) in your
code.
• Common issues: syntax errors, logic errors, and runtime errors.
• How to Debug HTML, CSS, and JavaScript:
• View the Console:
– Use browser Developer Tools (right-click and choose Inspect) to open the
console.
• Check the DOM:
– Use the Elements tab in DevTools to inspect your HTML structure.
– See how CSS styles are applied and override them in real-time.
• Fix the Code:
– Use the information from DevTools to identify and fix issues in your code.
Week 2 – Testing Code in Web Browsers
• Summary
• Key Web Technologies:
– HTML provides structure.
– CSS adds style.
– JavaScript enables interactivity.
• Setting Up a Development Environment:
– Use text editors like Visual Studio Code to write and organize code.
– Test your web applications in modern browsers with developer tools.
• Writing Code: You’ve learned how to write and organize code
using HTML, CSS, and JavaScript.
• Running Code: You know how to run and test code in web
browsers.
• Debugging: You’ve been introduced to debugging tools and
Week 2 – Assignment
On a 2-page A4 paper, design this login page, print out the
webpage design on 1page and print the code with your name
boldly written on it on another page.