summaryrefslogtreecommitdiff
path: root/static/resizetest/dump.fm_files/pichat.js
diff options
context:
space:
mode:
authoryo momma <shutup@oops.wtf>2026-01-27 03:33:16 +0000
committeryo momma <shutup@oops.wtf>2026-01-27 03:33:16 +0000
commitfc9a4ea22eb91757b95cbe1bf1708be17fc2337a (patch)
tree76a0122149e3288ee21d7fb6d0410b1b7b8970a4 /static/resizetest/dump.fm_files/pichat.js
parent25b74138d68ade87689e714f10e1f3116da5bbee (diff)
Fix HTTPS/mixed content; make config env-drivenHEADmaster2026
- Replace hardcoded dump.fm URLs with host/scheme config\n- Add optional passwordless login flow\n- Update templates/static assets to avoid blocked HTTP resources\n- Ignore local uploads/SQL dumps
Diffstat (limited to 'static/resizetest/dump.fm_files/pichat.js')
-rwxr-xr-xstatic/resizetest/dump.fm_files/pichat.js16
1 files changed, 8 insertions, 8 deletions
diff --git a/static/resizetest/dump.fm_files/pichat.js b/static/resizetest/dump.fm_files/pichat.js
index 8a293ee..bdef69c 100755
--- a/static/resizetest/dump.fm_files/pichat.js
+++ b/static/resizetest/dump.fm_files/pichat.js
@@ -301,7 +301,7 @@ function buildMessageDiv(msg, isLoading) {
var displayStyle = (TextEnabled || LastMsgContainsImage) ? '' : ' style="display: none"';
return '<div class="msgDiv dump ' + loadingClass + containsImageClass + '" ' + msgId + displayStyle + '>'
- + '<span class="nick"><b><a href="http://dump.fm/' + nick + ' ">' + nick + '</a></b>'
+ + '<span class="nick"><b><a href="/' + nick + ' ">' + nick + '</a></b>'
+ ' <img src="'+Imgs.chatThumbDot+'" class="chat-thumb" onclick="Tag.favorite(this)"> '
+ '</span>'
+ '<span class="content">' + builtContent + '</span>'
@@ -311,7 +311,7 @@ function buildMessageDiv(msg, isLoading) {
function buildUserDiv(user) {
if (user.avatar) {
return '<div class="username">'
- + '<a href="http://dump.fm/' + escapeHtml(user.nick) + '" target="_blank">'
+ + '<a href="/' + escapeHtml(user.nick) + '" target="_blank">'
+ '<img src="' + user.avatar + '" width="50" height="50">'
+ escapeHtml(user.nick) + '</a></div>';
} else {
@@ -327,7 +327,7 @@ function buildUserDiv(user) {
function buildFav(f) {
var h = '<div class="fav-note">'
+ '<img src="/static/img/thumbs/chatheartover.gif">'
- + '<a href="http://dump.fm/' + f.from + '">' + f.from + '</a>'
+ + '<a href="/' + f.from + '">' + f.from + '</a>'
+ '&nbsp;<span>just faved you!</span>'
+ '</div>';
return $(h);
@@ -363,7 +363,7 @@ function updateFavs(fs) {
function buildGrowlDataAndPopDatShit(msg) {
var nick = escapeHtml(msg.nick);
- nick = '<a href="http://dump.fm/' + nick + ' " style="color:pink">' + nick + '</a>:'
+ nick = '<a href="/' + nick + ' " style="color:pink">' + nick + '</a>:'
var msg = buildMsgContent(msg.content)
growl(nick, msg)
}
@@ -531,7 +531,7 @@ function refresh() {
var onError = function(resp, textStatus, errorThrown) {
var msg = $.trim(resp.responseText);
if (msg == "UNKNOWN_ROOM")
- location.href = "http://dump.fm";
+ location.href = "/";
if (IsAdmin && window.console) {
console.error(resp, textStatus, errorThrown);
}
@@ -1142,7 +1142,7 @@ function getMessageInfo(e){
var message = $(e).parents(".dump")
var id = message.attr("id").substr(8) // cut "message-001" to "001"
var nick = message.attr("nick")
- var link = "http://dump.fm/p/" + nick + "/" + id
+ var link = "/p/" + nick + "/" + id
var content = message.find(".linkify")
if (!content.length) content = message.find(".content")
var rawContent = content.html()
@@ -1159,7 +1159,7 @@ Share = {
},
"facebook": function(button){
var message = getMessageInfo(button)
- var url = "http://www.facebook.com/share.php?u=" + message.img + "&t=" + message.via
+ var url = "https://www.facebook.com/share.php?u=" + message.img + "&t=" + message.via
Share.openLink(url)
},
"tumblr": function(button){
@@ -1340,7 +1340,7 @@ function initChatMsgs() {
var zoomlink = $('<a>')
.attr({'href': img.attr('src') })
.addClass('msg-image-zoom')
- .append($('<img>').attr('src', 'http://dump.fm/static/img/zoom.gif')
+ .append($('<img>').attr('src', '/static/img/zoom.gif')
.addClass('zoom-icon'))
.click(function() { window.open(img.attr('src')); return false; });
$(this).append(zoomlink);