-
AuthorPosts
-
February 8th, 2013 at 23:18 #3552Bob M.
Hello!
First, I’ll admit to being a word press newb, so I might just be missing a simple setting. I’m playing with Mantra and am liking it alot. However, In creating a photo gallery I noticed that when you click an image from the gallery, the page has a comments box (see <a href=”http://wpmrm.org/beta/?attachment_id=87″ this page </a> ). I would like to disable it and I just find how to do that.
Also, I have the Share buttons turned on and they are showing up on the secondary pages, but not the presentation page, and I guess they should probably also show up on the image page as well, but that’s not too big of a deal to me.
Thanks!
Bob
February 11th, 2013 at 21:39 #3608KayCryout Creations mastermindHi!
You need to create a child theme and paste the following code in the chlild themes’ functions.php file. Or you can add this in mantra’s functions.php file but the changes will be lost when you update to another version.
function hide_attachment_comments( $open, $post_id ) {
$post = get_post( $post_id );
if( $post->post_type == 'attachment' ) {
return false;
}
return $open;
}
add_filter( 'comments_open', 'hide_attachment_comments', 10 , 2 );
Before posting consider reading our short theme debugging instructions.
Please read the FAQs: Mantra • Nirvana • Parabola • Tempera
Tutorials: custom menus • translating theme • installing theme • category page with intro • disabling comments Wordpress: child themes • categories/posts
Before making any modifications to your theme we strongly recommend using Child Themes.February 19th, 2013 at 22:43 #3730Bob M.Thanks, I modified the functions.php and that seems to have done the trick.
Any update on the share buttons not showing up on the presentation page?
Bob
February 21st, 2013 at 12:29 #3767KayCryout Creations mastermindHi!
The share plugin attaches itself to posts or created pages. As the presentation page is neither of them it has nothing to attach to. We’ll fix that in the next theme update.
Before posting consider reading our short theme debugging instructions.
Please read the FAQs: Mantra • Nirvana • Parabola • Tempera
Tutorials: custom menus • translating theme • installing theme • category page with intro • disabling comments Wordpress: child themes • categories/posts
Before making any modifications to your theme we strongly recommend using Child Themes. -
AuthorPosts
The topic ‘Disable Comments for images’ is closed to new replies.