Snipt.net is closing on December 31st, 2016

For more information, please visit this blog post.

snipt

Ctrl+h for KB shortcuts

Ruby

Capture web screenshots with Ruby

1
2
3
4
5
6
require 'grabzit'

grabzItClient = GrabzIt::Client.new("YOUR APPLICATION KEY", 
    "YOUR APPLICATION SECRET")
grabzItClient.set_image_options("http://www.google.com")
grabzItClient.save_to("test.jpg") 
https://snipt.net/embed/585c33e20b7874335bb10411c830cde9/
https://snipt.net/raw/585c33e20b7874335bb10411c830cde9/
585c33e20b7874335bb10411c830cde9
rb
Ruby
6
2016-12-02T11:47:42
True
False
False
/api/public/snipt/124413/
capture-web-screenshots-with-ruby
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><a href="#L-1">1</a> <a href="#L-2">2</a> <a href="#L-3">3</a> <a href="#L-4">4</a> <a href="#L-5">5</a> <a href="#L-6">6</a></pre></div></td><td class="code"><div class="highlight"><pre><span></span><span id="L-1"><a name="L-1"></a><span class="nb">require</span> <span class="s1">&#39;grabzit&#39;</span> </span><span id="L-2"><a name="L-2"></a> </span><span id="L-3"><a name="L-3"></a><span class="n">grabzItClient</span> <span class="o">=</span> <span class="no">GrabzIt</span><span class="o">::</span><span class="no">Client</span><span class="o">.</span><span class="n">new</span><span class="p">(</span><span class="s2">&quot;YOUR APPLICATION KEY&quot;</span><span class="p">,</span> </span><span id="L-4"><a name="L-4"></a> <span class="s2">&quot;YOUR APPLICATION SECRET&quot;</span><span class="p">)</span> </span><span id="L-5"><a name="L-5"></a><span class="n">grabzItClient</span><span class="o">.</span><span class="n">set_image_options</span><span class="p">(</span><span class="s2">&quot;http://www.google.com&quot;</span><span class="p">)</span> </span><span id="L-6"><a name="L-6"></a><span class="n">grabzItClient</span><span class="o">.</span><span class="n">save_to</span><span class="p">(</span><span class="s2">&quot;test.jpg&quot;</span><span class="p">)</span> </span></pre></div> </td></tr></table>
"screen capture", "screen grab", api, screenshots

C#

Get current page URL from Sitecore API

var currentUrl = Sitecore.Links.LinkManager.GetItemUrl(Sitecore.Context.Item);
https://snipt.net/embed/7769d43292c3a00b0447095f0d86be71/
https://snipt.net/raw/7769d43292c3a00b0447095f0d86be71/
7769d43292c3a00b0447095f0d86be71
csharp
C#
2
2016-12-05T18:25:27
True
False
False
Nov 26, 2013 at 06:38 PM
/api/public/snipt/96922/
get-current-page-url-from-sitecore-api
<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="kt">var</span> <span class="n">currentUrl</span> <span class="p">=</span> <span class="n">Sitecore</span><span class="p">.</span><span class="n">Links</span><span class="p">.</span><span class="n">LinkManager</span><span class="p">.</span><span class="n">GetItemUrl</span><span class="p">(</span><span class="n">Sitecore</span><span class="p">.</span><span class="n">Context</span><span class="p">.</span><span class="n">Item</span><span class="p">);</span> </span></pre></div> </td></tr></table>
api, c#, sitecore

Text only

This is a test of the API. This is only a test.

Flappers!
https://snipt.net/embed/5885bb5138c81312a5ebea81993f066e/
https://snipt.net/raw/5885bb5138c81312a5ebea81993f066e/
5885bb5138c81312a5ebea81993f066e
text
Text only
1
2016-12-02T11:48:06
True
False
False
/api/public/snipt/39930/
this-is-a-test-of-the-api-this-is-only-a-test
<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>Flappers! </span></pre></div> </td></tr></table>
api, snipt
Copyrighted, illegal, or inappropriate content? Email [email protected].