Přidat otázku mezi oblíbenéZasílat nové odpovědi e-mailemVyřešeno Počet komentářů - čeština v template (Delicate) WordPressu - úprava php

Je nějaká možnost upravit kód tak, aby se zobrazovalo Žádné komentáře/Jeden komentář/2-4komentáře/5-hodně komentářů? V současném kódu je to No Responses/One Response/2-hodně Responses, což v češtině tak nějak nestačí. V podstatě jde o to, přidat čtvrtou možnost.
Přikládám kód comments.php z template (něco tam mám přeloženo, ale to snad mást nebude)

<?php
/**
 * @package WordPress
 * @subpackage Default_Theme
 */

	if ( post_password_required() ) {		
		return;
	}
?>

<!-- You can start editing here. -->

<?php if ( have_comments() ) : ?>
	<h2><?php comments_number(__('No Responses','delicate'), __('One Response','delicate'), __('% Responses','delicate'));?></h2>
	<div class="inner-text">				

<?php if ( get_comment_pages_count() > 1 && get_option( 'page_comments' ) ) : // Are there comments to navigate through? ?>		
			<div class="navigation">
				<div class="alignleft"><?php previous_comments_link( __( '<span class="meta-nav">&larr;</span> Older Comments', 'delicate' ) ); ?></div>
				<div class="alignright"><?php next_comments_link( __( 'Newer Comments <span class="meta-nav">&rarr;</span>', 'delicate' ) ); ?></div>
			</div><div style="clear:both;"></div>
<?php endif; // check for comment navigation ?>			
            
            
			<ul class="commentlist">
			<?php wp_list_comments('style=ul&callback=natty_themecomment'); ?>
			</ul>

<?php if ( get_comment_pages_count() > 1 && get_option( 'page_comments' ) ) : // Are there comments to navigate through? ?>			
			<div class="navigation">
				<div class="alignleft"><?php previous_comments_link( __( '<span class="meta-nav">&larr;</span> Older Comments', 'delicate' ) ); ?></div>
				<div class="alignright"><?php next_comments_link( __( 'Newer Comments <span class="meta-nav">&rarr;</span>', 'delicate' ) ); ?></div>
			</div>
<?php endif; // check for comment navigation ?>				
              <div style="clear:both;"></div><br /><br />
	</div>
 <?php else : // this is displayed if there are no comments so far ?>

	<?php if ('open' == $post->comment_status) : ?>
		<!-- If comments are open, but there are no comments. -->

	 <?php else : // comments are closed ?>
		<!-- If comments are closed. -->
		<p class="nocomments"></p>

	<?php endif; ?>
<?php endif; ?>

<?php 
$defaults = array(
	'id_form'              => 'comment-form',
	'id_submit'            => 'submit',
	'title_reply'          => __( 'Odpovědět', 'delicate' ),
	'title_reply_to'       => __( 'Leave a Reply to %s', 'delicate' ),
	'cancel_reply_link'    => __( 'Cancel reply', 'delicate' ),
	'label_submit'         => __( 'Přidat komentář', 'delicate' )
);

comment_form($defaults); ?>
Předmět Autor Datum
IMHOj by bylo potřeba upravit funkci comments_number, kterou jsi sem nezveřejnil...
host 11.05.2013 17:18
host
Aha, tak já jdu pátrat.
Zarniwúp 11.05.2013 17:32
Zarniwúp
Mělo by to být v wp-includes/comment-template.php
host 11.05.2013 17:42
host
Ještě než se pustíš do nějakých úprav, mrkni na http://www.separatista.net/wordpress/pluginy/podpo r…
host 11.05.2013 17:44
host
Díky. V tomhle jsem amatér ale hrabat se v tom mi to nebrání... Takhle to bude lepší.
Zarniwúp 11.05.2013 17:53
Zarniwúp
Tak jo, vyřešeno pluginem. Děkuji :-)
Zarniwúp 11.05.2013 18:06
Zarniwúp
Super, takže já se s tím seru celý den a vono to nejde??? poslední
albru123 11.05.2013 20:28
albru123

Zpět do poradny Odpovědět na původní otázku Nahoru