wordpress主题汉化的时候,有时候会出现这个问题。Tags标签通过函数<?php the_tags() ?>输出 Tags: tag1, tag2, tag3。那我们应该怎样把Tags汉化为‘标签’?解决这个问题,需要用到<?php the_tags() ?>的参数了。带参数的形式为:
<?php the_tags(‘Tags: ‘, ‘, ‘, ”); ?>
把上述形式改为:<?php the_tags(‘__(‘Tags:’) ‘, ‘, ‘, ”); ?>就好了。
wordpress主题汉化的时候,有时候会出现这个问题。Tags标签通过函数<?php the_tags() ?>输出 Tags: tag1, tag2, tag3。那我们应该怎样把Tags汉化为‘标签’?解决这个问题,需要用到<?php the_tags() ?>的参数了。带参数的形式为:
<?php the_tags(‘Tags: ‘, ‘, ‘, ”); ?>
把上述形式改为:<?php the_tags(‘__(‘Tags:’) ‘, ‘, ‘, ”); ?>就好了。