Changeset 2206 for sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-developer/inc/formatting.php
- Timestamp:
- 12/18/2015 06:15:42 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-developer/inc/formatting.php
r1914 r2206 195 195 } 196 196 197 /** 198 * Handles formatting of the parameter description. 199 * 200 * @param string $text The parameter description. 201 * @return string 202 */ 203 public static function format_param_description( $text ) { 204 // Encode all htmlentities. 205 $text = htmlentities( $text ); 206 207 // Simple allowable tags that should get unencoded. 208 // Note: This precludes them from being able to be used in an encoded fashion 209 // within a parameter description. 210 $allowable_tags = array( 'code' ); 211 foreach ( $allowable_tags as $tag ) { 212 $text = str_replace( array( "<{$tag}>", "</{$tag}>" ), array( "<{$tag}>", "</{$tag}>" ), $text ); 213 } 214 215 // Convert any @link or @see to actual link. 216 $text = self::make_doclink_clickable( $text ); 217 218 return $text; 219 } 220 197 221 } // DevHub_Formatting 198 222
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)