summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--db/notice_source.sql1
-rw-r--r--js/util.js13
2 files changed, 10 insertions, 4 deletions
diff --git a/db/notice_source.sql b/db/notice_source.sql
index ce44f3235..17720028d 100644
--- a/db/notice_source.sql
+++ b/db/notice_source.sql
@@ -24,6 +24,7 @@ VALUES
('peoplebrowsr', 'PeopleBrowsr', 'http://www.peoplebrowsr.com/', now()),
('Pikchur','Pikchur','http://www.pikchur.com/', now()),
('Ping.fm','Ping.fm','http://ping.fm/', now()),
+ ('pingvine','PingVine','http://pingvine.com/', now()),
('pocketwit','PockeTwit','http://code.google.com/p/pocketwit/', now()),
('posty','Posty','http://spreadingfunkyness.com/posty/', now()),
('royalewithcheese','Royale With Cheese','http://p.hellyeah.org/', now()),
diff --git a/js/util.js b/js/util.js
index f15c4f2bb..3f14bc61c 100644
--- a/js/util.js
+++ b/js/util.js
@@ -166,14 +166,20 @@ $(document).ready(function(){
$("#notice_action-submit").addClass("disabled");
return true;
},
+ timeout: '60000',
error: function (xhr, textStatus, errorThrown) { $("#form_notice").removeClass("processing");
$("#notice_action-submit").removeAttr("disabled");
$("#notice_action-submit").removeClass("disabled");
- if ($(".error", xhr.responseXML).length > 0) {
- $('#form_notice').append(document._importNode($(".error", xhr.responseXML).get(0), true));
+ if (textStatus == "timeout") {
+ alert ("Sorry! We had trouble sending your notice. The servers are overloaded. Please try again, and contact the site administrator if this problem persists");
}
else {
- alert("Sorry! We had trouble sending your notice ("+xhr.status+" "+xhr.statusText+"). Please report the problem to the site administrator if this happens again.");
+ if ($(".error", xhr.responseXML).length > 0) {
+ $('#form_notice').append(document._importNode($(".error", xhr.responseXML).get(0), true));
+ }
+ else {
+ alert("Sorry! We had trouble sending your notice ("+xhr.status+" "+xhr.statusText+"). Please report the problem to the site administrator if this happens again.");
+ }
}
},
success: function(xml) { if ($("#error", xml).length > 0) {
@@ -189,7 +195,6 @@ $(document).ready(function(){
}
else {
li = $("li", xml).get(0);
- id = li.id;
if ($("#"+li.id).length == 0) {
$("#notices_primary .notices").prepend(document._importNode(li, true));
$("#notices_primary .notice:first").css({display:"none"});