Guten Abend,
ich habe in Problem mit meiner functions.php:
PHP
<?php
function wpe_excerptlenght_teaser($lenght) {
return 22;
}
function wpe_excerptlenght_index($lenght) {
return 70;
}
function wpe_excerptmore($more) {
return '... <a href="'. get_permalink($post->ID) . '">' . '»' . '</a>';
}
function wpe_excerpt($lenght_callback='', $more_callback='') {
global $post;
if(function_exists($lenght_callback)){
add_filter('excerpt_length', $lenght_callback);
}
if(function_exists($more_callback)){
add_filter('excerpt_more', $more_callback);
}
$output = get_the_excerpt();
$output = apply_filters('wptexturize', $output);
$output = apply_filters('convert_chars', $output);
$output = '<p>'.$output.'</p>';
echo $output;
}
function mytheme_comment($comment, $args, $depth) {
$GLOBALS['comment'] = $comment; ?>
<li <?php comment_class(); ?> id='li-comment-<?php comment_ID() ?>'>
<div id='comment-<?php comment_ID(); ?>'>
<div class='comment-author vcard'>
<?php echo get_avatar($comment,$size='48',$default='<path_to_url>' ); ?>
<?php printf(__('<cite class='fn'>%s</cite> <span class='says'>says:</span>'), get_comment_author_link()) ?>
</div>
<?php if ($comment->comment_approved == '0') : ?>
<em><?php _e('Your comment is awaiting moderation.') ?></em>
<br />
<?php endif; ?>
<div class='comment-meta commentmetadata'><a href='<?php echo htmlspecialchars( get_comment_link( $comment->comment_ID ) ) ?>'><?php printf(__('%1$s at %2$s'), get_comment_date(), get_comment_time()) ?></a><?php edit_comment_link(__('(Edit)'),' ','') ?></div>
<?php comment_text() ?>
<div class='reply'>
<?php comment_reply_link(array_merge( $args, array('depth' => $depth, 'max_depth' => $args['max_depth']))) ?>
</div>
</div>
}
?>
Alles anzeigen
Es wird folgende Fehlermeldung angezeigt:
Parse error: syntax error, unexpected T_STRING in /is/htdocs/XXX-XXX/www/wp-content/themes/XXX-XXX/functions.php on line 36
Woran liegt das? Vorab schon einmal vielen Dank! :-)