Shortcode to display Recent Posts in page

Community Forums Forums Design Tips and Tricks Shortcode to display Recent Posts in page

This topic is: not resolved

This topic contains 8 replies, has 2 voices, and was last updated by  styzer 1 year, 3 months ago.

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #35128

    styzer
    Participant
    Post count: 85

    Hi all,

    After spending the past 2 hours looking for a solution, I thought I better ask here.

    Should be simple enough, but I can’t see it:

    - I want to display Recent Posts (Excerpts with a “read more” link) on a page called News. I used the shortcode

    [display-posts tag="news" posts_per_page="3"]

    but it shows a whole lot of content. http://musicmondayca.barefootheart.com/news/

    I deleted this shortcode finally, yet the content still shows…

    I promise I’m not using drugs or alcohol…!

    Help!

    Andre

     

    #35130

    braddalton
    Participant
    Post count: 8797

    Why don’t you simply rename your blog page to news and then you can customize it using the Genesis > Theme settings > Content Archives.

    Or install this plugin http://wordpress.org/extend/plugins/display-posts-shortcode/


    Specializing In StudioPress Child Theme Customization.
    500+ StudioPress Tutorials

    #35135

    styzer
    Participant
    Post count: 85

    Thanks Brad,

    I’m using that plugin, but the Genesis setting did it!

    However, how could I also include a “read more” link at the bottom of each excerpt? Right now, people can only read the rest by clicking on the title.

    Cheers!

    Andre

    #35139

    braddalton
    Participant
    Post count: 8797

    No worries Andre.

    Change the content settings in Genesis > Theme Settings > Content Archives > Display Post Content and add a number for the limit.

    You can also customize the read more link http://www.briangardner.com/code/customize-read-more-link/


    Specializing In StudioPress Child Theme Customization.
    500+ StudioPress Tutorials

    #35141

    styzer
    Participant
    Post count: 85

    Thanks Brad,

    So I copy/pasted Brian’s code at the bottom of my functions.php file. But all I see is a … at the end of the excerpts as before. Something I’m not doing right?

    Andre

     

    #35155

    braddalton
    Participant
    Post count: 8797

    1. Change the settings first in the Content Archives

    2. After pasting the code you can modify the Continue Reading link in the code.

    You can also style the read more link using the class which the PHP code generates:
    [css]
    .more-link {}
    [/css]
    Then paste the CSS in your child themes style.css file if you want to add styling to the link.


    Specializing In StudioPress Child Theme Customization.
    500+ StudioPress Tutorials

    #35158

    styzer
    Participant
    Post count: 85

    Hey Brad,

    Just back-stepping a bit: do I need a shortcode or a hook in order to display a post-type on a specific page? I need to display post types that were created using templates (tpl_arrangements.php). Now those pages don’t show content although they show on the menu.

    All it shows now are post excerpts…

    http://musicmondayca.barefootheart.com/arrangements/

    Shortcode – what code (or link to a list?)

    Hooks – code and file to edit

    Thanks! I think once I get that sorted out, it's going to be a breeze to complete the site.

    Regards,

    Andre

    #35160

    braddalton
    Participant
    Post count: 8797

    If the plugin doesn’t support custom post types, you’ll need a custom function or another plugin.


    Specializing In StudioPress Child Theme Customization.
    500+ StudioPress Tutorials

    #35170

    styzer
    Participant
    Post count: 85

    Hi all,

    I would like to know how I can see the custom-types templates in my editor sidebar in order to select a particular one?
    http://musicmondayca.barefootheart.com/arrangements/

    You should be able to see a whole list of documents, but none are found.

    Yet, when I check in the plugin, under Manage, I can see the arrangements post-type, and selecting the code, I pasted it at the bottom of my functions.php file.

    If I click the Arrangements link in the left-menu in the admin, I can see all the documents under Arrangements.

    Anyone has any idea why?

    BTW, this used to be a Multi-site, but it’s been separated in two individual sites. Could that be the reason?

    Thanks for any help!

    Regards,

    Andre

    http://wordpress.org/extend/plugins/custom-post-type-ui/

Viewing 9 posts - 1 through 9 (of 9 total)

You must be logged in to reply to this topic.