@@ -448,7 +448,7 @@ public static function displayAnnouncement($id)
448448 return '' ;
449449 }
450450
451- $ title = $ announcement ->getTitle ();
451+ $ title = Security:: remove_XSS ( $ announcement ->getTitle () );
452452 $ content = $ announcement ->getContent ();
453453
454454 $ html .= "<table height= \"100 \" width= \"100% \" cellpadding= \"5 \" cellspacing= \"0 \" class= \"table table-hover table-striped data_table \"> " ;
@@ -471,7 +471,9 @@ public static function displayAnnouncement($id)
471471 Display::return_icon ($ image_visibility .'.png ' , $ alt_visibility , '' , ICON_SIZE_SMALL )."</a> " ;
472472
473473 if (api_is_allowed_to_edit (false , true )) {
474- $ modify_icons .= "<a href= \"" .api_get_self ()."? " .api_get_cidreq ()."&action=delete&id= " .$ id ."&sec_token= " .$ stok ."\" onclick= \"javascript:if(!confirm(' " .addslashes (api_htmlentities (get_lang ('ConfirmYourChoice ' ), ENT_QUOTES , $ charset ))."')) return false; \"> " .
474+ $ modify_icons .= "<a
475+ href= \"" .api_get_self ()."? " .api_get_cidreq ()."&action=delete&id= " .$ id ."&sec_token= " .$ stok ."\"
476+ onclick= \"javascript:if(!confirm(' " .addslashes (api_htmlentities (get_lang ('ConfirmYourChoice ' ), ENT_QUOTES , $ charset ))."')) return false; \"> " .
475477 Display::return_icon ('delete.png ' , get_lang ('Delete ' ), '' , ICON_SIZE_SMALL ).
476478 "</a> " ;
477479 }
@@ -514,7 +516,7 @@ public static function displayAnnouncement($id)
514516 $ html .= '<br/> ' ;
515517 $ html .= Display::return_icon ('attachment.gif ' , get_lang ('Attachment ' ));
516518 $ html .= '<a href=" ' .$ full_file_name .' "> ' .$ user_filename .' </a> ' ;
517- $ html .= ' - <span class="forum_attach_comment" > ' .$ attachment_list ['comment ' ].'</span> ' ;
519+ $ html .= ' - <span class="forum_attach_comment" > ' .Security:: remove_XSS ( $ attachment_list ['comment ' ]) .'</span> ' ;
518520 if (api_is_allowed_to_edit (false , true )) {
519521 $ url = api_get_self ()."? " .api_get_cidreq ().
520522 "&action=delete_attachment&id_attach= " .$ attachment_list ['id ' ]."&sec_token= " .$ stok ;
0 commit comments