Guest User

Untitled

a guest
Dec 14th, 2017
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.65 KB | None | 0 0
  1. // ...
  2. <?php
  3. function RestrictionBoxStatus ($post) {
  4. $PostID = $post -> ID;
  5. if ($post -> post_type == "page") {
  6. $TheIDs = get_opt ("pages");
  7. }
  8. else {
  9. $TheIDs = get_opt ("posts");
  10. }
  11. if (!is_array ($page_ids)) {
  12. $page_ids = array ();
  13. }
  14. ?>
  15. <input name="pr" type="hidden" value="update">
  16. <input type="checkbox" name="restriction-status"<?php if (in_array ($PostID, $TheIDs)) echo ' checked="checked"'; ?>>
  17. Restrict This <?php echo $post -> post_type == "post" ? "Post" : "Page"; ?>
  18. <p>This setting apply only to this <b><u>
  19. <?php
  20. $post -> post_type == 'post' ? 'post' : 'page' . '</u></b> only.';
  21. _e($post);
  22. ?></p>
  23. <?php
  24. }
  25. //..
  26. ?>
Add Comment
Please, Sign In to add comment