Index: trunk/phase3/RELEASE-NOTES-1.19 |
— | — | @@ -197,6 +197,7 @@ |
198 | 198 | srprop=sectiontitle |
199 | 199 | * Correct the documentation of srprop properties |
200 | 200 | * (bug 28817) Add reference help page link to API Modules |
| 201 | +* (bug 29935) Improve formatting of examples in ApiParamInfo |
201 | 202 | |
202 | 203 | === Languages updated in 1.19 === |
203 | 204 | |
Index: trunk/phase3/includes/api/ApiParamInfo.php |
— | — | @@ -93,7 +93,8 @@ |
94 | 94 | $result = $this->getResult(); |
95 | 95 | $retval['classname'] = get_class( $obj ); |
96 | 96 | $retval['description'] = implode( "\n", (array)$obj->getDescription() ); |
97 | | - $retval['examples'] = implode( "\n", (array)$obj->getExamples() ); |
| 97 | + $examples = (array)$obj->getExamples(); |
| 98 | + $retval['examples'] = implode( "\n", $examples ); |
98 | 99 | $retval['version'] = implode( "\n", (array)$obj->getVersion() ); |
99 | 100 | $retval['prefix'] = $obj->getModulePrefix(); |
100 | 101 | |
— | — | @@ -118,6 +119,9 @@ |
119 | 120 | $retval['helpurls'] = (array)$obj->getHelpUrls(); |
120 | 121 | $result->setIndexedTagName( $retval['helpurls'], 'helpurl' ); |
121 | 122 | |
| 123 | + $retval['allexamples'] = $examples; |
| 124 | + $result->setIndexedTagName( $retval['allexamples'], 'example' ); |
| 125 | + |
122 | 126 | $retval['parameters'] = array(); |
123 | 127 | $paramDesc = $obj->getFinalParamDescription(); |
124 | 128 | foreach ( $allowedParams as $n => $p ) { |