summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorBrion Vibber <brion@pobox.com>2010-03-17 15:49:10 -0700
committerSarven Capadisli <csarven@status.net>2010-03-25 23:11:06 +0100
commit013647f0ba29949e9025330b9692ad3113b1d644 (patch)
tree96288b138a0b618a51b2bd9cacc8f2a0905ac80c /plugins
parent511a164c99eb143575925743a5223ca454f55fb0 (diff)
Add doc comments on saveHTMLFile; drop the extra <div> wrapping the contents to make it easier to extract without getting extra markup.
Diffstat (limited to 'plugins')
-rw-r--r--plugins/OStatus/classes/Ostatus_profile.php10
1 files changed, 9 insertions, 1 deletions
diff --git a/plugins/OStatus/classes/Ostatus_profile.php b/plugins/OStatus/classes/Ostatus_profile.php
index e5210cda1..0abc1ee19 100644
--- a/plugins/OStatus/classes/Ostatus_profile.php
+++ b/plugins/OStatus/classes/Ostatus_profile.php
@@ -1676,10 +1676,18 @@ class Ostatus_profile extends Memcached_DataObject
throw new Exception("Couldn't find a valid profile for '$addr'");
}
+ /**
+ * Store the full-length scrubbed HTML of a remote notice to an attachment
+ * file on our server. We'll link to this at the end of the cropped version.
+ *
+ * @param string $title plaintext for HTML page's title
+ * @param string $rendered HTML fragment for HTML page's body
+ * @return File
+ */
function saveHTMLFile($title, $rendered)
{
$final = sprintf("<!DOCTYPE html>\n<html><head><title>%s</title></head>".
- '<body><div>%s</div></body></html>',
+ '<body>%s</body></html>',
htmlspecialchars($title),
$rendered);