Skip to content

Instantly share code, notes, and snippets.

@sammydigits
sammydigits / iframe-from-js.html
Last active August 29, 2015 14:00
Create iframe element from javascript
<script type="text/javascript">
window.onload = function(){
var jvurl = 'http://www.example.com';
var iframe = document.createElement('iframe');
iframe.frameBorder=0;
iframe.width="800px";
iframe.height="450px";
iframe.setAttribute("src", jvurl);
document.getElementById("container").innerHTML = '';
document.getElementById("container").appendChild(iframe);
@sammydigits
sammydigits / _cq_editConfig.xml
Created April 9, 2014 15:53
CQ5: Display the name/title of the component
<jcr:root xmlns:cq="http://www.day.com/jcr/cq/1.0" xmlns:jcr="http://www.jcp.org/jcr/1.0"
cq:actions="[text:Your Component Name,-,edit,delete,copymove,-,insert]"
cq:dialogMode="floating"
jcr:primaryType="cq:EditConfig">
</jcr:root>