WordPress.org

Ready to get started?Download WordPress

Forums

How to intergrate Read More Image? (6 posts)

  1. sngsl
    Member
    Posted 4 years ago #

    Hi everyone?

    for now in my theme when i write in a Excerpts section it showing a Read more link to read full post.

    can i integrate a image to automatically insert to Excerpts view and when click on it need to view full post

    i mean, if my post ID is ?p=5 the image need to get ?p=5#more-5

    i don't know this is possible or not in now in adding this button and linking to read more code manually in to the Excerpts windows. if this possible it will grate help to me...

    i can't think how to do it because i don't have PHP or CSS knowledge..

    Hope someone will help me as soon as possible..

  2. Joni
    Member
    Posted 4 years ago #

    Try this, in your index.php file:

    <?php the_excerpt (); ?>
    <a href="<?php the_permalink(); ?>" class="more-button">&nbsp;</a>

    And here's the css to style the button:

    .more-button {
       background: url(images/more-button.gif) no-repeat 0 0;
       cursor: pointer;
       width: 77px;
       height: 22px;
       font-size: 0;
       line-height: 0;
       text-indent: -9999px;
       display: block;
    }

    Of course you can name your class anything, and provide the image of your choosing in your stylesheet.

    HTH

  3. sngsl
    Member
    Posted 4 years ago #

    Hi jonimueller,

    Thank you so much for your quick response.

    I'll try it and post a result here soon...

    please post anyone have a other ideas about it...

    Thanks...

  4. sngsl
    Member
    Posted 4 years ago #

    Hi jonimueller,

    I tried your codes but it's not working for me...

    can you tell me whats wrong please...

    Thanx

  5. sngsl
    Member
    Posted 4 years ago #

    Hi guys...

    Can anyone suggest me another way or another codes?

    I tried the codes given by jonimueller but it didn't work for me. don't know that i had a mistake or not.. please help me...

    Thank you...

  6. sngsl
    Member
    Posted 4 years ago #

    It's Works 100%. Thank you so much jonimueller.

Topic Closed

This topic has been closed to new replies.

About this Topic