Changeset 853 for sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-developer/inc/template-tags.php
- Timestamp:
- 09/10/2014 10:55:43 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-developer/inc/template-tags.php
r836 r853 500 500 $types[ $i ] = "<span class=\"{$v}\">{$v}</span>"; 501 501 } 502 503 // Normalize spacing at beginning of hash notation params. 504 if ( '{' == $tag['content'][0] ) { 505 $tag['content'] = '{ ' . trim( substr( $tag['content'], 1 ) ); 506 } 507 502 508 $params[ $tag['variable'] ]['types'] = implode( '|', $types ); 503 509 if ( strtolower( substr( $tag['content'], 0, 9 ) ) == "optional." ) { 504 510 $params[ $tag['variable'] ]['required'] = 'Optional'; 505 511 $params[ $tag['variable'] ]['content'] = substr( $tag['content'], 10 ); 512 $encountered_optional = true; 513 } elseif ( strtolower( substr( $tag['content'], 2, 9 ) ) == "optional." ) { // Hash notation param 514 $params[ $tag['variable'] ]['required'] = 'Optional'; 515 $params[ $tag['variable'] ]['content'] = '{ ' . substr( $tag['content'], 12 ); 506 516 $encountered_optional = true; 507 517 } elseif ( $encountered_optional ) {
Note: See TracChangeset
for help on using the changeset viewer.