-------- Page 1 (JavaScript Basics-01.jpg) --------- University of Tripoli Faculty of Information Technology Department of Software Engineering JavaScript Basics Introduction to Internet Programming ITGS 226 -- F2023 By: Fatima Ben Lashihar -------- Page 2 (JavaScript Basics-02.jpg) --------- INTRODUCTION • JavaScript is the most popular and widely used client-side scripting language. • JavaScript is designed to add interactivity and dynamic effects to the web pages by manipulating the content returned from a web server. • JavaScript is an object-oriented language, and it also has some similarities in syntax to Java programming language. But, JavaScript is not related to Java in any way. -------- Page 3 (JavaScript Basics-03.jpg) --------- What can do with Javascript • Modify the content of a web page by adding or removing elements (Example) • Change the style and position of the elements on a web page (Example) • Monitor events like mouse click, hover, etc. and react to it (Example) • Create alert pop-ups to display info or warning messages to the user (Example) • Validate user inputs before submitting it to the server (Example) 3 -------- Page 4 (JavaScript Basics-04.jpg) --------- ADDING JAVASCRIPT TO WEB PAGES • There are typically three ways to add JavaScript to a web page: 1. Embedding (internal) the JavaScript code between a pair of tag. 2. Creating an external JavaScript file with the .js extension and then load it within the page through the src attribute of the tags. • The