如何使用jsp将数据库连接到html? [英] how database can be connected to html using jsp ?

查看:72
本文介绍了如何使用jsp将数据库连接到html?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何使用jsp将数据库连接到html?

how database can be connected to html using jsp ?

推荐答案

你的问题让我摆动:)好像你刚刚开始编程。



数据库没有使用JSP连接到HTML。相反,流程就像



* JSP接收浏览器请求

* JSP使用一些连接字符串连接到数据库

* JSP使用来自数据库的数据发送HTML代码并发送回浏览器

*浏览器将HTML显示回用户



JSP几乎已经过时了。有MVC框架可以隔离和简化以上流程。



我给你的建议是从一本好的基础书开始
Your question made me swing :) Seems like you have just started programming.

Well database do not connect to HTML using JSP. Rather the flow is like

* JSP receives browser request
* JSP connects to Database using some connection string
* JSP emit HTML code using the data comes from Database and send back to the browser
* Browser shows the HTML back to the user

JSP is almost obsolete. There are MVC framework available that have isolated and simplified above flow.

My advice to you is to start with a good fundamental book


这篇关于如何使用jsp将数据库连接到html?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