Advertisement
Guest User

Untitled

a guest
Jan 20th, 2018
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.45 KB | None | 0 0
  1. <?php
  2. /*
  3. Template Name: Klienci
  4. */
  5.  
  6. get_header(); ?>
  7.  
  8. <?php
  9.  
  10. if (is_user_logged_in()):
  11.  
  12. global $wpdb;
  13. $customers = $wpdb->get_results("SELECT * FROM wp_formmaker_submits;");
  14.  
  15. echo "<table>";
  16. foreach($customers as $customer){
  17.  
  18.  
  19. echo "<span>".$customer->element_value."</span>";
  20.  
  21. }
  22. echo "</table>";
  23. else:
  24. echo "Sorry, only registered users can view this information";
  25. endif;
  26.  
  27. ?>
  28.  
  29.  
  30.  
  31. <?php get_sidebar(); ?>
  32. <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement