Differentiate attachment pages in search results

Found out how to do it, I added the following in content.php. I added the second elseif statement and simple put the word Document in there before it displays the title of the page. if ( is_single() ) { the_title( ‘<h1 class=”entry-title”>’, ‘</h1>’ ); } elseif (get_post_type() == ‘attachment’ ) { the_title( ‘<h1 class=”entry-title”>Document: <a … Read more

page creator to leave comments ONLY

There’s probably a way to do this via one of the meta cap filters, but off the top of my head you could use the comments_open filter to check if the currently logged in user is the author of the post and change the output of the comments_open() function accordingly. I’m on the patio, so … Read more

Plugin dont Work Inside AJAX Call

All AJAX calls in WordPress run through admin. So if you wrap something inside if ( ! is_admin() ) { // stuff } then the AJAX call would not be able to know about this part. In other words, it does not get executed. I don’t know what this plugin specifically does, but if only … Read more