Smuggli has uploaded a new change for review. https://gerrit.wikimedia.org/r/172712
Change subject: Strip tags from preview text ...................................................................... Strip tags from preview text When showtext parameter is set a little preview of the page content is shown. It looks strange when tags are included in this preview. Change-Id: I07ad32bd6aeb1050f412af6fa9593afba9eba44e --- M SmartList/SmartList.class.php 1 file changed, 1 insertion(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/BlueSpiceExtensions refs/changes/12/172712/1 diff --git a/SmartList/SmartList.class.php b/SmartList/SmartList.class.php index 1a447db..fb8e9bf 100644 --- a/SmartList/SmartList.class.php +++ b/SmartList/SmartList.class.php @@ -850,6 +850,7 @@ if ( $aArgs['showtext'] && ( $iItems <= $aArgs['numwithtext'] ) ) { $oSmartListListEntryView->setTemplate( '*[[:{NAMESPACE}:{TITLE}|{DISPLAYTITLE}]]{META}<br/>{TEXT}' . "\n" ); $sText = BsPageContentProvider::getInstance()->getContentFromTitle( $oTitle ); + $sText = Sanitizer::stripAllTags( $sText ); $sText = BsStringHelper::shorten( $sText, array( 'max-length' => $aArgs['trimtext'], 'position' => 'end' ) ); $sText = '<nowiki>' . $sText . '</nowiki>'; } else { -- To view, visit https://gerrit.wikimedia.org/r/172712 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I07ad32bd6aeb1050f412af6fa9593afba9eba44e Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/BlueSpiceExtensions Gerrit-Branch: master Gerrit-Owner: Smuggli <mug...@hallowelt.biz> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits