Comments (8)
这是本地图片?
from mp-html.
这是本地图片?
这个是编辑器里面上传的图片 保存的路径是相对路径
from mp-html.
这是本地图片?
我在trees.wxml里面把data-src的路径补充完整,DomHandler.js里面的
if (attrs['data-src']) {
attrs.src = attrs.src || attrs['data-src'];
delete attrs['data-src'];
}
好像不起作用 不知道是什么原因
from mp-html.
那个是在没有src时把data-src赋给src,有src的时候就不起效果了;而且wxml里的data-src是用来点击预览用的;没有办法直接把src补充完整吗?
from mp-html.
在后端加强包里是可以通过设置domain来自动把src补全的,前端插件包暂时还没有这样的功能
from mp-html.
那个是在没有src时把data-src赋给src,有src的时候就不起效果了;而且wxml里的data-src是用来点击预览用的;没有办法直接把src补充完整吗?
这倒是个办法 我去看一下编辑器 有没有办法把编辑器保存的图片路径变成绝对路径
from mp-html.
不行的话我觉得暂时可以用正则替换上去😂(反正一定要有完整的地址才能显示)
html=html.replace(/src="\//g,'src="http://xxx.com/')
from mp-html.
不行的话我觉得暂时可以用正则替换上去😂(反正一定要有完整的地址才能显示)
html=html.replace(/src="\//g,'src="http://xxx.com/')
也对哦 我怎么没想到 太感谢啦🙏
from mp-html.
Related Issues (20)
- 支付宝小程序中,分包中的文件,使用组件时无法显示内容;主包中可以正常展示;
- 图片数量过多时,微信小程序显示没有问题,H5和App会出现个别图片显示慢或者裂图问题
- loadingImg的大小如何设置呢? HOT 1
- 支付宝图片设置宽高后被解析为mode=""导致显示不出来 HOT 4
- taro3.6.5 react mp-html无法显示内容 HOT 2
- span标签设置text-align: justify 两端未对齐 HOT 1
- td 样式解析异常问题
- 富文本中的video标签的视频无法播放 HOT 1
- 关于新版将不支持getSystemInfo,不知道能否改成getSystemInfoAsync HOT 3
- Vue3 + App安卓模拟器报错 Cannot access 'node' before initialization
- 需要渲染的HTML中有iframe标签的话 没有渲染出来 是有相关的设置项吗 还是没有判断这个标签啊 HOT 1
- 如果div下仅包含一些没有标签的文字和一个table则无法识别到这个table标签
- 在mp-html外面包了一层scroll-view的锚点定位问题 HOT 3
- plus is not defined HOT 4
- 渲染时间太长
- 微信小程序保存图片到本地提示保存失败
- 使用表情后,页面渲染错误。 HOT 3
- iOS真机未渲染tag-style定义的table的border样式
- uni-app包微信端小程序部分富文本内容特殊符号会报错replace of null HOT 1
- 微信小程序渲染解析以下格式的html异常包含(sgv animate) HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mp-html.