I have a working php code saved in a view as a shortcode (it's rather long so thought this would keep my functions shorter.) I've tried various ways to append the shortcode to the post titles but nothing works. I've tried so many for hours so I'm giving up and asking for help. This was my last try...which is not close to being right, I'm guessing.
function price_after_title($title,$post_id)
{ $price_after_t = rwmb_meta('price_after_title');
return $title. $price_after_title_t;
}
add_action ('the_title', 'price_after_title_t);
Help! Thanks 🙂