<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.0.1" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>Gravity Support Forums Topic: Does GF have a conditional function to check if there is a form on the page?</title>
		<link>https://legacy.forums.gravityhelp.com/topic/does-gf-have-a-conditional-function-to-check-if-there-is-a-form-on-the-page</link>
		<description>Gravity Support Forums Topic: Does GF have a conditional function to check if there is a form on the page?</description>
		<language>en-US</language>
		<pubDate>Sun, 19 Apr 2026 22:13:27 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.0.1</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>https://legacy.forums.gravityhelp.com/search.php</link>
		</textInput>
		<atom:link href="https://legacy.forums.gravityhelp.com/rss/topic/does-gf-have-a-conditional-function-to-check-if-there-is-a-form-on-the-page" rel="self" type="application/rss+xml" />

		<item>
			<title>Richard Vav on "Does GF have a conditional function to check if there is a form on the page?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/does-gf-have-a-conditional-function-to-check-if-there-is-a-form-on-the-page#post-321200</link>
			<pubDate>Thu, 13 Jun 2013 16:34:25 +0000</pubDate>
			<dc:creator>Richard Vav</dc:creator>
			<guid isPermaLink="false">321200@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;It is my experience that the Gravity Forms scripts and styles are only enqueued and included on a post/page if there is form embedded on the post/page, what method are you using to embed the forms, what versions of WordPress and Gravity Forms are you using, are you using any add ons.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>gluethje on "Does GF have a conditional function to check if there is a form on the page?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/does-gf-have-a-conditional-function-to-check-if-there-is-a-form-on-the-page#post-321169</link>
			<pubDate>Thu, 13 Jun 2013 16:09:21 +0000</pubDate>
			<dc:creator>gluethje</dc:creator>
			<guid isPermaLink="false">321169@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I'm looking for a good way to only load the GF CSS and JS files if there is a form on the page. Many times there are only one or 2 pages on the site with a form, and it wold be nice not to have to load all of those files on pages where they're not needed.&#60;/p&#62;
&#60;p&#62;I have gone the route of toggling &#34;Output CSS&#34; to &#34;No&#34; in settings, registering my own copy of the stylesheet, and then conditionally enqueueing it on a per page basis:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;// Register Gravity Forms style sheet
wp_register_style( &#38;#39;gravity-forms&#38;#39;, get_stylesheet_directory_uri() . &#38;#39;/library/css/gravity-forms.css&#38;#39;, array(), &#38;#39;&#38;#39; );

// Only load it on Contact Us page
if(is_page(&#38;#39;contact-us&#38;#39;)){
    wp_enqueue_style(&#38;#39;gravity-forms&#38;#39;);
}&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;but that is prone to breaking if the page with the form on it changes, a new form is added somewhere else, etc. &#60;/p&#62;
&#60;p&#62;It would be awesome to have a &#60;code&#62;is_gforms&#60;/code&#62; conditional to use.
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
