What you should know?

Download Report

Transcript What you should know?

Web Design II
PHP & MySQL or ASP.NET
Welcome
Year 1, 2nd semester
IT Course
Lecturer: MSc. Prak Samrith, London, UK
Agenda
1. Revision on CSS
2. Revision on JavaScript and its objects
3. How to host your website locally & Remotely
4. Image optimization & formats of choice for web
5. Introduction to Server Side Scripting
1. Revision on CSS
- CSS Selectors
- the Fonts
- CSS Links
Samples on W3Schools:
http://www.w3schools.com/css/css_syntax.asp
2. Revision on JavaScript
and its objects
- Good sample of JavaScript
http://www.w3schools.com/js/tryit.asp?filename=tryjs_intro_lightbulb
- Can be on Head and Body sections of HTML page inside script tag
<html><head>
<script>
function myFunction() {
document.getElementById("demo").innerHTML = "Paragraph changed.";
}
</script>
</head>
<body>
2. Revision on JavaScript
and its objects
Also can put in external file
Eg. myScript.js
<html>
<body>
<script src="myScript.js"></script>
</body>
</html>
2. Revision on JavaScript
and its objects
Examples of JavaScript is on W3Schools
http://www.w3schools.com/js/js_whereto.asp
Using window.alert()
http://www.w3schools.com/js/js_output.asp
3. How to host your website
locally & Remotely
- Local Machine: Install Web server
Eg. Windows IIS or XAMPP
-Remote Hosting: register for FREE or paid web
hosting
-Eg. https://www.000webhost.com/
-http://www.godaddy.com
4. Image optimization &
formats of choice for web
- Use image editing tool or software to optimize images
Eg. Adobe Photoshop (Mac OS, Windows)
Gimp (all OSs)  FREE
-Format: GIF is good because of small size
- JPEG is good in term of quality and better optimize
- PNG format is also very good for HD image
4. Image optimization &
formats of choice for web
-in Adobe Photoshop use the Save for Web & Devices to get
the best image for your web page
5. Introduction to Server
Side Scripting
Server-side Environment
The server-side environment that runs a scripting language is a web server.
- running a script directly on the web server to generate HTML pages. This HTML is
then sent to the client browser.
- interface to databases or other data stores on the server.
- different from client-side scripting where scripts are run by the viewing web
browser, usually in JavaScript.
- highly customize the response based on the user's requirements, access rights, or
queries into data store
Reference: http://www.sqa.org.uk/e-learning/ClientSide01CD/page_18.htm
5. Introduction to Server
Side Scripting
Example of Server Side Scripting languages:
- PHP (we learn this semester)
- ASP.NET: from Microsoft
- Perl: old language
- Python: new and getting popular
- Java: not JavaScript, this is different
Contact Info
• Tel: 012 79 53 57 (urgent only)
• Email: [email protected]
• Web: www.praksamrith.com
• Facebook page: Prak Samrith
What you are expected to learn during this course
In this course, you will gain a foundational knowledge of :
1. Writing Server Side scripting using PHP programming language
2. How to run PHP & MySQL on your Windows PC
3. Writing some simple ASP.NET scripting blocks and run on IIS servers
4. Manage & create simple MySQL Database
5. be able to apply it to the planning, designing and development of your own website.