Shopify添加快递查询网页

Blog3年前更新 跨境柒仔
6,166 00

在Shopify后台添加一个新的自定义页面,点击编辑代码按钮,将下面代码复制粘贴保存页面,添加到首页导航即可

<div style="text-align: center;">

<input type="text" id="YQNum" placeholder="Your package number" maxlength="50" />
<input type="button" id="kjdzd" value="TRACK" onclick="doTrack()" />
<div id="YQContainer"></div>
</div>
<style type="text/css"><!--
#YQNum{
border-top-right-radius: 0;
border-bottom-right-radius: 0;
border:1px solid black;
width:200px;
height:35px;
}
#YQNum:hover{
border:1px solid #f40;
}
#kjdzd{
width:80px;
height:35px;
background-color:#f80;
color:white;
border:0px solid black;
}
--></style>
<div style="text-align: center;">
<script type="text/javascript" src="//www.17track.net/externalcall.js"></script>
<script type="text/javascript">// <![CDATA[
function doTrack() {
var num = document.getElementById("YQNum").value;
if(num===""){
alert("Enter your number.");
return;
}
YQV5.trackSingle({
YQ_ContainerId:"YQContainer",
YQ_Height:560,
YQ_Fc:"0",
YQ_Lang:"en",
YQ_Num:num
});
}
// ]]></script>
</div>

© 版权声明

相关文章