1. <?php
  2. function has_gform()
  3. {
  4. $id = get_the_id();
  5. $post = get_post($id);
  6. $all_content = apply_filters('the_content', $post->post_content);
  7. if(strpos($all_content, '[gravityform') !== false)
  8. {
  9. return true;
  10. }
  11. else
  12. {
  13. return false;
  14. }
  15. }
Comments powered by Disqus