enter code here
var v = document.getElementsByTagName('html')[0].style.top.toString().substring(0, 2);
if (parseInt(v, 10) > 0) {
var pxx = (v + 35).toString();
document.getElementsByTagName('html')[0].style.position = "relative"
document.getElementsByTagName('html')[0].style.top = pxx + "px";
}
else {
document.getElementsByTagName('html')[0].style.position = "relative"
document.getElementsByTagName('html')[0].style.top = "35px";
}
var url = chrome.extension.getURL('docz/links.html');
var fRame = $(document.createElement('iframe'));
var wrapDiv = $(document.createElement('div'));
wrapDiv.attr('id','wDiv');
wrapDiv.css('width','100%');
wrapDiv.css('height','35px' );
wrapDiv.css('position','fixed' );
wrapDiv.css('top','0 !important');
wrapDiv.css('z-index','2147482637');
fRame.attr('id','fr1');
fRame.attr('scrolling','no');
fRame.attr('src',url);
fRame.attr('frameborder','0');
fRame.css('position','absolute');
fRame.css('top', '0 !important');
fRame.css('width','100%');
fRame.css('height','35px');
fRame.css('border','none');
fRame.css('border-radius','10px 10px 10px 10px');
fRame.css('background-color','silver');
fRame.appendTo(wrapDiv);
wrapDiv.prependTo(document.body);
try this... before was more crude approach put this code int $(function(){});