WordPress.org

Ready to get started?Download WordPress

Forums

Display Posts Shortcode
[resolved] title of post without link (3 posts)

  1. jmichaelk
    Member
    Posted 2 years ago #

    Finally (and thank you for all of your help, as I said, this plugin helps me immensely, despite all the questions), I am hoping to just include a non-linked version of the title. I have gone into the css and I see how to do this on my own (and I was successful), but I am concerned that future updates of the plugin will wipe out my changes each time. Also, I was curious if there's any way to add a new argument (is that the right term?), that is an unlinked title, as opposed to the one included, that is (by default)linked. This would provide some flexibility, in case there was some area that I wanted to include linked titles, as opposed to unlinked ones. Currently though, I don't want users to have the option to see the individual post, but instead, just an aggregated feed of all the posts together. I will be using Display Posts Shortcode on my landing page (inside a widget, but only displaying the three most recent) and also on it's own dedicated page where all posts will be included. Anyway, the question is: is my only option to go in and change the css to customize this (and risk losing it with future updates) or is there a more efficient and sustainable way of going about it? Thank you.

    http://wordpress.org/extend/plugins/display-posts-shortcode/

  2. Bill Erickson
    Member
    Plugin Author

    Posted 2 years ago #

    That's a great question. I've provided all the most common arguments, but you can fully customize the plugin using the output filter.

    I just added an output filter that checks to see if there is a title and if 'linkedtitle' equals false, then wrap the title in a span instead of a link (this way you can still style it, but it doesn't link anywhere).

    https://gist.github.com/1313677

    In my page I used this shortcode: [display-posts linkedtitle="false"]

    Every attribute that is added in the shortcode is accessible in the $atts variable. You can then use them to do whatever you like using a filter.

  3. jmichaelk
    Member
    Posted 2 years ago #

    thanks again, this worked perfectly.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic