2010-06-28 2 views
0

누구나 the.content()가 single.php 페이지에 표시되지 않는 이유를 아는 사람이라면 누구나 index.php에 표시되는 동안 알 수 있습니까? 당신의 single.php 페이지 NAD 인덱스 페이지에서Wordpress and thecontent()

<div class="block"> 
    <h1><?php the_title(); ?></h1> 
    <p class="date"> 
     <?php the_date('d F Y'); ?> 
    </p> 
    <p> 
     <?php the_content(); ?> 
    </p> 
</div> 
+1

일부 코드를 표시하십시오. –

+0

아마도 pastebin.com을 사용하여 어딘가에서 single.php와 index.php의 코드를 업로드해야 할 수도 있습니다. 그래서 우리는 무엇이 잘못 될지 알 수 있습니다 ... – ariefbayu

+1

은 보여주는 제목과 날짜가 맞습니까? while 루프 내에 있습니까 – RobertPitt

답변

1

the_*() 기능은 루프 내에서 사용할 수 있도록 설계되었습니다.

while(have_posts()) 
{ 
    ///the_content(); the_title(); the_post(); etc 
} 

//If I Used here then it would not work! 
+0

왜 the_title과 the_date가 표시됩니까? – Alex

+0

the_post()에 the_content를 변경해보십시오. – RobertPitt

+0

호출 할 루프가없는 경우 제목과 날짜는 어떻게 표시됩니까? – theorise