


Because I have always been self-taught, I don’t know very well how big companies write websites. In the past, many websites were written by embedding jsp or php code into html. The node+jade method has been used before, but now the interface is provided in the background, and then Ajax is submitted to obtain the data and then displayed in the backbone template. So what is the general approach? I asked a senior at Baidu and he told me smarty, but I didn’t quite understand it either. Please give me some advice, thank you
Reply content:
Because I have always been self-taught, I don’t know very well how big companies write websites. In the past, many websites were written by embedding jsp or php code into html. The node+jade method has been used before, but now the interface is provided in the background, and then Ajax is submitted to obtain the data and then displayed in the backbone template. So what is the general approach? I asked a senior at Baidu and he told me smarty, but I didn’t quite understand it either. Please give me some advice, thank you
The reason for the separation of front-end and back-end is: in the past, websites were developed using dynamic scripts such as jsp and asp.
Mixed scripts such as jsp and asp that incorporate back-end languages, javascript, css, and html make code development and maintenance extremely inconvenient.
As front-end interactions become more and more complex, script syntax such as jsp and asp can no longer meet the needs of development.
So the concept of front-end and back-end was proposed: front-end personnel are responsible for page display and interaction, and then call the data interface written by back-end personnel through ajax.
So the core of developing a website is basically:
html + css: page display
javascript + ajax (this is part of the browser and can be called through javascript): page interaction, logic processing
Usual development framework choices:
Simple website: jquery + bootstrap
Backend management system: angularjs + jquery + bootstrap + webpack
Complex products: react + redux + webpack
Nowadays, website development is basically a model of separation of front-end and back-end. The back-end only writes interfaces, and the front-end calls interfaces, using a js template engine to render data, such as arttemplate.js. Some js module development frameworks such as sea.js will also be used.
Well, we don’t write pages now. The front-end writes the pages and puts them directly on CDN, and then calls the interface provided by our back-end to obtain the data for rendering.
smarty is a template engine used to separate the front and back ends. Its core content is MVC
M = Model
V = View
C = Controller
This question is very broad. Websites can be divided into many categories from small to large. That is to say, they are both called websites. The homepages of small shops in third-rate cities and Taobao are both called websites, but the overall development is very different.
Actually, after self-study, think more about how to realize requirements more quickly, respond to demand changes, and facilitate later maintenance. Based on this standard, which one is better? What you said is correct. There are also companies using it. At present, writing HTML directly in jsp or php should be rare. The separation of front and rear ends is on track. So how to separate them, who occupies more and who occupies less, depends on the technical level of each company. When the front-end development engineer is good, he just thinks about the front-end mvc and mvvm, and goes straight out. If the backend is awesome, I just think, you give this prototype to the backend and don’t worry about the rest.
In the question, node+jade is the backend, and backbone is the frontend. Smarty is an old template for PHP. Similar to node's jade.
So, position yourself, are you a front-end, a back-end, or a full-end? It is best to use a language more deeply first, such as Java, or Node, or PHP. You don’t have to know everything or nothing. Let’s go back and confirm what your problem is, and we’ll discuss it in detail.
Does this have anything to do with it? The routines are basically the same, maybe divided into more layers, but the essence has not changed. Just practice them all and get more practical experience. There is no difference, don’t worry about it
html + ajax
I'm not sure if the question you want to ask is what I'm going to say below. So please read carefully.
Regarding the separation of the front and backend of the website, I read the general description in the question details. It may be that the previous php code was written in html In the code, there are no pure php files (only php code in them) and html files. Here, the front and back ends are not separated, which roughly means php and html. You have me, and I have you.
But, later development We encountered many problems when we were working on it. Front-end (html, css, js) engineers may not be able to read PHP code, and PHP engineers are not very familiar with CSS content, so later people came up with a way to separate the code! This way, Everyone performs better in their respective fields, which consumes a certain amount of efficiency, but is friendly to developers from a certain perspective.
smarty template is a typical example. He puts the front desk (for users to see) ’s) backend (functions that implement user needs) are separated and given to different developers.
Smarty is a template engine implemented on the front end for the back-end code you mentioned. Ajax is an asynchronous operation to achieve front-end and back-end separation
The separation of front-end and back-end is not as complicated as said on the Internet.
First of all, you must know that all programs are based on data. A program without data has no practical meaning. The essence of a program is the addition, deletion, modification and checking of the program.
Separation of front-end and back-end is to separate data operation and display. The front-end focuses on data display, displaying the data intuitively through text, pictures, or icons. The backend focuses on data operations. The front end sends data to the back end, and the back end modifies the data.
The backend generally uses java, c# and other languages. The current node belongs to JavaScript and can also perform backend operations. There is no point in cracking the language here. The backend is used to connect to the database and operate on the data.
The backend provides an interface for the frontend to call to trigger the backend's operation of data.
The basic principle is this. The language may be inaccurate, but the thinking is correct.

