forked from Mirrors/freeswitch
hack for dropbox
This commit is contained in:
parent
6f800ef90a
commit
e09ea08c34
@ -115,7 +115,11 @@ 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?dl=1'><\/a>");
|
||||
var mod = "";
|
||||
if (body.match(/dropbox.com/)) {
|
||||
mod = "?dl=1";
|
||||
}
|
||||
body = body.replace(/(http[s]{0,1}:\/\/\S+)/g, "<a target='_blank' href='$1'>$1<br><img border='0' class='chatimg' src='$1'" + mod + "><\/a>");
|
||||
} else {
|
||||
body = body.replace(/(http[s]{0,1}:\/\/\S+)/g, "<a target='_blank' href='$1'>$1<\/a>");
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user