Asked by markdolar
at 2024-07-17 21:20:14
Point:500 Replies:9 POST_ID:829015USER_ID:11917
Topic:
JavaScript;;Web Languages/Standards
I have the following function:
function() {
if (settings.onthumbnailclick != null) {
settings.onthumbnailclick($(this).attr('src') + "Selected");
}
});
Which, when run off a web page, prints the name of a file associated with the thumbnail click ("src"). The file is an image file (jpg or png).
What I want to do is display the contents of the file as an image instead of the message. I don't really want to do in the html if I don't have to. I would like the image to overlay on top of the web page, just like the message this function generates does.
Is there a statement I could substitute for
settings.onthumbnailclick($(this).attr('src') + "Selected");
That would display src as an image instead?
Thank you for your time.
function() {
if (settings.onthumbnailclick != null) {
settings.onthumbnailclick($(this).attr('src') + "Selected");
}
});
Which, when run off a web page, prints the name of a file associated with the thumbnail click ("src"). The file is an image file (jpg or png).
What I want to do is display the contents of the file as an image instead of the message. I don't really want to do in the html if I don't have to. I would like the image to overlay on top of the web page, just like the message this function generates does.
Is there a statement I could substitute for
settings.onthumbnailclick($(this).attr('src') + "Selected");
That would display src as an image instead?
Thank you for your time.