mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-04-13 07:45:26 +00:00
render image urls
This commit is contained in:
parent
a47dc4b5d0
commit
a4ff7eade7
@ -115,7 +115,7 @@ var callbacks = {
|
||||
var body = data.body;
|
||||
|
||||
if (body.match(/\.gif|\.jpg|\.jpeg|\.png/)) {
|
||||
body = body.replace(/(http[s]{0,1}:\/\/\S+)/g, "<a target='_blank' href='$1'>$1<br><img border='0' class='chatimg' src='$1'><\/a>");
|
||||
body = body.replace(/(http[s]{0,1}:\/\/\S+)/g, "<a target='_blank' href='$1'>$1<br><img border='0' class='chatimg' src='$1?dl=1'><\/a>");
|
||||
} else {
|
||||
body = body.replace(/(http[s]{0,1}:\/\/\S+)/g, "<a target='_blank' href='$1'>$1<\/a>");
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user