Hello, I'm having trouble with my custom fields displaying in the preview window when I go to publish a custom post. I was getting a 404 error at first, which was fixed by saving the permalink settings. Now, however, the post title displays in preview mode, but no custom content displays along with it. I have two custom fields within my custom post, neither of which are working.
I've been looking all over for a fix but to no avail. Anybody have any similar problems?
I'm displaying my custom fields on the front end with:
$portfolioContent = get_post_meta($post->ID, 'wpcf-portfolio-content', true);
echo $portfolioContent;
Thanks for any help.
Colin
Dear colinM-2,
Types save custom fields when you press save draft/publish. When you click 'Preview' without save post, wordpress loads post from last revision, but Types plugin not do any actions for revisions. It's not a bug, it's Types plugin logic.
Please let me know if you are satisfied with my answer and if I can help you with any other questions you might have.
Regards,
Gen.
Hi Gen,
Thanks for your reply. Although Types loads the last revision, it should still be loading the page content since it has been published already. I have attached a couple of screenshots to illustrate my issue.
As shown, there is custom content published and visible in the post page. However, when the preview post button is pressed, all that shows it the post title and that the comments are closed (see attached image). Finally, I included a view of what the page looks like live. Is there a reason I can't preview the page as it appears live?
Thanks for your time and any help you can offer
Colin
Dear colinM-2,
Can you provide me credentials of your site? I will check where problem.
Please let me know if you are satisfied with my answer and if I can help you with any other questions you might have.
Regards,
Gen.
Is there an email I can reach you at with login information?
Thanks
Colin
Dear colinM-2,
Please fill form bellow this message.
Please let me know if you are satisfied with my answer and if I can help you with any other questions you might have.
Regards,
Gen.
Here is the login/ftp info:
Dear colinM-2,
I found that you use custom structure for post type 'project'. It's require #post_slug in url. But when you click preview/view project url have only #undefined.
Problem not in Types plugin, you have to review your page-project.php and javascript for this page.
Please let me know if you are satisfied with my answer and if I can help you with any other questions you might have.
Regards,
Gen.