Skip to main content

All Questions

Tagged with
Filter by
Sorted by
Tagged with
27 votes
4 answers
36k views

Manually set global $post vars with an ID, in order to use template tags

I have a function retrieving ID's of posts by very specific means. I need to be able to set the global $post in order to use functions like the_content(), which does not allow an ID as a parameter. ...
Mild Fuzz's user avatar
  • 4,190
4 votes
1 answer
24k views

Define Function in functions.php or plugin and call in theme loop

I need to define a function in functions.php or a plugin and be able to call it inside the theme's loop & outside. Example; I have a $product_price = get_post_meta(get_the_ID(), 'product-price', ...
Raphaello's user avatar
0 votes
1 answer
74 views

Place content inside the Post Loop

Has anyone had any luck manipulating the Post Loop to insert content between post data? I'm looking to post content in between my posts as they are displayed on the archive, and homepage templates. ...
Brian's user avatar
  • 1