Interwikiデモサンプル試作室

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="ja" lang="ja">
<head>
<title>Controler</title>
<title>Remort Htmlblock Controler</title>
<script type="text/javascript">
var targetFrame = null;
function resizeStart(){
if(!targetFrame){
searchTargetFrame();
if(!targetFrame){
alert();
return;
}
}
targetFrame.resizeFrame(newHeight.value);
}
function searchTargetFrame(){
var brother = window.parent.window.frames;
for(var i = 0;i < brother.length;i++){
try{
if(typeof(brother[i].resizeFrame) == "function"){
 targetFrame = brother[i];
}
 
}catch(e){
 
}
 
}
 
}
</script>
</head>
<body>
<input type="text" id="newHeight"></input><button onclick="resizeStart()">Interwiki Resize</button>
</body>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="ja" lang="ja">
<head>
<title>SampleInterWiki</title>
<script type="text/javascript">
function resizeFrame(heightNum){
while(iframeSet.childNodes.length > 0){
iframeSet.removeChild(iframeSet.firstChild);
}
var MyURL = location.href;
var MyURLArray = MyURL.split("#");
var Referrer = document.referrer;
var Mydomain = Referrer.split("//").join("/").split("/")[1];
var sendHash = "";
if(MyURLArray.length > 1){
sendHash = "#" + MyURLArray[1];
}
var Height = heightNum;
var iframe = document.createElement("iframe");
iframe.src = "http://"+Mydomain+"/common--javascript/resize-iframe.html" + "?" +"InterwikiResize"+ "#" + Height + "/2"+sendHash;
iframe.style.display = "none";
iframeSet.appendChild(iframe);
}
</script>
</head>
<body>
<iframe src="http://shitake-crude-production.wikidot.com/harmonicinterwiki-mock/code/1#11" height="500" width="100%" scrolling="no" frameborder="0"></iframe>
<div id="iframeSet"></div>
</body>
</html>
    .InterWikiContainer iframe{
    border: 5px solid #EFA9A2;
    border-radius: 10px;
    box-shadow: 0 2px 6px rgba(102,0,0,.5);
        padding: 0px !important;
        /*border: 1px solid #660000 !important;
        border-radius: 10px !important;
        box-shadow: 0 2px 6px rgba(102,0,0,.5) !important;*/
        background: #fff !important;
        margin: 0 !important;
        box-sizing: border-box !important;
        width: 16.25em !important;
    -webkit-filter: hue-rotate(40deg) brightness(110%);
    -moz-filter: hue-rotate(40deg) brightness(110%);
    -ms-filter: hue-rotate(40deg) brightness(110%);
    filter: hue-rotate(40deg) brightness(110%);
/**/
    }
.InterWikiContainer iframe[style="height: 10px;"]{
display:none !important;
border-radius: 0px !imporatant;
}
.InterWikiContainer iframe[style="height: 0px;"]{
display:none !important;
border-radius: 0px !imporatant;
}
Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License