html - 如何在 JSP 中将值传递给 html?
问题描述
我试图将值,lottie json url 传递给 html。但它不起作用。但是当我直接在html“src”中写lottie url时,它可以工作。这段代码有什么问题?先感谢您
[js文件]
test : function () {
$("#lottie1").attr('src', "https://assets5.lottiefiles.com/datafiles/zc3XRzudyWE36ZBJr7PIkkqq0PFIrIBgp4ojqShI/newAnimation.json")
}
[html文件]
<td width="300" height="200">
<lottie-player id="lottie1" src="" background="transparent" style="width: 300px; height: 225px;" speed="1" loop autoplay>
</lottie-player>
</td>
解决方案
推荐阅读
- amazon-s3 - 如何创建用于在 Web 前端中显示大型数据集的后端
- powershell - 在 PowerShell 中为多种语言更改键盘布局
- reactjs - 在 reactjs 中渲染不同组件时更改组件的样式
- c++ - std::chrono::years 存储真的至少 17 位吗?
- oauth-2.0 - 邮递员在针对 Keycloak 服务器的 OAuth2 流中使用错误(废话?)代码
- google-data-studio - Google 数据洞察:创建排名维度
- java - 为什么人们 gitignore .classpath 和 .project?
- ios - appium 检查器中 IOS 13.3 中的定位器问题?
- qt - QtQuick 或 QtWidget
- jquery - 在 Angular 8 中集成 jQuery 控件