Plugin is striping custom field URL
-
I love this plug in as it does exactly as advertised.
I added a custom image field to the custom post pages that are being pulled into the masonry layout. I added the code to call the custom field with no problem.
The issue I’m having is the field should return the URL of the image. However, it is returning the attachment ID and creating a url that includes the page the gallery is on, not the actual post. Basically it spits out a url of “https://www.examplesite.com/gallery-page/166. (Where 166 is the attachment id). It should spit out a url of “https://www.examplesite.com/wp-content/uploads/2015/05/myimage.jpg”.
Under “global $post;” near line 330 of masonry-post-gallery.php I am calling the variable with:
$logoimage = get_post_meta($post->ID,”logo2″,true);
And then inside the databox I’m using the following:
if(self::$a[‘display_post_titles’] && strlen($tit) > 0) $data_text .= “<img src='{$logoimage}’ />”;
Please help me track down where the URL is switching from the image URL to the Attachment ID.
- The topic ‘Plugin is striping custom field URL’ is closed to new replies.