Home >Development Tools >sublime >How to run html in sublime

How to run html in sublime

下次还敢
下次还敢Original
2024-04-03 17:39:201093browse

How to run HTML files in Sublime Text: Open the HTML file in Sublime Text. Press Ctrl B (Windows) or Cmd B (Mac) to load and display the HTML page using your default browser. You can use a different browser path with a custom build system by going to Build System in the Tools menu. Select "New Build System". Enter a custom name and command (for example, using Internet Explorer: "C:\Program Files\Int

How to run html in sublime

How to run HTML in Sublime Text

Running an HTML file

To run an HTML file, use the following steps:

  1. Open the HTML file in Sublime Text.
  2. Press Ctrl B (Windows) or Cmd B (Mac) to run the HTML file.

This will load and Display an HTML page.

Custom run command

Although the shortcut keys Ctrl B or Cmd B are standard for running HTML files method, but you can also customize the run command:

  1. In Sublime Text, go to "Build System" in the "Tools" menu.
  2. Select "New Build System" .
  3. Enter a custom name (for example, "HTML Runner") in the "Name" field.
  4. Enter the following command in the "Command" field:
<code>"C:\Program Files\Internet Explorer\iexplore.exe" %path</code>

Replace it with your browser path.

  1. Click the "Save" button to save the build system.

Now, you can save the build system via the "Tools" menu "Build System" Select a custom build system to run HTML files using custom commands.

The above is the detailed content of How to run html in sublime. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn