把html设置为桌面项目
This tutorial series will guide you through creating and further customizing this website using HTML, the standard markup language used to display documents in a web browser. No prior coding experience is necessary but we recommend you start at the beginning of the series if you wish to recreate the demonstration website.
本教程系列将指导您使用HTML(用于在Web浏览器中显示文档的标准标记语言)创建和进一步自定义此网站 。 不需要任何编码经验,但是如果您希望重新创建演示网站,建议您从本系列的开头开始 。
At the end of this series, you should have a website ready to deploy to the cloud and a basic familiarity with HTML. Knowing how to write HTML will provide a strong foundation for learning additional front-end web development skills, such as CSS and JavaScript.
在本系列的最后,您应该拥有一个可以部署到云的网站,并且对HTML有了基本的了解。 知道如何编写HTML将为学习其他前端Web开发技能(例如CSS和JavaScript)奠定坚实的基础。
The first thing to do when creating a new website project is to create a project directory (or folder) to store all the files that will be created in the process. This tutorial will walk you through the steps of setting up folders and files necessary for building your website with HTML.
创建新的网站项目时,要做的第一件事是创建一个项目目录(或文件夹)来存储将在此过程中创建的所有文件。 本教程将引导您完成设置文件夹和文件的步骤,这些文件夹和文件是使用HTML构建网站的必要步骤。
For this website project, we can continue using the html-practice
project directory and index.html
file we created earlier in the tutorial series. (If you have not been following along this tutorial series and need instructions for setting up a project directory and index.html
file, please see our earlier tutorial in this series Setting Up Your HTML Project.
对于此网站项目,我们可以继续使用我们在本系列教程前面创建的html-practice
项目目录和index.html
文件。 (如果您还没有一起设立一个项目目录,本系列教程和说明需要以下index.html
文件,请参阅本系列我们之前的教程设置你HTML项目 。
Note: If you decide to choose your own name for the directory, make sure to avoid character spaces, special characters (such as !, #, %, or others), and capital letters, as these can cause problems later on.
注意 :如果您决定为目录选择自己的名称,请确保避免使用字符空格,特殊字符(例如!,#,%或其他)和大写字母,因为它们以后可能会引起问题。
Next, we’ll format the index.html
file to serve as the website’s homepage. The first step in formatting a web document is to add the <!DOCTYPE html>
declaration to the first line. Make sure your index.html
file is clear and then add <!DOCTYPE html>
to the first line of the document.
接下来,我们将格式化index.html
文件以用作网站的主页。 格式化Web文档的第一步是将<!DOCTYPE html>
声明添加到第一行。 确保您的index.html
文件是清除的,然后将<!DOCTYPE html>
添加到文档的第一行。
This declaration tells the browser which type of HTML is being used and is important to declare as there are multiple versions of HTML. In this declaration, html
specifies the current web standard of HTML, which is HTML5.
该声明告诉浏览器正在使用哪种类型HTML,并且由于存在多个HTML版本,因此声明非常重要。 在此声明中, html
指定html
的当前Web标准,即HTML5。
Next, we’ll add the <html>
element by adding opening and closing <html>
tags. The <html>
element tells the browser that all content it contains is intended to be read as HTML. Your document should now look like this:
接下来,我们将通过添加打开和关闭<html>
标签来添加<html>
元素。 <html>
元素告诉浏览器它包含的所有内容都应阅读为HTML。 您的文档现在应如下所示:
<!DOCTYPE html>
<html>
</html>
From this point forward, all content that we add to our website will be added between the opening and closing <html>
tags.
从现在开始,我们添加到我们网站的所有内容将添加在开始和结束<html>
标签之间。
We will begin adding content to our site in the next tutorial.
在下一个教程中,我们将开始向我们的网站添加内容。
翻译自: https://www.digitalocean.com/community/tutorials/how-to-set-up-your-html-website-project
把html设置为桌面项目