snipt

Ctrl+h for KB shortcuts

HTML+PHP

WP Print

<?php if(function_exists('wp_print')) { print_link(); } ?>
https://snipt.net/embed/03c564b3587162ee4198d544184c272b/
/raw/03c564b3587162ee4198d544184c272b/
03c564b3587162ee4198d544184c272b
html+php
HTML+PHP
1
2019-07-08T06:13:49
True
False
False
/api/public/snipt/732/
wp-print
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><a href="#L-1">1</a></pre></div></td><td class="code"><div class="highlight"><pre><span></span><span id="L-1"><a name="L-1"></a><span class="cp">&lt;?php</span> <span class="k">if</span><span class="p">(</span><span class="nb">function_exists</span><span class="p">(</span><span class="s1">&#39;wp_print&#39;</span><span class="p">))</span> <span class="p">{</span> <span class="nx">print_link</span><span class="p">();</span> <span class="p">}</span> <span class="cp">?&gt;</span> </span></pre></div> </td></tr></table>
plugins

HTML+PHP

WP Email This

<?php if(function_exists('wp_email')) { email_link(); } ?>
https://snipt.net/embed/9fcb388cc6764772fdcaee812f591771/
/raw/9fcb388cc6764772fdcaee812f591771/
9fcb388cc6764772fdcaee812f591771
html+php
HTML+PHP
1
2019-07-09T11:37:55
True
False
False
/api/public/snipt/731/
wp-email-this
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><a href="#L-1">1</a></pre></div></td><td class="code"><div class="highlight"><pre><span></span><span id="L-1"><a name="L-1"></a><span class="cp">&lt;?php</span> <span class="k">if</span><span class="p">(</span><span class="nb">function_exists</span><span class="p">(</span><span class="s1">&#39;wp_email&#39;</span><span class="p">))</span> <span class="p">{</span> <span class="nx">email_link</span><span class="p">();</span> <span class="p">}</span> <span class="cp">?&gt;</span> </span></pre></div> </td></tr></table>
plugins

HTML+PHP

Display only on index.php

<?php if ( ( is_home() ) ) { ?>
<?php } ?>
https://snipt.net/embed/a428d3876a463973b0af7e25bc0a83b1/
/raw/a428d3876a463973b0af7e25bc0a83b1/
a428d3876a463973b0af7e25bc0a83b1
html+php
HTML+PHP
2
2019-06-23T16:54:44
True
False
False
/api/public/snipt/730/
display-only-on-indexphp
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><a href="#L-1">1</a> <a href="#L-2">2</a></pre></div></td><td class="code"><div class="highlight"><pre><span></span><span id="L-1"><a name="L-1"></a><span class="cp">&lt;?php</span> <span class="k">if</span> <span class="p">(</span> <span class="p">(</span> <span class="nx">is_home</span><span class="p">()</span> <span class="p">)</span> <span class="p">)</span> <span class="p">{</span> <span class="cp">?&gt;</span> </span><span id="L-2"><a name="L-2"></a><span class="cp">&lt;?php</span> <span class="p">}</span> <span class="cp">?&gt;</span> </span></pre></div> </td></tr></table>
special

HTML+PHP

Generate PDF

http://savepageaspdf.pdfonline.com/pdfonline/pdfonline.asp?cURL=<?php the_permalink();?>
https://snipt.net/embed/413af47a4a66a13de8fb01c47a803db6/
/raw/413af47a4a66a13de8fb01c47a803db6/
413af47a4a66a13de8fb01c47a803db6
html+php
HTML+PHP
1
2019-07-12T04:45:46
True
False
False
/api/public/snipt/729/
generate-pdf
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><a href="#L-1">1</a></pre></div></td><td class="code"><div class="highlight"><pre><span></span><span id="L-1"><a name="L-1"></a>http://savepageaspdf.pdfonline.com/pdfonline/pdfonline.asp?cURL=<span class="cp">&lt;?php</span> <span class="nx">the_permalink</span><span class="p">();</span><span class="cp">?&gt;</span> </span></pre></div> </td></tr></table>
loop

HTML+PHP

Custom Field

<?php echo get_post_meta($post->ID, 'client-site-url', true); ?>
https://snipt.net/embed/fc7534a9484335ef3f8c3e6dcba56243/
/raw/fc7534a9484335ef3f8c3e6dcba56243/
fc7534a9484335ef3f8c3e6dcba56243
html+php
HTML+PHP
1
2019-07-18T19:00:55
True
False
False
/api/public/snipt/728/
custom-field
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><a href="#L-1">1</a></pre></div></td><td class="code"><div class="highlight"><pre><span></span><span id="L-1"><a name="L-1"></a><span class="cp">&lt;?php</span> <span class="k">echo</span> <span class="nx">get_post_meta</span><span class="p">(</span><span class="nv">$post</span><span class="o">-&gt;</span><span class="na">ID</span><span class="p">,</span> <span class="s1">&#39;client-site-url&#39;</span><span class="p">,</span> <span class="k">true</span><span class="p">);</span> <span class="cp">?&gt;</span> </span></pre></div> </td></tr></table>
loop

HTML+PHP

Post Avatar

<?php if (function_exists('gkl_postavatar')) gkl_postavatar(); ?>
https://snipt.net/embed/20be75b12e384cbd0fe06aad5b0cbe17/
/raw/20be75b12e384cbd0fe06aad5b0cbe17/
20be75b12e384cbd0fe06aad5b0cbe17
html+php
HTML+PHP
1
2019-07-04T17:53:59
True
False
False
/api/public/snipt/727/
post-avatar
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><a href="#L-1">1</a></pre></div></td><td class="code"><div class="highlight"><pre><span></span><span id="L-1"><a name="L-1"></a><span class="cp">&lt;?php</span> <span class="k">if</span> <span class="p">(</span><span class="nb">function_exists</span><span class="p">(</span><span class="s1">&#39;gkl_postavatar&#39;</span><span class="p">))</span> <span class="nx">gkl_postavatar</span><span class="p">();</span> <span class="cp">?&gt;</span> </span></pre></div> </td></tr></table>
plugins

HTML+PHP

Related Posts

<?php if (function_exists('related_posts')) related_posts(); ?>
https://snipt.net/embed/180f84e0214939c6b10266039d2dc96e/
/raw/180f84e0214939c6b10266039d2dc96e/
180f84e0214939c6b10266039d2dc96e
html+php
HTML+PHP
1
2019-07-10T10:59:54
True
False
False
/api/public/snipt/726/
related-posts
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><a href="#L-1">1</a></pre></div></td><td class="code"><div class="highlight"><pre><span></span><span id="L-1"><a name="L-1"></a><span class="cp">&lt;?php</span> <span class="k">if</span> <span class="p">(</span><span class="nb">function_exists</span><span class="p">(</span><span class="s1">&#39;related_posts&#39;</span><span class="p">))</span> <span class="nx">related_posts</span><span class="p">();</span> <span class="cp">?&gt;</span> </span></pre></div> </td></tr></table>
plugins

HTML+PHP

Submit to del.icio.us

http://del.icio.us/post?url=<?php echo get_permalink() ?>&title=<?php the_title(); ?>
https://snipt.net/embed/a399469a0425241a767cd4053ee3c126/
/raw/a399469a0425241a767cd4053ee3c126/
a399469a0425241a767cd4053ee3c126
html+php
HTML+PHP
1
2019-07-12T03:00:20
True
False
False
/api/public/snipt/725/
submit-to-delicious
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><a href="#L-1">1</a></pre></div></td><td class="code"><div class="highlight"><pre><span></span><span id="L-1"><a name="L-1"></a>http://del.icio.us/post?url=<span class="cp">&lt;?php</span> <span class="k">echo</span> <span class="nx">get_permalink</span><span class="p">()</span> <span class="cp">?&gt;</span><span class="err">&amp;</span>title=<span class="cp">&lt;?php</span> <span class="nx">the_title</span><span class="p">();</span> <span class="cp">?&gt;</span> </span></pre></div> </td></tr></table>
social

HTML+PHP

UBD Block Ad Plugin

<?php if (function_exists('affiliate_code_link')) { affiliate_code_link(); } ?>
https://snipt.net/embed/9dcb5614f362138d037a7f88837c3a93/
/raw/9dcb5614f362138d037a7f88837c3a93/
9dcb5614f362138d037a7f88837c3a93
html+php
HTML+PHP
1
2019-07-10T07:40:54
True
False
False
/api/public/snipt/724/
ubd-block-ad-plugin
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><a href="#L-1">1</a></pre></div></td><td class="code"><div class="highlight"><pre><span></span><span id="L-1"><a name="L-1"></a><span class="cp">&lt;?php</span> <span class="k">if</span> <span class="p">(</span><span class="nb">function_exists</span><span class="p">(</span><span class="s1">&#39;affiliate_code_link&#39;</span><span class="p">))</span> <span class="p">{</span> <span class="nx">affiliate_code_link</span><span class="p">();</span> <span class="p">}</span> <span class="cp">?&gt;</span> </span></pre></div> </td></tr></table>
plugins

HTML+PHP

Submit to Digg

http://digg.com/submit?phase=2&url=<?php echo get_permalink() ?>&title=<?php the_title(); ?>
https://snipt.net/embed/dc042db4ec6ffb1ba7768395e894f7d8/
/raw/dc042db4ec6ffb1ba7768395e894f7d8/
dc042db4ec6ffb1ba7768395e894f7d8
html+php
HTML+PHP
1
2019-07-11T07:28:32
True
False
False
/api/public/snipt/723/
submit-to-digg
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><a href="#L-1">1</a></pre></div></td><td class="code"><div class="highlight"><pre><span></span><span id="L-1"><a name="L-1"></a>http://digg.com/submit?phase=2<span class="err">&amp;</span>url=<span class="cp">&lt;?php</span> <span class="k">echo</span> <span class="nx">get_permalink</span><span class="p">()</span> <span class="cp">?&gt;</span><span class="err">&amp;</span>title=<span class="cp">&lt;?php</span> <span class="nx">the_title</span><span class="p">();</span> <span class="cp">?&gt;</span> </span></pre></div> </td></tr></table>
social