Web Browser as generic Client

The web browser maintains a Document Object Model (DOM) for each window, along with Cascading Style Sheet (CSS), that describes what should be rendered. 

The DOM is constructed from a Web document such as a HTML document. It may contain JavaScript scripts, or link to them, that are loaded and executed in a JavaScript Engine.

The engine can manipulate DOM, receive user events from the browser window and make Web requests for data.


Document Object Model (DOM)

DOM as a platform and language-neutral interface that allows programs and scripts to dynamically access and update the content, structure, and style of a document. Everything in a page is a node or part of the DOM tree.

The DIV (division) tag is used to provide a node in the DOM tree.


JavaScript (JS)

JS is a scripting language. It is created in 1995, from NS LiveScript.

JS can be used to:

1) validate user input in an HTML form before sending the data to a server;

2) build form that respond to user input without accessing a server;

3) change the appearance of HTML documents and dynamically write HTML into separate Windows;

4) open and close new browser windows or frames

5) manipulate HTML "layers" including hiding, moving and allowing the users to drag them around a browser window;

6) build small but complete client side programs


JavaScript combines with HTML and CSS.

Modern Web Sites and Application: HTML: Page Structure and Content. Base level interactivity.

      CSS: Page Design/ Look and feel. Simple interactivity.

      JavaScript: Scriptable page manipulation. High level interactivity.


SCRIPT tag: to let a browser know that part of an HTML document is JavaScript, enclose it inside the HTML SCRIPT tags.


SCRIPT files: Scripts can also be included from files, that define functions and then called.


JavaScript Libraries

While you can design and develop applications directly in JavaScript, there are many existing JavaScript libraries. A common library suite is jQuery:

1) jQuery library: HTML document traversal and manipulation, event handling, animation and Ajax;

2) jQuery UI library: user interface interactions, effects, widgets and themes;

3) jQuery Mobile library: user interface system for popular mobile device platforms


Document Ready

When a Web browser is interpreting a Web document, it (loads and) executes scripts as they are found in the document. This is okay for variable declarations and function definitions but not so safe for code that manipulates the DOM. The scripts may refer to elements of the DOM that have not yet been created by the document because they appear later in the Web document. Generally it is safest to only execute code when the document is ready.

The code insider the handler can assume that the entire DOM is ready to be accessed. The handler can proceed to prepare global variables, attach callbacks to events, retrieve more data from the web server, etc.


Selectors

Much of manipulating the DOM is concerned with selecting DOM elements.


Events

Events that occur in the browser window can be handled by JavaScript functions. 


Modifying CSS

CSS properties can be required and modified.


Time Events

JavaScript is not threaded, events can be set to be triggered after a certain timeout or at regular intervals.


Functions

Functions can be defined with any number of arguments.


Objects

Objects are constructed using the new keyword by using functions or existing object constructions.




  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
毕业设计,基于SpringBoot+Vue+MySQL开发的精简博客系统,源码+数据库+毕业论文+视频演示 当下,正处于信息化的时代,许多行业顺应时代的变化,结合使用计算机技术向数字化、信息化建设迈进。以前企业对于博客信息的管理和控制,采用人工登记的方式保存相关数据,这种以人力为主的管理模式已然落后。本人结合使用主流的程序开发技术,设计了一款基于Springboot开发的精简博客系统,可以较大地减少人力、财力的损耗,方便相关人员及时更新和保存信息。本系统主要使用B/S开发模式,在idea开发平台上,运用Java语言设计相关的系统功能模块,MySQL数据库管理相关的系统数据信息,SpringBoot框架设计和开发系统功能架构,最后通过使用Tomcat服务器,在浏览器中发布设计的系统,并且完成系统与数据库的交互工作。本文对系统的需求分析、可行性分析、技术支持、功能设计、数据库设计、功能测试等内容做了较为详细的介绍,并且在本文中也展示了系统主要的功能模块设计界面和操作界面,并对其做出了必要的解释说明,方便用户对系统进行操作和使用,以及后期的相关人员对系统进行更新和维护。本系统的实现可以极大地提高企业的工作效率,提升用户的使用体验,因此在现实生活中运用本系统具有很大的使用价值。 关键词:博客管理;Java语言;B/S结构;MySQL数据库
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值