aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorpetko <petko@524c5546-5005-0410-9a3e-e25e191bd360>2024-06-25 08:38:06 +0000
committerpetko <petko@524c5546-5005-0410-9a3e-e25e191bd360>2024-06-25 08:38:06 +0000
commit112279a363b0d528cb3cf4d12a1afb3adc98fa1a (patch)
treed4bc5f0b73677cc5b78f232c5e1ccb40d83e339f
parent20d6c858ae51fb71693e1fb4b3a93679328667f7 (diff)
downloadpmwiki.svn-112279a363b0d528cb3cf4d12a1afb3adc98fa1a.tar.bz2
Fix page title could accidentally include raw HTML.
git-svn-id: svn://pmwiki.org/pmwiki/trunk@4728 524c5546-5005-0410-9a3e-e25e191bd360
-rw-r--r--scripts/stdmarkup.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/scripts/stdmarkup.php b/scripts/stdmarkup.php
index c368f1ca..4abff4d8 100644
--- a/scripts/stdmarkup.php
+++ b/scripts/stdmarkup.php
@@ -260,8 +260,11 @@ function MarkupSetProperty($m){ # title, description, keywords
switch ($markupid) {
case 'title':
global $EnablePageTitlePriority;
- return PZZ(PCache($pagename, $zz=array('title' =>
- SetProperty($pagename, 'title', $m[1], NULL, $EnablePageTitlePriority))));
+ $etp = IsEnabled($EnablePageTitlePriority, 0);
+ $title = strip_tags(MarkupRestore($m[1]));
+ $title = SetProperty($pagename, 'title', $title, NULL, $etp);
+ PCache($pagename, array('title' => $title));
+ return "";
case 'keywords':
return PZZ(SetProperty($pagename, 'keywords', $m[1], ', '));
case 'description':