Embedding Storify posts
Perhaps the lack of activity is an indicator of the obscurity of my problem, but Storify is a very popular tool so I imagine someone else might also have this issue. Here is how I solved it, thanks to a couple of colleagues helping me think creatively about this. Unfortunately my solution only works for one tool, but it could be made to work for any service with a consistent embed code.


Make a new field called Storify slug that contains the URL of the storify after storify.com/.
Add the embed code to the field's template. Below is field--field-storify-slug.tpl.php

&lt;?php foreach ($items as $delta =&gt; $item): ?&gt;
  &lt;div class="field-item &lt;?php print $delta % 2 ? 'odd' : 'even'; ?&gt;"&lt;?php print $item_attributes[$delta]; ?&gt;&gt;

    &lt;div id="storify-wrapper"&gt;
    &lt;div class="storify" id="storify-story"&gt;

    &lt;iframe allowtransparency="true" frameborder="no" height="750" src="//storify.com/&lt;?php print render($item); ?&gt;/embed?header=false&amp;amp;border=false" width="100%"&gt;&lt;/iframe&gt;
    &lt;script src="//storify.com/&lt;?php print render($item); ?&gt;.js?header=false&amp;border=false"&gt;&lt;/script&gt;
    &lt;noscript&gt;[&lt;a href="//storify.com/&lt;?php print render($item); ?&gt;" target="_blank"&gt;View on Storify&lt;/a&gt;]&lt;/noscript&gt;

    &lt;/div&gt;
    &lt;/div&gt;

  &lt;/div&gt;
&lt;?php endforeach; ?&gt;



I added the storify-story ID to deal with some bad behavior where the Storify script was rewriting the DIV it was in and adding clear: left; as in inline style.