10亿+海关交易数据,1.2亿企业数据,2亿+企业联系人数据,1000千万真实采购商。覆盖200+个国家及地区,95%外贸重点拓展市场,可根据行业、经营范围等多方位挖掘目标客户。
免费试用在 Shopify 后台中,转到在线商店 > 模板。
找到您要编辑的模板,然后点击操作 > 编辑代码。
在 Assets 目录中,点击添加新资产。
点击选择文件,以浏览到您计算机上的新礼品卡图片并上传。我们建议使用简单的文件名,例如 blue-giftcard.png
。
提示:礼品卡图片的建议大小为 950 × 550 像素(您还可以使用 5:3 的纵横比或最小尺寸 450 x 270 像素)。
点击上传资产。新的礼品卡图片将显示在您的 Assets 目录中。请记下文件扩展名(.png
或 .jpg
)。
在 Templates 目录中,点击 gift-card.liquid
。
在该文件中查找以下代码:
liquid
<img src="{{ 'gift-card/card.jpg' | shopify_asset_url }}" alt="">
将它替换为以下代码:
liquid
<img src="{{ 'blue-giftcard.png' | asset_img_url: '1024x1024' }}" alt="">
点击保存。
备注:请确保根据需要将 blue-giftcard.png
更改为新图片的文件名和扩展名。
在模板代码编辑器中,点击右上角的自定义模板。
打开模板编辑器。
在页面顶部的下拉菜单或在移动设备上的模板菜单中,选择礼品卡。
Shopify商户官网原文详情:
Personalize gift cards with a custom image
Upload a new image for your gift card
From your Shopify admin, go to Online Store > Themes.
Find the theme you want to edit, and click Actions > Edit code.
In the Assets directory, click Add a new asset.
Click Choose File to browse to the new gift card image on your computer and upload it. We suggest using a simple filename, for example
blue-giftcard.png
.Click Upload asset. The new gift card image will appear in your Assets directory. Take note of the file extension (
.png
or.jpg
).Edit the gift card template file so that it uses your new image
In the Templates directory, click
gift-card.liquid
.Find the following code within the file:
<img src="{{ 'gift-card/card.jpg' | shopify_asset_url }}" alt="">Replace it with the following:
<img src="{{ 'blue-giftcard.png' | asset_img_url: '1024x1024' }}" alt="">Click Save.
Preview your new gift card image
From the theme code editor, in the top right-hand corner, click Customize theme.
Open the theme editor.
From the drop-down menu at the top of the page, or from the Templates menu on mobile, select Gift card.
文章内容来源:Shopify商户官方网站
(本文内容根据网络资料整理和来自用户投稿,出于传递更多信息之目的,不代表本站其观点和立场。本站不具备任何原创保护和所有权,也不对其真实性、可靠性承担任何法律责任,特此声明!)
礼品卡使用的图片格式需要是JPG、JPEG或PNG格式,大小建议在200KB以下。
如何上传自定义图片?登录商城后台管理系统,进入“产品”选项卡,选择需要设置图片的礼品卡,点击“编辑”按钮,选择“添加图片”选项,选择上传图片文件即可。
图片设置位置有哪些?主要有三个位置可以设置图片:卡面图片、卡内图片与卡背图片。卡面图片设置在卡片正面展示,卡内图片设置在卡片内页展示,卡背图片设置在卡片反面展示。
是否可以设置图片链接?是的,您可以给图片设置链接。在上传图片后,系统会自动生成图片链接地址,您可以修改这个链接地址,将图片设置点击后跳转到您想要的页面。
如何设置卡片样式?您可以登录后台的“产品”页面,选择需要设置样式的礼品卡,点击编辑按钮,选择“样式”选项进行卡片样式设置,包括卡片尺寸、背景颜色等。