Home > Web Front-end > HTML Tutorial > Call js function or js variable in img src='' of html to dynamically specify the image path_HTML/Xhtml_web page production

Call js function or js variable in img src='' of html to dynamically specify the image path_HTML/Xhtml_web page production

WBOY
Release: 2016-05-16 16:38:12
Original
2827 people have browsed it

I found a lot of online resources for this problem. Here are several methods. In the experiment,

Copy the code
The code is as follows:

Seaside Style, so that the JS function NextPic() can be called.

Excerpted for your convenience
Related labels:
img
source:php.cn
Statement of this Website
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template