Home  >  Article  >  WeChat Applet  >  How to solve the problem that real device pictures are not displayed in the WeChat applet

How to solve the problem that real device pictures are not displayed in the WeChat applet

angryTom
angryTomOriginal
2020-03-23 10:48:3710732browse

How to solve the problem that real device pictures are not displayed in the WeChat applet

How to solve the problem that the WeChat applet real machine pictures are not displayed

: During the real machine test, it was found that some local pictures can be displayed on the development tool , but it cannot be displayed when previewing on the real machine

The code is written like this



Cause and solution: The path written like this is not recognized on the real machine and needs to be written relative to the root directory

Recommended learning: Small program development

Other solutions:

If it is not a path problem , there are several other ways to find the problem:

1. The picture is loaded using image;

2. There is no Chinese in the URL of the picture;

3. HTTP should be lowercase http and the suffix of the picture should be lowercase .png or .jpg

4. The domain name has been registered;

5. The picture name has no spaces

PHP Chinese Internet, a large number of MySQL video tutorials, welcome to learn!

The above is the detailed content of How to solve the problem that real device pictures are not displayed in the WeChat applet. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn