Shopify后台生产力工具:富文本编辑器

使用富文本编辑器插入音频文件

您可以使用富文本编辑器在博客文章、页面、产品描述和产品系列描述中插入或嵌入音频文件。

步骤:

1.在 Shopify 后台,点击设置,然后点击文件。

2.点击上传文件,上传要在商店中插入或嵌入的音频文件。

3.从在线商店部分中,为想包含该音频文件的页面或博客文章打开富文本编辑器。

4.复制 <div id="player"><audio controls="controls">,然后将代码粘贴在富文本编辑器中,以在您的页面上嵌入音频播放器。

5.复制以下代码:

<source src="https://cdn.shopify.com/s/files/1/0220/2378/files/example.mp3" type="audio/mpeg" /></div>

在富文本编辑器中,将此代码粘贴至音频播放器代码之后,然后将 https://cdn.shopify.com/s/files/1/0220/2378/files/example.mp3 替换为您将音频文件上传至 Shopify 时为该音频文件创建的 URL。您随时都可在文件页面上找到音频文件的 URL。

6.单击保存。

7.点击查看以确保您的音频文件可正常播放。

提示:

您可以直接从 Soundcloud 嵌入音频文件的代码,但 Soundcloud 的音频播放器可能无法在所有设备上都能正常工作。

在富文本编辑器中添加或删除内部注释

您可以对不想发布到商店的内部文本使用注释标记 <!-- 和 -->。

步骤:

  1. 在富文本编辑器中,点击显示 HTML 按钮。

  2. 若要添加内部注释,请将要隐藏的文本括在 <!-- 和 --> 之中。例如:<!--yourtext-->。

  3. 单击保存。

包含在注释标记中的 HTML 标记将另存为内部文本。为了使这些 HTML 标记正常工作,您需要删除其两边的注释标记 <!-- 和 -->。

Shopify商户官网原文详情:

Insert audio files with the rich text editor

You can use the rich text editor to insert or embed audio files in blog posts, pages, product descriptions, and collection descriptions.

Steps:

1.From your Shopify admin, click Settings, then click Files.

2.Click Upload files to upload the audio file you want to insert or embed in your store.

3.From the Online Store section, open the rich text editor for the page or blog post you want to feature the audio file.

4.Copy <div id="player"><audio controls="controls">, then paste the code in the rich text editor to embed an audio player on your page.

5.Copy the following code:

<source src="https://cdn.shopify.com/s/files/1/0220/2378/files/example.mp3" type="audio/mpeg" /></div>

Paste this code in your rich text editor after the code for the audio player, and then replace https://cdn.shopify.com/s/files/1/0220/2378/files/example.mp3 with the URL you created for your audio file when you uploaded it to Shopify. You can find your audio file's URL at any time on the Files page.

6.Click Save.

7.Click View to make sure your audio file plays correctly.

Tip

You can embed code for audio files directly from Soundcloud, but Soundcloud's audio player might not function correctly on all devices. 

Add or remove internal comments in the rich text editor

You can use comment tags <!-- and --> for internal text that you don't want to publish to your store.

Steps:

  1. In your rich text editor, click the Show HTML button.

  2. To add an internal comment, enclose the text that you want to keep hidden within <!-- and -->. For example: <!--yourtext-->.

  3. Click Save.

HTML tags that are enclosed within the comment tags are saved as internal text. For those HTML tags to work properly, you need to remove the comment tags <!-- and --> around them.

文章内容来源:Shopify商户官方网站 

(本文内容根据网络资料整理,出于传递更多信息之目的,不代表连连国际赞同其观点和立场)