- 这个调试错误是什么意思?什么东西没有定义吗?还是配置?麻烦大家了
[图片] wxml代码: <view class="splice-page"> <!--隐藏canvas--> <canvas canvas-id="tempCanvas" style="width:750rpx;height:{{totalHeight}}px;position:absolute;left:-999999px"></canvas> <!--保存按钮--> <view class="saveButton" wx:if="{{readuSave}}" bindtap="saveImgToPhone" style="background:url('../frame/background-pink.jpg')"> <test class="icon-save"></test></view> <!--拼长图页面--> <scroll-view scroll-y class="longImage" wx:if="{{page=='longImages'}}" style="height:{{imgViewHeight}}px"> <view class="img-wrapbox" wx:for="{{longImageSrcs}}" wx:key="*this"> <image src="{{item}}" mode="widthFix" data-idx="{{index}}" catchlongtap="gotoDelete" catchtap="quitDelete"></image> <text class="deleteTextBox" wx:if="{{whichDeleteShow==index}}" bindtap="deleteImg" style="top:50%">删除这张?</text> </view> </scroll-view> <!--拼相框页面--> <view class="photoFrame" wx:if="{{page==='photoFrame'}}" style="height:{{frameHeight}}px" bindtouchstart="uploadScaleStart" bindtouchmove="uploadScaleMove" bindtouchend="uploadScaleEnd"> <image class="frame" src="{{frameSrc}}" mode="widthFix"></image> <image class="photo" src="{{photoSrc}}" style="width:{{photoWidth}}px;height:{{photoHeight}}px;top:{{photoTop}}px;left:{{photoLeft}}px" disable-scroll="true"></image> </view> <!--拼长图页面的底部工具栏--> <view class="toolbar-bottom" wx:if="{{page==='longImages'}}"> <view bindtap="addImages"><text class="icon-listadd"></text><text class="text">添加图片</text></view> </view> <!--相框页面的底部工具栏--> <view class="toolbar-bottom" wx:if="{{page==='photoFrame'}}"> <view bindtap="addFrame"><text class="icon-frame"></text><text class="text">选择相框</text></view> <view bindtap="addPhoto"><text class="icon-photo"></text><text class="text">添加照片</text></view> </view> <!--相框选择窗口--> <view class="frameChoose" wx:if="{{isFrameChoose}}"> <view class="frameChoose-top"><text class="farmeChoose-top-left">选择相框</text><text class="farmeChoose-top-right" bindtap="closeFrameChoose"></text> </view> <scroll-view scroll-y> <view wx:for="{{frameSrcs}}" wx:key="*this" data-src="{{item.src}}" class="frameBox" bindtap="chooseFrame"> <image src="{{'../frame'+item.src}}" mode="aspectFit"></image><text>{{item.title}}</text> </view> </scroll-view> </view> </view> 调试错误: VM56 WAService.js:2 TypeError: Cannot read property 'windowWidth' of undefined at vt.onLoad (index.js? [sm]:27) at vt.<anonymous> (VM56 WAService.js:2) at vt.r.__callPageLifeTime__ (VM56 WAService.js:2) at nn (VM56 WAService.js:2) at VM56 WAService.js:2 at cn (VM56 WAService.js:2) at Function.<anonymous> (VM56 WAService.js:2)
2021-04-17 - 小程序代码在WXSS中添加样式的背景图片一定要是base64或者svg吗?麻烦大家了
[图片] 如果不用WXSS添加每个地方的背景图片在wxml中怎么添加呀? WXSS代码部分样式: .saveButton .icon-save{ /*background-image: url("data:https://images-1304802581.cos.ap-guangzhou.myqcloud.com/frame/background-pink.jpg");*/ background-size: cover; display: inline-block; width: 60rpx; height: 60rpx; } .saveButton:active .icon-save{ background-image:"https://images-1304802581.cos.ap-guangzhou.myqcloud.com/frame/background-pink.jpg"; } 编译错误是: [ WXSS 文件编译错误] ./pages/fabu/index.wxss unexpected "�" at pos 260 13 | /*z-index: 5;*/ 14 | } > 15 | .saveButton .icon-save{ | ^ 16 | /*background-image: url("data:https://images-1304802581.cos.ap-guangzhou.myqcloud.com/frame/background-pink.jpg");*/ 17 | background-size: cover; 18 | display: inline-block; at files://pages/fabu/index.wxss#15
2021-04-16 - 小程序代码 wxml出现 unexpected character 调试错误?路过帮解决,谢谢了
[图片] wxml代码如下: <view class='box'> <view class='title'>点一点图片/摇一摇手机,获取随机签</view> <view> <image src="{{imgArr[index]}}" bindtap="changeFace" mode='widthFix'></image> </view> </view> wxss代码如下: .image { margin: 15px; } 调试错误: [图片]
2021-04-15