hallo.
auf meiner test seite funzt das nicht: I ♥ sham-rock » Jung, geil und am Leben!
ich hab ein problem mit gravatar. bei mir ist das avatar nicht direkt neben dem kommentar sondern darunter oder darüber.
hier ist meine comments.php
PHP
<?php // Do not delete these lines
if ('comments.php' == basename($_SERVER['SCRIPT_FILENAME']))
die ('Bitte diese Seite nicht direkt laden. Danke!');
if (!empty($post->post_password)) { // if there's a password
if ($_COOKIE['wp-postpass_' . COOKIEHASH] != $post->post_password) { // and it doesn't match the cookie
?>
<p class="nocomments"><?php _e("Dieser Beitrag ist Passwort geschützt. Um ihn anzusehen gib bitte das Passwort ein:"); ?><p>
<?php return; } }
/* This variable is for alternating comment background */
$oddcomment = 'even';
?>
<div id="watertownStrip">
<div class="responses">
<?php if ($comments) : ?>
<?php $relax_comment_count=1; ?>
<?php foreach ($comments as $comment) : ?>
<dl>
<b><dt><?php comment_author_link() ?> <?php comment_date('d.m.y | H:i') ?> Uhr</dt></b>
<dd><?php comment_text() ?>
<?php if ($comment->comment_approved == '0') : ?>
<br /><em class="responseMod">Dein Kommentar muss moderiert werden.</em></dd>
<?php endif; ?>
</dl>
<li <?php echo $oddcomment; ?>id="comment-<?php comment_ID() ?>">
<?php echo get_avatar( $comment, 40 ); ?>
</span>
<?php $relax_comment_count++; ?>
<?php if ('even' == $oddcomment) $oddcomment = 'odd';
else $oddcomment = 'even'; ?>
<?php endforeach; /* end for each comment */ ?>
</div>
<?php else : // this is displayed if there are no comments so far ?>
<?php if ('open' == $post-> comment_status) : // comments open, none there though ?>
<?php else : // comments are closed ?>
<h3>Kommentare deaktiviert</h3>
<?php endif; ?>
<?php endif; ?>
<?php if ('open' == $post-> comment_status) : ?>
<p id="respond" class="respond">Hast du auch was zu sagen?</p>
<?php if ( get_option('comment_registration') && !$user_ID ) : ?>
<p>Du musst <a href="<?php echo get_option('siteurl'); ?>/wp-login.php?redirect_to=<?php the_permalink(); ?>">eingeloggt</a> sein, um zu kommentieren.</p>
<?php else : ?>
<form name="commentform" action="<?php echo get_option('siteurl'); ?>/wp-comments-post.php" method="post" id="commentform">
<?php if ( $user_ID ) : ?>
<p>Eingeloggt als <a href="<?php echo get_option('siteurl'); ?>/wp-admin/profile.php"><?php echo $user_identity; ?></a>. <a href="<?php echo get_option('siteurl'); ?>/wp-login.php?action=logout" title="<?php _e('Ausloggen') ?>">Ausloggen »</a></p>
<?php else : ?>
<p><input class="textform" type="text" name="author" id="author" value="<?php echo $comment_author; ?>" size="22" tabindex="1" />
<label for="author"><small>Name <?php if ($req) _e('(required)'); ?></small></label></p>
<p><input class="textform" type="text" name="email" id="email" value="<?php echo $comment_author_email; ?>" size="22" tabindex="2" />
<label for="email"><small>eMail (wird nicht veröffentlicht) <?php if ($req) _e('(required)'); ?></small></label>
</p>
<p><input class="textform" type="text" name="url" id="url" value="<?php echo $comment_author_url; ?>" size="22" tabindex="3" />
<label for="url"><small>Webseite</small></label></p>
<?php endif; ?>
<!--<p><small><strong>XHTML:</strong> You can use these tags: <?php echo allowed_tags(); ?></small></p>-->
<p><textarea class="textform" name="comment" id="comment" cols="100%" rows="10" tabindex="4"></textarea></p>
<p><input type="submit" id="submit" tabindex="5" value="Absenden" />
<input type="hidden" name="comment_post_ID" value="<?php echo $id; ?>" />
</p>
<?php do_action('comment_form', $post->ID); ?>
</form>
<?php endif; // If registration required and not logged in ?>
<?php endif; // if you delete this the sky will fall on your head ?>
Alles anzeigen
und hier ist mein gravatar plugin,.
PHP
<?php
/*
Plugin Name: Gravatar
Plugin URI: http://www.gravatar.com/implement.php#section_2_2
Description: This plugin allows you to generate a gravatar URL complete with rating, size, default, and border options. See the <a href="http://www.gravatar.com/implement.php#section_2_2">documentation</a> for syntax and usage.
Version: 1.1
Author: Tom Werner
Author URI: http://www.mojombo.com/
CHANGES
2004-11-14 Fixed URL ampersand XHTML encoding issue by updating to use proper entity
*/
function gravatar($rating = false, $size = false, $default = false, $border = false) {
global $comment;
$out = "http://www.gravatar.com/avatar.php?gravatar_id=".md5($comment->comment_author_email);
if($rating && $rating != '')
$out .= "&rating=".$rating;
if($size && $size != '')
$out .="&size=".$size;
if($default && $default != '')
$out .= "&default=".urlencode($default);
if($border && $border != '')
$out .= "&border=".$border;
echo $out;
}
?>
Alles anzeigen
was muss ich da tun bzw ändern??