IPB

( Zaloguj | Zarejestruj )

 
Reply to this topicStart new topic
> Jak wyświetlić cały post w archiwum i kategoriach
Yanetteee
post 29.10.2009 - 11:40
Post #1





Grupa: Bloger
Postów: 7

Nr: 7 228



Witam,
wiem, że temat już był, ale nadal nie potrafię sobie poradzić, próbowałam tak jak radzono w podobnym temacie ale nie zadziałało.

Chciałabym aby w archiwum oraz w kategoriach wyświetlały się całe posty a nie tylko skróty.
Jak to zrobić ?? To moja strona: http://www.yanettee.za.pl/blog/

Z góry dziękuje jeśli ktoś będzie tak uprzejmy mi pomóc.
Pozdrawiam

plik index.php

KOD
<?php get_header(); ?>

    <div id="content" class="narrowcolumn">

    <?php if (have_posts()) : ?>
<?php while (have_posts()) : the_post(); ?>
                
            <div class="post">
                <h2 id="post-<?php the_ID(); ?>"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><?php the_title(); ?></a></h2>
                <small>Posted by <?php the_author() ?> in <?php the_category(', ') ?> on <?php the_time('F jS, Y') ?> <strong>|</strong> <?php edit_post_link('Edit','','<strong>|</strong>'); ?>
&nbsp;<?php comments_popup_link('No Comments »', '1 Comment »', '% Comments »'); ?></small>
                
                <div class="entry">
                    <?php the_content('Read the rest of this entry &raquo;'); ?>
                </div>
        </div>
                
                
                <!--
                <?php trackback_rdf(); ?>
                -->
            
    
        <?php endwhile; ?>

        <div class="navigation">
            <div class="alignleft"><?php posts_nav_link('','','&laquo; Previous Entries') ?></div>
            <div class="alignright"><?php posts_nav_link('','Next Entries &raquo;','') ?></div>
        </div>
        
    <?php else : ?>

        <h2 class="center">Not Found</h2>
        <p class="center"><?php _e("Sorry, but you are looking for something that isn't here."); ?></p>
        <?php include (TEMPLATEPATH . "/searchform.php"); ?>
<?php endif; ?>

    </div>

<?php get_sidebar(); ?>
<?php get_footer(); ?>


plik archive.php

KOD
<?php get_header(); ?>

    <div id="content" class="narrowcolumn">

        <?php if (have_posts()) : ?>

         <?php $post = $posts[0]; // Hack. Set $post so that the_date() works. ?>
<?php /* If this is a category archive */ if (is_category()) { ?>                
        <h2 class="pagetitle">Archive for the '<?php echo single_cat_title(); ?>' Category</h2>
        
      <?php /* If this is a daily archive */ } elseif (is_day()) { ?>
        <h2 class="pagetitle">Archive for <?php the_time('F jS, Y'); ?></h2>
        
     <?php /* If this is a monthly archive */ } elseif (is_month()) { ?>
        <h2 class="pagetitle">Archive for <?php the_time('F, Y'); ?></h2>

        <?php /* If this is a yearly archive */ } elseif (is_year()) { ?>
        <h2 class="pagetitle">Archive for <?php the_time('Y'); ?></h2>
        
      <?php /* If this is a search */ } elseif (is_search()) { ?>
        <h2 class="pagetitle">Search Results</h2>
        
      <?php /* If this is an author archive */ } elseif (is_author()) { ?>
        <h2 class="pagetitle">Author Archive</h2>

        <?php /* If this is a paged archive */ } elseif (isset($_GET['paged']) && !empty($_GET['paged'])) { ?>
        <h2 class="pagetitle">Blog Archives</h2>

        <?php } ?>


        <div class="navigation">
            <div class="alignleft"><?php posts_nav_link('','','&laquo; Previous Entries') ?></div>
            <div class="alignright"><?php posts_nav_link('','Next Entries &raquo;','') ?></div>
        </div>

        <?php while (have_posts()) : the_post(); ?>
        <div class="post">
                <h3 id="post-<?php the_ID(); ?>"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><?php the_title(); ?></a></h3>
                <small><?php the_time('l, F jS, Y') ?></small>
                
                <div class="entry">
                    <?php the_excerpt() ?>
                </div>
        
                <p class="postmetadata">Posted in <?php the_category(', ') ?> <strong>|</strong> <?php edit_post_link('Edit','','<strong>|</strong>'); ?>  <?php comments_popup_link('No Comments »', '1 Comment »', '% Comments »'); ?></p>
                
                <!--
                <?php trackback_rdf(); ?>
                -->
            </div>
    
        <?php endwhile; ?>

        <div class="navigation">
            <div class="alignleft"><?php posts_nav_link('','','&laquo; Previous Entries') ?></div>
            <div class="alignright"><?php posts_nav_link('','Next Entries &raquo;','') ?></div>
        </div>
    
    <?php else : ?>

        <h2 class="center">Not Found</h2>
        <?php include (TEMPLATEPATH . '/searchform.php'); ?>

    <?php endif; ?>
        
    </div>

<?php get_sidebar(); ?>

<?php get_footer(); ?>
Go to the top of the page
 
+Quote Post
kejsi
post 29.10.2009 - 11:54
Post #2


aktywność:
*****

Grupa: +Bloger
Postów: 892

Nr: 3 286



Leniuszku w pliku archive.php

KOD
<?php the_excerpt() ?>
zamień na

KOD
<?php the_content(); ?>
Go to the top of the page
 
+Quote Post
Yanetteee
post 29.10.2009 - 12:06
Post #3





Grupa: Bloger
Postów: 7

Nr: 7 228



CYTAT(kejsi @ 29.10.2009 - 11:54) *
Leniuszku w pliku archive.php

KOD
<?php the_excerpt() ?>
zamień na

KOD
<?php the_content(); ?>


zmieniłam
nadal pokazuje skróty wpisów sad.gif
Go to the top of the page
 
+Quote Post
kejsi
post 29.10.2009 - 12:36
Post #4


aktywność:
*****

Grupa: +Bloger
Postów: 892

Nr: 3 286



I na pewno tej zmiany dokonujesz w pliku, do którego ścieżka wygląda tak: www.yanettee.za.pl/blog/wp-content/themes/EverlastingBlooms/archive.php ???

Bo jeśli tak, to nie wiem dlaczego nie wyświetla się cały wpis.

Ten post edytował kejsi 29.10.2009 - 12:38
Go to the top of the page
 
+Quote Post
Yanetteee
post 29.10.2009 - 12:52
Post #5





Grupa: Bloger
Postów: 7

Nr: 7 228



tak, dokładnie w tym pliku,
jeszcze raz od nowa i nadal nie działa wacko.gif
Go to the top of the page
 
+Quote Post
Yanetteee
post 29.10.2009 - 17:09
Post #6





Grupa: Bloger
Postów: 7

Nr: 7 228



może ktoś inny pomoże ?? crybaby.gif
Go to the top of the page
 
+Quote Post
amistad18
post 29.10.2009 - 17:25
Post #7


aktywność:
*********

Grupa: Redakcja
Postów: 4 254

Nr: 5 919



Powiedz jakie pliki masz w katalogu Twojego thema, oraz pokaż jak obecnie wygląda Twój plik archive.php - także z katalogu thema.
Go to the top of the page
 
+Quote Post
Yanetteee
post 29.10.2009 - 19:25
Post #8





Grupa: Bloger
Postów: 7

Nr: 7 228






KOD
<?php get_header(); ?>

    <div id="content" class="narrowcolumn">

        <?php if (have_posts()) : ?>

         <?php $post = $posts[0]; // Hack. Set $post so that the_date() works. ?>
<?php /* If this is a category archive */ if (is_category()) { ?>                
        <h2 class="pagetitle">Archive for the '<?php echo single_cat_title(); ?>' Category</h2>
        
      <?php /* If this is a daily archive */ } elseif (is_day()) { ?>
        <h2 class="pagetitle">Archive for <?php the_time('F jS, Y'); ?></h2>
        
     <?php /* If this is a monthly archive */ } elseif (is_month()) { ?>
        <h2 class="pagetitle">Archive for <?php the_time('F, Y'); ?></h2>

        <?php /* If this is a yearly archive */ } elseif (is_year()) { ?>
        <h2 class="pagetitle">Archive for <?php the_time('Y'); ?></h2>
        
      <?php /* If this is a search */ } elseif (is_search()) { ?>
        <h2 class="pagetitle">Search Results</h2>
        
      <?php /* If this is an author archive */ } elseif (is_author()) { ?>
        <h2 class="pagetitle">Author Archive</h2>

        <?php /* If this is a paged archive */ } elseif (isset($_GET['paged']) && !empty($_GET['paged'])) { ?>
        <h2 class="pagetitle">Blog Archives</h2>

        <?php } ?>


        <div class="navigation">
            <div class="alignleft"><?php posts_nav_link('','','&laquo; Previous Entries') ?></div>
            <div class="alignright"><?php posts_nav_link('','Next Entries &raquo;','') ?></div>
        </div>

        <?php while (have_posts()) : the_post(); ?>
        <div class="post">
                <h3 id="post-<?php the_ID(); ?>"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><?php the_title(); ?></a></h3>
                <small><?php the_time('l, F jS, Y') ?></small>
                
                <div class="entry">
                    <?php the_content(); ?>
                </div>
        
                <p class="postmetadata">Posted in <?php the_category(', ') ?> <strong>|</strong> <?php edit_post_link('Edit','','<strong>|</strong>'); ?>  <?php comments_popup_link('No Comments »', '1 Comment »', '% Comments »'); ?></p>
                
                <!--
                <?php trackback_rdf(); ?>
                -->
            </div>
    
        <?php endwhile; ?>

        <div class="navigation">
            <div class="alignleft"><?php posts_nav_link('','','&laquo; Previous Entries') ?></div>
            <div class="alignright"><?php posts_nav_link('','Next Entries &raquo;','') ?></div>
        </div>
    
    <?php else : ?>

        <h2 class="center">Not Found</h2>
        <?php include (TEMPLATEPATH . '/searchform.php'); ?>

    <?php endif; ?>
        
    </div>

<?php get_sidebar(); ?>

<?php get_footer(); ?>
Go to the top of the page
 
+Quote Post
amistad18
post 29.10.2009 - 19:46
Post #9


aktywność:
*********

Grupa: Redakcja
Postów: 4 254

Nr: 5 919



No to testujemy. Spróbuj teraz poprawić tam kod na taki:
KOD
<div class="entry">
               ....  <?php the_content(); ?>
                </div>
Go to the top of the page
 
+Quote Post
Yanetteee
post 29.10.2009 - 20:04
Post #10





Grupa: Bloger
Postów: 7

Nr: 7 228



nie działa, dodało jedynie .... na początku posta w archiwum
http://www.yanettee.za.pl/blog/2009/10/#0
Go to the top of the page
 
+Quote Post
kejsi
post 29.10.2009 - 20:39
Post #11


aktywność:
*****

Grupa: +Bloger
Postów: 892

Nr: 3 286



CYTAT(Yanetteee @ 29.10.2009 - 20:04) *
nie działa, dodało jedynie ....


...to przynajmniej wiemy, że zmiany zachodzą, ale niekoniecznie tam gdzie trzeba.
Wiesz co, zmień na chwilę motyw na defaultowy i wtedy zobaczymy, bo może masz coś skopane w bazie
Go to the top of the page
 
+Quote Post
Yanetteee
post 29.10.2009 - 20:53
Post #12





Grupa: Bloger
Postów: 7

Nr: 7 228



a nie rozwali mi wpisów itp. jak zmienie motyw ?

sory za glupie pytania, ale ja dopiero zaczynam, i nie orientuje sie w tym

Ten post edytował Yanetteee 29.10.2009 - 20:55
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



: 22 05 12 - 10:39