0
votes
0answers
21 views

Custom Shortcode that includes filtering by tag

Within a custom shortcode, how do I filter the posts that come back from get_posts() such that only posts with Tag = "xyz" are returned? Here is what I have in my shortcode currently: $args = array( ...
0
votes
2answers
48 views

Strange get_the_* behavior with php 5.4

Let me try to explain what happened to me : I have a shortcode plugin which display child pages of the current page (a mod of http://wpist.me/wp/child-pages-shortcode/, very useful). In the display ...
0
votes
3answers
309 views

shortcode for recent custom type post

I'm not a coder so I may have done some "coding" crimes, apologies. I've bought a theme who has shortcodes for last posts but not for last "custom post type". So I tried to create last "custom post ...
0
votes
2answers
843 views

get_posts displaying wrong permalink for “continue reading” link

I lifted the "continue reading" link functions from the Twenty Eleven theme and for the most part, it is working (works in RSS feeds). I created a shortcode to display the latest post on the front ...
1
vote
1answer
1k views

get_the_content(“more…”) returns full text

I'm creating shortcode [latest_post] and want to show post date, title and short content. (content has "more" separator). Here is code: function shortcode_latest_post() { global $post, $more; ...
0
votes
2answers
537 views

get_posts not working on homepage?

I have a simple custom shortcode plugin where you give it a tag and it'll display the titles of all the posts with that tag. e.g. In my post if I type "[listposts tag=oct-2011]" it will output the ...