Tagged: Placeholder
-
AuthorPosts
-
November 17, 2016 at 7:47 pm #713715
Hello Community,
If I set up a blog and add a image to a post (standard post type) everything works finde. In edit view for a post I can choose “Don’t display image on single post”. By checking these box I have a still a placeholder for the image in the single post. Is it possible to remove these placeholder if this box is checked so the text and title in the single post is alinged to left without the empty space?
Here are two images to show my problem:
https://www.dropbox.com/s/lpu5krlsv1i1mg0/edit-view_no-image.jpg
https://www.dropbox.com/s/bte2thn9610wc3r/final-view_no-image.jpg
I know about the solution with css to hide these space for the image, but then its deactivated in gerenal. I only want it deactivated if I choose the option in the post edit view. How can I realize that?
Many thanks in advance for support ;-)
- This topic was modified 7 years, 11 months ago by Yigit.
November 19, 2016 at 12:43 am #714225Ok, I figured some out.
I used this solution in this thread: https://kriesi.at/support/topic/how-to-remove-the-picture-icon-on-blog-posts/
For me its not clear why the checkbox works using a big featured image and is not working using the small featured image. Is this a bug?Cheers
November 21, 2016 at 1:50 pm #714802Hey!
The checkbox (Don’t display image on single post) does work whether you use small featured image or the big one, however it’s only applicable in the single post page, checking that option will allow you to display or hide featured image in that post only, but that option doesn’t affect anything on small or big featured image.
Best regards,
NikkoNovember 23, 2016 at 12:22 am #715668Hi Nikko,
Thanks for the answer. Just checked the behavior with a fresh installation and enfold.
If for the single post view the big preview image is selected the function hides the feature image correctly. Changing the single post view to small feature image and checking this option the feature image disappears. But now there is still the placeholder/space for the feature image.
So, for me this is not working correctly. I expect that the feature image including the placeholder is hidden ;-)- This reply was modified 8 years ago by MrDroos.
November 24, 2016 at 4:58 pm #716498Hi,
Can you please post the link to your page so we can provide you an accurate solution? :)
Best regards,
YigitNovember 24, 2016 at 7:08 pm #716547Hmm, I need to pass. I use a local installation to build up the site. Any other idea? ;)
Cheers
November 25, 2016 at 9:01 pm #717088Hi,
Could you please post a link when you launch your website?
If it is urgent, you can send a screenshot showing the whole page so we can figure out the layout and try to reproduce on our local installations :)Best regards,
YigitNovember 27, 2016 at 1:03 pm #717420Hi Yigit,
We will try it with Screenshots. Its a fresh enfold-installation.
1. WordPress settings i made:
https://www.dropbox.com/s/d5o0kdss6d5c10h/WP%20General%20settings.jpeg?dl=0
2. Enfold settings i made:
https://www.dropbox.com/s/z5i04qavtm4d1ga/enfold%20general%20setup.jpeg?dl=0
a. Setup with big featured image in single post activated
Enfold Blog Setup: https://www.dropbox.com/s/gd6ebx1ln3d9asn/enfold%20setup%20active%20big.jpeg?dl=0
Article edit view: https://www.dropbox.com/s/9shsac0m4531mh3/article%20edit%20active%20big.jpeg?dl=0
Single post view: https://www.dropbox.com/s/g90gqccecgfkvva/single%20post%20big%20active%20big.jpeg?dl=0
b. Setup with big featured image in single post deactivated
Article edit view: https://www.dropbox.com/s/h4eo4saj6y4w2j2/article%20edit%20deactivated%20big.jpeg?dl=0
Single post view: https://www.dropbox.com/s/stf0wp0b952ewet/single%20post%20deactivated%20big.jpeg?dl=0
As you can see, this all is working fine for big preview image :-)
================================================================
Now the same, but with small featured image. The general settings for WP and Enfold from the beginning of this post remain the same.
a. Setup with small featured image in single post activated
Enfold Blog Setup: https://www.dropbox.com/s/0535tiv50uq1jdo/enfold%20setup%20small.jpeg?dl=0
Article edit view: https://www.dropbox.com/s/9shsac0m4531mh3/article%20edit%20active%20big.jpeg?dl=0
Single post view: https://www.dropbox.com/s/38a1fviwdgw8kdq/single%20post%20active%20small.jpeg?dl=0
b. Setup with small featured image in single post deactivated
Article edit view: https://www.dropbox.com/s/h4eo4saj6y4w2j2/article%20edit%20deactivated%20big.jpeg?dl=0
Single post view: https://www.dropbox.com/s/hhgsq7wp79ochb8/single%20deactivated%20small.jpeg?dl=0
Now you can see that there is the placeholder for the feature image which is deactivated.
I hope you can reproduce this behavior ;-)
November 29, 2016 at 4:57 pm #718344Hi,
– Please do not choose your blog and frontpage in Settings > Reading, only choose them in Enfold theme options.
– Please use a child theme if you are not – http://kriesi.at/documentation/enfold/using-a-child-theme/ and copy enfold/includes/loop-index.php file to your child theme in the same path enfold-child/includes/loop-index.php file and then find following linesecho "<div class='blog-meta'>"; $blog_meta_output = ""; $icon = '<span class="iconfont" '.av_icon_string($post_format).'></span>'; if(strpos($blog_style, 'multi') !== false) { $gravatar = ""; $link = get_post_format_link($post_format); if($post_format == 'standard') { $author_name = apply_filters('avf_author_name', get_the_author_meta('display_name', $post->post_author), $post->post_author); $author_email = apply_filters('avf_author_email', get_the_author_meta('email', $post->post_author), $post->post_author); $gravatar_alt = esc_html($author_name); $gravatar = get_avatar($author_email, '81', "blank", $gravatar_alt); $link = get_author_posts_url($post->post_author); } $blog_meta_output = "<a href='{$link}' class='post-author-format-type'><span class='rounded-container'>".$gravatar.$icon."</span></a>"; } else if(strpos($blog_style, 'small') !== false) { $blog_meta_output = "<a href='{$link}' class='small-preview' title='{$featured_img_desc}'>".$slider.$icon."</a>"; } echo apply_filters('avf_loop_index_blog_meta', $blog_meta_output); echo "</div>";
and change it to following
if(is_single($initial_id) && get_post_meta( $current_post['the_id'], '_avia_hide_featured_image', true ) ) { $current_post['slider'] = ""; } else{ echo "<div class='blog-meta'>"; $blog_meta_output = ""; $icon = '<span class="iconfont" '.av_icon_string($post_format).'></span>'; if(strpos($blog_style, 'multi') !== false) { $gravatar = ""; $link = get_post_format_link($post_format); if($post_format == 'standard') { $author_name = apply_filters('avf_author_name', get_the_author_meta('display_name', $post->post_author), $post->post_author); $author_email = apply_filters('avf_author_email', get_the_author_meta('email', $post->post_author), $post->post_author); $gravatar_alt = esc_html($author_name); $gravatar = get_avatar($author_email, '81', "blank", $gravatar_alt); $link = get_author_posts_url($post->post_author); } $blog_meta_output = "<a href='{$link}' class='post-author-format-type'><span class='rounded-container'>".$gravatar.$icon."</span></a>"; } else if(strpos($blog_style, 'small') !== false) { $blog_meta_output = "<a href='{$link}' class='small-preview' title='{$featured_img_desc}'>".$slider.$icon."</a>"; } echo apply_filters('avf_loop_index_blog_meta', $blog_meta_output); echo "</div>"; }
Best regards,
Yigit- This reply was modified 7 years, 12 months ago by Yigit.
November 30, 2016 at 3:12 am #718611Yeaaha!
You made it! It works! Great! Thanks a lot!November 30, 2016 at 3:24 am #718614Hey!
You are welcome! :)
For your information, you can take a look at Enfold documentation here – http://kriesi.at/documentation/enfold/
And if there are features that you wish Enfold had, you can request them and vote the requested ones here – https://kriesi.at/support/enfold-feature-requests/
For any other questions or issues, feel free to post them here on the forum and we will gladly try to help you :)Regards,
Yigit -
AuthorPosts
- The topic ‘Placeholder for single post image even with "Don't display image on single post"’ is closed to new replies.