译者 | 李睿审校 | 孙淑娟Web Speech API是一种Web技术,允许用户将语音数据合并到应用程序中。它可以通过浏览器将语音转换为文本,反之亦然。Web Speech API于2012年由W3C社区引入。而在十年之后,这个API仍在开发中,这是因为浏览器兼容性有限。该API既支持短时输入片段,例如一个口头命令,也支持长时连续的输入。广泛的听写能力使它非常适合与Applause应用程序集成,而简短的输入很适合语言翻译。语音识别对可访问性产生了巨大的影响。残疾用户可以使用语音更轻松地浏览

docker部署javaweb系统1.在root目录下创建一个路径test/appmkdirtest&&cdtest&&mkdirapp&&cdapp2.将apache-tomcat-7.0.29.tar.gz及jdk-7u25-linux-x64.tar.gz拷贝到app目录下3.解压两个tar.gz文件tar-zxvfapache-tomcat-7.0.29.tar.gztar-zxvfjdk-7u25-linux-x64.tar.gz4.对解

web端指的是电脑端的网页版。在网页设计中我们称web为网页,它表现为三种形式,分别是超文本(hypertext)、超媒体(hypermedia)和超文本传输协议(HTTP)。

区别:1、前端指的是用户可见的界面,后端是指用户看不见的东西,考虑的是底层业务逻辑的实现,平台的稳定性与性能等。2、前端开发用到的技术包括html5、css3、js、jquery、Bootstrap、Node.js、Vue等;而后端开发用到的是java、php、Http协议等服务器技术。3、从应用范围来看,前端开发不仅被常人所知,且应用场景也要比后端广泛的太多太多。

和它本身的轻便一样,Bottle库的使用也十分简单。相信在看到本文前,读者对python也已经有了简单的了解。那么究竟何种神秘的操作,才能用百行代码完成一个服务器的功能?让我们拭目以待。1. Bottle库安装1)使用pip安装2)下载Bottle文件https://github.com/bottlepy/bottle/blob/master/bottle.py2.“HelloWorld!”所谓万事功成先HelloWorld,从这个简单的示例中,了解Bottle的基本机制。先上代码:首先我们从b

web前端打包工具有:1、Webpack,是一个模块化管理工具和打包工具可以将不同模块的文件打包整合在一起,并且保证它们之间的引用正确,执行有序;2、Grunt,一个前端打包构建工具;3、Gulp,用代码方式来写打包脚本;4、Rollup,ES6模块化打包工具;5、Parcel,一款速度极快、零配置的web应用程序打包器;6、equireJS,是一个JS文件和模块加载器。

web有前端,也有后端。web前端也被称为“客户端”,是关于用户可以看到和体验的网站的视觉方面,即用户所看到的一切Web浏览器展示的内容,涉及用户可以看到,触摸和体验的一切。web后端也称为“服务器端”,是用户在浏览器中无法查看和交互的所有内容,web后端负责存储和组织数据,并确保web前端的所有内容都能正常工作。web后端与前端通信,发送和接收信息以显示为网页。

怎么解决高并发大流量问题?下面本篇文章就来给大家分享下高并发大流量web解决思路及方案,希望对大家有所帮助!


Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Dreamweaver CS6
Visual web development tools

SecLists
SecLists is the ultimate security tester's companion. It is a collection of various types of lists that are frequently used during security assessments, all in one place. SecLists helps make security testing more efficient and productive by conveniently providing all the lists a security tester might need. List types include usernames, passwords, URLs, fuzzing payloads, sensitive data patterns, web shells, and more. The tester can simply pull this repository onto a new test machine and he will have access to every type of list he needs.

MantisBT
Mantis is an easy-to-deploy web-based defect tracking tool designed to aid in product defect tracking. It requires PHP, MySQL and a web server. Check out our demo and hosting services.

mPDF
mPDF is a PHP library that can generate PDF files from UTF-8 encoded HTML. The original author, Ian Back, wrote mPDF to output PDF files "on the fly" from his website and handle different languages. It is slower than original scripts like HTML2FPDF and produces larger files when using Unicode fonts, but supports CSS styles etc. and has a lot of enhancements. Supports almost all languages, including RTL (Arabic and Hebrew) and CJK (Chinese, Japanese and Korean). Supports nested block-level elements (such as P, DIV),

ZendStudio 13.5.1 Mac
Powerful PHP integrated development environment
