[Small number] program and the public Failed to load local image resource ... the server responded with a status of 500

Problems encountered in the development of: image loading out, but reported this error in the micro-channel development tools:
Here Insert Picture Description

I looked at the question of when we see problems arise mostly described it this way:

Failed to load image xxx the server responded with a status of 404 (HTTP/1.1 404 Not Found) 
From server 127.0.0.1

But the problem is the nature of the micro-channel development tools mainly because:

Initialization of variables have not rendered into

So at this time you need to add in front of src wx:ifto render. Specific examples:

<image 
class="tip-image" 
wx:if='{{nowInfo.now.code}}' 
bindtap='refreshPage' 
src="../../image/wxfox/{{shareImage}}.png"
>
</image> 
Published 134 original articles · won praise 80 · views 30000 +

Guess you like

Origin blog.csdn.net/Umbrella_Um/article/details/103319664