Changeset 26906
- Timestamp:
- 01/05/2014 05:54:07 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/template.php
r25991 r26906 19 19 * @param string $type Filename without extension. 20 20 * @param array $templates An optional list of template candidates 21 * @return string Full path to file.21 * @return string Full path to template file. 22 22 */ 23 23 function get_query_template( $type, $templates = array() ) { … … 45 45 * Retrieve path of index template in current or parent template. 46 46 * 47 * The template path is filterable via the 'index_template' hook. 48 * 47 49 * @since 3.0.0 48 50 * 49 * @return string 51 * @see get_query_template() 52 * 53 * @return string Full path to index template file. 50 54 */ 51 55 function get_index_template() { … … 56 60 * Retrieve path of 404 template in current or parent template. 57 61 * 58 * @since 1.5.0 59 * 60 * @return string 62 * The template path is filterable via the '404_template' hook. 63 * 64 * @since 1.5.0 65 * 66 * @see get_query_template() 67 * 68 * @return string Full path to 404 template file. 61 69 */ 62 70 function get_404_template() { … … 67 75 * Retrieve path of archive template in current or parent template. 68 76 * 69 * @since 1.5.0 70 * 71 * @return string 77 * The template path is filterable via the 'archive_template' hook. 78 * 79 * @since 1.5.0 80 * 81 * @see get_query_template() 82 * 83 * @return string Full path to archive template file. 72 84 */ 73 85 function get_archive_template() { … … 88 100 * Retrieve path of post type archive template in current or parent template. 89 101 * 102 * The template path is filterable via the 'archive_template' hook. 103 * 90 104 * @since 3.7.0 91 105 * 92 * @return string 106 * @see get_archive_template() 107 * 108 * @return string Full path to archive template file. 93 109 */ 94 110 function get_post_type_archive_template() { … … 107 123 * Retrieve path of author template in current or parent template. 108 124 * 109 * @since 1.5.0 110 * 111 * @return string 125 * The template path is filterable via the 'author_template' hook. 126 * 127 * @since 1.5.0 128 * 129 * @see get_query_template() 130 * 131 * @return string Full path to author template file. 112 132 */ 113 133 function get_author_template() { … … 132 152 * template, if those files don't exist. 133 153 * 134 * @since 1.5.0 135 * @uses apply_filters() Calls 'category_template' on file path of category template. 136 * 137 * @return string 154 * The template path is filterable via the 'category_template' hook. 155 * 156 * @since 1.5.0 157 * 158 * @see get_query_template() 159 * 160 * @return string Full path to category template file. 138 161 */ 139 162 function get_category_template() { … … 158 181 * template, if those files don't exist. 159 182 * 183 * The template path is filterable via the 'tag_template' hook. 184 * 160 185 * @since 2.3.0 161 * @uses apply_filters() Calls 'tag_template' on file path of tag template. 162 * 163 * @return string 186 * 187 * @see get_query_template() 188 * 189 * @return string Full path to tag template file. 164 190 */ 165 191 function get_tag_template() { … … 189 215 * index.php. 190 216 * 217 * The template path is filterable via the 'taxonomy_template' hook. 218 * 191 219 * @since 2.5.0 192 * @uses apply_filters() Calls 'taxonomy_template' filter on found path. 193 * 194 * @return string 220 * 221 * @see get_query_template() 222 * 223 * @return string Full path to taxonomy template file. 195 224 */ 196 225 function get_taxonomy_template() { … … 212 241 * Retrieve path of date template in current or parent template. 213 242 * 214 * @since 1.5.0 215 * 216 * @return string 243 * The template path is filterable via the 'date_template' hook. 244 * 245 * @since 1.5.0 246 * 247 * @see get_query_template() 248 * 249 * @return string Full path to date template file. 217 250 */ 218 251 function get_date_template() { … … 224 257 * 225 258 * This is the template used for the page containing the blog posts. 226 *227 259 * Attempts to locate 'home.php' first before falling back to 'index.php'. 228 260 * 229 * @since 1.5.0 230 * @uses apply_filters() Calls 'home_template' on file path of home template. 231 * 232 * @return string 261 * The template path is filterable via the 'home_template' hook. 262 * 263 * @since 1.5.0 264 * 265 * @see get_query_template() 266 * 267 * @return string Full path to home template file. 233 268 */ 234 269 function get_home_template() { … … 241 276 * Retrieve path of front-page template in current or parent template. 242 277 * 243 * Looks for 'front-page.php'. 278 * Looks for 'front-page.php'. The template path is filterable via the 279 * 'front_page_template' hook. 244 280 * 245 281 * @since 3.0.0 246 * @uses apply_filters() Calls 'front_page_template' on file path of template. 247 * 248 * @return string 282 * 283 * @see get_query_template() 284 * 285 * @return string Full path to front page template file. 249 286 */ 250 287 function get_front_page_template() { … … 261 298 * and finally 'page.php'. 262 299 * 263 * @since 1.5.0 264 * 265 * @return string 300 * The template path is filterable via the 'page_template' hook. 301 * 302 * @since 1.5.0 303 * 304 * @see get_query_template() 305 * 306 * @return string Full path to page template file. 266 307 */ 267 308 function get_page_template() { … … 292 333 * Retrieve path of paged template in current or parent template. 293 334 * 294 * @since 1.5.0 295 * 296 * @return string 335 * The template path is filterable via the 'paged_template' hook. 336 * 337 * @since 1.5.0 338 * 339 * @see get_query_template() 340 * 341 * @return string Full path to paged template file. 297 342 */ 298 343 function get_paged_template() { … … 303 348 * Retrieve path of search template in current or parent template. 304 349 * 305 * @since 1.5.0 306 * 307 * @return string 350 * The template path is filterable via the 'search_template' hook. 351 * 352 * @since 1.5.0 353 * 354 * @see get_query_template() 355 * 356 * @return string Full path to search template file. 308 357 */ 309 358 function get_search_template() { … … 314 363 * Retrieve path of single template in current or parent template. 315 364 * 316 * @since 1.5.0 317 * 318 * @return string 365 * The template path is filterable via the 'single_template' hook. 366 * 367 * @since 1.5.0 368 * 369 * @see get_query_template() 370 * 371 * @return string Full path to single template file. 319 372 */ 320 373 function get_single_template() { … … 341 394 * finally 'text_plain.php'. 342 395 * 396 * The template path is filterable via the 'attachment_template' hook. 397 * 343 398 * @since 2.0.0 344 399 * 345 * @return string 400 * @see get_query_template() 401 * 402 * @return string Full path to attachment template file. 346 403 */ 347 404 function get_attachment_template() { … … 372 429 * parent template. 373 430 * 374 * @since 1.5.0 375 * @uses apply_filters() Calls 'comments_popup_template' filter on path. 376 * 377 * @return string 431 * The template path is filterable via the 'comments_popup_template' hook. 432 * 433 * @since 1.5.0 434 * 435 * @see get_query_template() 436 * 437 * @return string Full path to comments popup template file. 378 438 */ 379 439 function get_comments_popup_template() {
Note: See TracChangeset
for help on using the changeset viewer.