From 58d43ad576276916668a506490ae0cfd1f892473 Mon Sep 17 00:00:00 2001 From: Michael Date: Thu, 20 Sep 2018 12:44:40 +0000 Subject: [PATCH] Fix: Update routine for conversations in contacts was missing --- mod/update_contacts.php | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 mod/update_contacts.php diff --git a/mod/update_contacts.php b/mod/update_contacts.php new file mode 100644 index 0000000000..863542e666 --- /dev/null +++ b/mod/update_contacts.php @@ -0,0 +1,39 @@ +\r\n"; + echo "
"; + + if ($_GET["force"] == 1) { + $text = contacts_content($a, true); + } else { + $text = ''; + } + + if (PConfig::get(local_user(), "system", "bandwidth_saver")) { + $replace = "
".L10n::t("[Embedded content - reload page to view]")."
"; + $pattern = "/<\s*audio[^>]*>(.*?)<\s*\/\s*audio>/i"; + $text = preg_replace($pattern, $replace, $text); + $pattern = "/<\s*video[^>]*>(.*?)<\s*\/\s*video>/i"; + $text = preg_replace($pattern, $replace, $text); + $pattern = "/<\s*embed[^>]*>(.*?)<\s*\/\s*embed>/i"; + $text = preg_replace($pattern, $replace, $text); + $pattern = "/<\s*iframe[^>]*>(.*?)<\s*\/\s*iframe>/i"; + $text = preg_replace($pattern, $replace, $text); + } + + echo str_replace("\t", " ", $text); + echo "
"; + echo "\r\n"; + killme(); +}