The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Content on the background

2 posters

Go down

Content on the background Empty Content on the background

Post by Julija June 14th 2013, 6:32 pm

Hello, so basically what I want to do is put table or some content on the marked space of forum's background:
Content on the background O57EADJ

Like here:
Content on the background CxFbrxy

(I know it's not the widget thingie, because it appears on the body of the forum.

If necessary, here's the link 
http://gtfo.justgoo.com/
avatar
Julija
Forumember

Female Posts : 48
Reputation : 0
Language : english

Back to top Go down

Content on the background Empty Re: Content on the background

Post by Julija June 15th 2013, 10:35 am

To put it in a simpler way, I want widgets to appear on the background of the forum... anyone?
avatar
Julija
Forumember

Female Posts : 48
Reputation : 0
Language : english

Back to top Go down

Content on the background Empty Re: Content on the background

Post by Ultron's Vision June 15th 2013, 11:42 am

Try it with JavaScript.

Code:
jQuery(document).ready(function(){

var t = document.getElementsByTagName("table"), nt = document.createElement("table"), b, h;

if(!t[0]) throw new Error("Invalid Site Structure."); // this line will never be reached if tables exist, I just added it to feature error handling

if(!document.body.offsetHeight || !document.documentElement.offsetHeight) {
if(!window.innerHeight || !window.outerHeight) {
alert("No CSS compability detected; current height cannot be calculated.");
} else { h = window.innerHeight; }
} else { h = document.body.offsetHeight; }

if(!t[0].style.border) var b = undefined; else b = t[0].style.border;

jQuery(nt).css({
'width' : '200px',
'height' : t + 'px',
'position' : 'fixed'
'border' : b ? b : 'none',
'overflow' : 'scroll'
});

nt.innerHTML = "<tr><td>Your HTML here.</td></tr><tr><td>This is the second row.</td></tr><tr><td>This the third row.</td></tr><tr><td>And so on.</td></tr>";

jQuery(nt).prependTo(t[0]);

});

You can add the code under Administration Panel -> Modules -> HTML & JavaScript -> JavaScript pages management -> Create a new JavaScript; name it as you like and select where you want it to appear.
Ultron's Vision
Ultron's Vision
Forumember

Male Posts : 634
Reputation : 45
Language : English | German | HTML | JavaScript | PHP | C++ | Perl | Java
Location : Vienna, Austria

http://duelacademy.net

Back to top Go down

Content on the background Empty Re: Content on the background

Post by Julija June 15th 2013, 12:37 pm

Thanks for your time, but it doesn't seem to be working
avatar
Julija
Forumember

Female Posts : 48
Reputation : 0
Language : english

Back to top Go down

Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum