Tagged Questions
0
votes
1answer
157 views
How to check if post/page or taxonomy post is published by admin
Example :- 10 users and 2 admin in a site.
If the post is published by admins than
<?php ?????() { ?>
<!-- do this -->
<?php }
else { ?>
<!-- do this if posted by ...
4
votes
1answer
645 views
How to determine whether we are in add New page/post/CPT or in edit page/post/CPT in wordpress admin?
This seems like simple thing but I need way to determine whether the current screen is for Add New or Edit ( a sort of wordpress admin conditional tag). Is there a built in function for this already, ...
2
votes
3answers
197 views
Conditional check for front-end which includes ajax
I need a conditional which exits if the context is not a front-end view including AJAX requests. I have this at the moment:
if (is_admin() && !DOING_AJAX)
return;
The DOING_AJAX bit ...