Opened 17 years ago
Closed 17 years ago
#9784 closed defect (bug) (fixed)
catchable fatal error - category template line 24
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | 2.8 | Priority: | normal |
| Severity: | normal | Version: | 2.8 |
| Component: | Template | Keywords: | category template, catchable fatal error |
| Focuses: | Cc: |
Description
Found a possible bug when betatesting Hybrid 0.6 theme with 2.8 bleeding.
When using the get_the_term_list() function to show a post's categories with the default (non-pretty) permalink settings, I receive this error:
Catchable fatal error: Object of class stdClass could not be converted to string in ..\wp-includes\category-template.php on line 24
Code example::
get_the_term_list( $post->ID, 'category', 'Posted in', ', ', '' );
Change History (3)
#1
@
17 years ago
- Component changed from General to Template
- Milestone set to 2.8
- Resolution set to worksforme
- Status changed from new to closed
#2
@
17 years ago
- Resolution worksforme deleted
- Status changed from closed to reopened
Fails miserably in Kubrick for me too.
Step by step:
1) Set your permalinks to the default: http://localhost/?p=123.
2) Add this code within The Loop in index.php:
<?php echo get_the_term_list( $post->ID, 'category', 'Posted in ', ', ', '' ); ?>
This error is produced:
Catchable fatal error: Object of class stdClass could not be converted to string in C:\xampp\htdocs\wp-includes\category-template.php on line 24
Note: See
TracTickets for help on using
tickets.
works fine in kubrick. please re-open with a step by step procedure to reproduce.