<?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: Make an image a link in Post Template?</title>
		<link>https://legacy.forums.gravityhelp.com/topic/make-an-image-a-link-in-post-template</link>
		<description>Gravity Support Forums Topic: Make an image a link in Post Template?</description>
		<language>en-US</language>
		<pubDate>Fri, 17 Apr 2026 05:29:38 +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/make-an-image-a-link-in-post-template" rel="self" type="application/rss+xml" />

		<item>
			<title>Chris Hajer on "Make an image a link in Post Template?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/make-an-image-a-link-in-post-template#post-77665</link>
			<pubDate>Thu, 27 Sep 2012 11:44:39 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">77665@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Thank you for the update.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>UWEX on "Make an image a link in Post Template?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/make-an-image-a-link-in-post-template#post-77652</link>
			<pubDate>Thu, 27 Sep 2012 10:27:22 +0000</pubDate>
			<dc:creator>UWEX</dc:creator>
			<guid isPermaLink="false">77652@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;This works perfectly. Thanks!!!
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Chris Hajer on "Make an image a link in Post Template?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/make-an-image-a-link-in-post-template#post-77637</link>
			<pubDate>Thu, 27 Sep 2012 08:36:14 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">77637@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Take a look at this code: &#60;a href=&#34;http://pastebin.com/FwLbc09A&#34; rel=&#34;nofollow&#34;&#62;http://pastebin.com/FwLbc09A&#60;/a&#62;  This code will be added to your theme's functions.php.  You will need to change the form ID on line 4, from 171 to your actual form ID.&#60;/p&#62;
&#60;p&#62;I took your content template and will use that when an image is uploaded. When no image is submitted with the form, since it's not a required field, an alternate content template will be used, with just &#60;strong&#62;{Details:2}&#60;/strong&#62; in it.  Let me know if you have any questions.  I removed some blank lines.  I was not sure if they were intentional for layout or not.  You can add them back in if you need them.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Chris Hajer on "Make an image a link in Post Template?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/make-an-image-a-link-in-post-template#post-77494</link>
			<pubDate>Wed, 26 Sep 2012 12:13:04 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">77494@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Can you export your form please as XML (Forms &#38;gt; Import/Export &#38;gt; top menu item &#34;Export Forms&#34;) and email it to me at &#60;a href=&#34;mailto:chris@rocketgenius.com&#34;&#62;chris@rocketgenius.com&#60;/a&#62; please? I will install it and take a look at your content template to see what needs to be made conditional and provide you some code to do that.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>UWEX on "Make an image a link in Post Template?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/make-an-image-a-link-in-post-template#post-77472</link>
			<pubDate>Wed, 26 Sep 2012 10:39:53 +0000</pubDate>
			<dc:creator>UWEX</dc:creator>
			<guid isPermaLink="false">77472@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;&#38;gt;  Or you can use the gform_pre_submission_filter to change the postContentTemplate and make your merge tag conditional. &#60;/p&#62;
&#60;p&#62;Is there any guidance on doing this?  The gform_pre_submission page doesn't seem nearly verbose enough to really even hint at how to do this.&#60;/p&#62;
&#60;p&#62;Thanks
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Chris Hajer on "Make an image a link in Post Template?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/make-an-image-a-link-in-post-template#post-77439</link>
			<pubDate>Wed, 26 Sep 2012 08:47:37 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">77439@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Sorry about the example.  Glad you were able to figure that out.  We'll take a look at the documentation.&#60;/p&#62;
&#60;p&#62;Regarding your new issue, if the field is not required, and you add the HTML to your content template, it will result in broken HTML as you have discovered.  &#60;/p&#62;
&#60;p&#62;The &#60;a href=&#34;http://www.gravityhelp.com/documentation/page/Shortcodes#Conditional_Shortcode&#34; rel=&#34;nofollow&#34;&#62;conditional shortcode&#60;/a&#62; does not work in the content template area.  You may have to use your page or post template to conditionally include the HTML if there is a value in the field.  Or you can use the &#60;a href=&#34;http://www.gravityhelp.com/documentation/page/Gform_pre_submission_filter&#34; rel=&#34;nofollow&#34;&#62;gform_pre_submission_filter&#60;/a&#62; to change the postContentTemplate and make your merge tag conditional.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>UWEX on "Make an image a link in Post Template?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/make-an-image-a-link-in-post-template#post-77354</link>
			<pubDate>Tue, 25 Sep 2012 17:01:13 +0000</pubDate>
			<dc:creator>UWEX</dc:creator>
			<guid isPermaLink="false">77354@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I got it working, but your example is just a tad off I think.&#60;/p&#62;
&#60;p&#62;{Image:5:url} still generates a full on Image tag, but if you include a SIZE before url..&#60;/p&#62;
&#60;p&#62;{Image:5:large:url} ... that gives you just the URL. &#60;/p&#62;
&#60;p&#62;However, I've now found another problem that I'm less optimistic that you can help me with.  What I wanted to do was make the small Image a link to the big, by putting this in the Template:&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;a href=&#38;#39;{Image:5:large:url}&#38;#39;&#38;gt;{Image:5:small}&#38;lt;/a&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;The problem is that the field isn't required, and it generates some broken HTML if no image is uploaded.  Is there any workaround to this?  For example...&#60;br /&#62;
&#60;code&#62;{gf_if Image:5:large:url}  :all my code:  {/gf_if}&#60;/code&#62;
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Rob Harrell on "Make an image a link in Post Template?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/make-an-image-a-link-in-post-template#post-77342</link>
			<pubDate>Tue, 25 Sep 2012 15:52:58 +0000</pubDate>
			<dc:creator>Rob Harrell</dc:creator>
			<guid isPermaLink="false">77342@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;You should be able to use a merge tag like this to get the url value: {Post Image:5:url}&#60;/p&#62;
&#60;p&#62;See this page of documentation:&#60;br /&#62;
&#60;a href=&#34;http://www.gravityhelp.com/documentation/page/Merge_Tags&#34; rel=&#34;nofollow&#34;&#62;http://www.gravityhelp.com/documentation/page/Merge_Tags&#60;/a&#62;
&#60;/p&#62;</description>
		</item>
		<item>
			<title>UWEX on "Make an image a link in Post Template?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/make-an-image-a-link-in-post-template#post-77341</link>
			<pubDate>Tue, 25 Sep 2012 15:50:03 +0000</pubDate>
			<dc:creator>UWEX</dc:creator>
			<guid isPermaLink="false">77341@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;When creating a post from a public-facing Gravity Form, I am able to insert an image of any size I want.  However, I can't figure out how to make that image a link to the original size.&#60;/p&#62;
&#60;p&#62;Any ideas?  I'm thinking I need to do something akin to:&#60;/p&#62;
&#60;p&#62;&#60;a href='{something}' rel=&#34;nofollow&#34;&#62;{Image:5:small:right}&#60;/a&#62; .. but have no idea how to get the '{something}' in the Template.
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
