
images returned, but the front end under the separation of the ajax request picture, I won't have bosses teach it to me
CodePudding user response:
What is you return to the format of the picture is the url of the picture? If it is you in success method to img SRC assignment controls
CodePudding user response:
$(" # "user - get - vercode"). The attr (" SRC ",
your image path );
CodePudding user response:
& lt; Img &western nclick="changeCode ();" Id="img/& gt;"
$. Ajax ({
.
Var uuid=XHR. GetResponseHeader (" uuid "),
# $(" img "). Attr (' SRC 'path);//image path
});
The function changeCode () {
Document. The getElementById (" img "). The SRC="https://bbs.csdn.net/topics/xxxx?" + Math. The random ();
}
CodePudding user response: