PDA

View Full Version : How to get the 'floating' forum feel ??


vfxtalk
11-23-2003, 02:46 AM
Hi All,

What code is it that lets a forum scroll on a static background like how it is here: http://vbskin.pixicore.com/ ??

Is there any browser pitfalls that will not handle this ...or is there any other pitfalls to consider with this function ??

Thanks for your help and time

Paul

assassingod
11-23-2003, 07:42 AM
IIRC you would use in the headinclude template (or if you're using vB3 the body CSS bit in the Style Mananger)

background-attachment:fixed;

Erwin
11-23-2003, 08:41 AM
When I tried this, my users complained that it slowed their browsing down.

Dean C
11-23-2003, 11:36 AM
I don't think it makes that much difference :)

MindTrix
11-23-2003, 11:50 AM
Beeing a noob what does IIRC mean?

Also do you have to have an image as your background for this to work?

assassingod
11-23-2003, 11:51 AM
If I Recall Correctly

Yes (Using CSS though)

MindTrix
11-23-2003, 11:55 AM
How do you mean using CSS?

I thought you would just set an image as your background and then chuck that code you posted up there in the headinclude template.

Another stupid question, im guessing this makes the image stay in the same place?

Andddddd one last note to admins here etc, dont you think assassingod should be made a mod or something here? He's always helping out pretty much every person who asks for help and is always active.

Just my thoughts thats all.

assassingod
11-23-2003, 11:59 AM
When I mean CSS I mean using:

body {background-img:url("yourbgimg.gif");
background-attachment:fixed;}


In the headinclude template you said. IIRC You can't use the background-attachment:fixed; if you are using <body background="yourbgimg.gif">

And yes, it stops the image from moving along with the rest of the page (I believe it's popular with people who use blogs)

MindTrix
11-23-2003, 12:05 PM
Ok. At the moment my background is just erm a blue colour. But if i chuck the above code into my headinclude, it should work fine? Sorry for beeing dumb

assassingod
11-23-2003, 12:07 PM
Yeah, add it under:

BODY {

(IIRC)

MindTrix
11-23-2003, 12:10 PM
Cheers mate :)

assassingod
11-23-2003, 12:12 PM
Let me know if it doesn't work.

MindTrix
11-23-2003, 12:20 PM
ok i added this code underneath the BODY {

body {background-img:url("http://www.xbox.v76host.com/forum/images/trindel/tweety_mad.jpg");
background-attachment:fixed;}

I used a mad tweety just to test it, yet nothing shows. Im guessing im putting the wrong code in?

assassingod
11-23-2003, 12:25 PM
Sorry, just add:

background-img:url("http://www.xbox.v76host.com/forum/images/trindel/tweety_mad.jpg");
background-attachment:fixed;


Under

BODY {

MindTrix
11-23-2003, 12:33 PM
Huuuuummmmmmm still nothing :) I must be doing something wrong even though im doing exactly as you said.

This is my body tag inside my fonts/colours etc etc

<body bgcolor="#243142" text="#CACFD5" id="all" leftmargin="10" topmargin="10" marginwidth="10" marginheight="10" link="#000020" vlink="#000020" alink="#000020">

Would that effect it in anyway?

Dan
11-23-2003, 12:47 PM
When I tried this, my users complained that it slowed their browsing down.
Actually it does slow down scrolling especially if you are using the scroll on a scroll mouse. I use to think it was cool untill I noticed how slow it made it when I was browsing my/others forums.

assassingod
11-23-2003, 12:56 PM
LOL, Sorry Liam I was spelling image wrong;)

background-image:url("http://www.xbox.v76host.com/forum/images/trindel/tweety_mad.jpg");
background-attachment:fixed;

Will work:)

MindTrix
11-23-2003, 01:02 PM
lol um still doesnt work, I think i should just give up :p ive done everything right so i dont really see why its not working.

assassingod
11-23-2003, 01:03 PM
Strange because I got it working fine on my localhost

Instead of using a full URL, upload the image to your images folder and use {imagesfolder}/filename.gif as the URl

MindTrix
11-23-2003, 01:07 PM
Lol still nothing :) Must be something stopping it showing.

This is my head insert code as it looks now

<meta http-equiv="MSThemeCompatible" content="Yes">
<style type="text/css">
BODY {
background-image:url("{imagesfolder}/jordan.jpg");
background-attachment:fixed;

SCROLLBAR-BASE-COLOR: {categorybackcolor};

I changed the picture to a bigger one so that i would definetly see it if it showed.


Odd no? :)

assassingod
11-23-2003, 01:13 PM
Very odd, it's fine for me. Try this:

background-image:url("{imagesfolder}/jordan.jpg");
background-attachment:fixed;
background-repeat:repeat-x;

Under

BODY {

MindTrix
11-23-2003, 01:15 PM
lmao still nothing :) Think i should just give up :)

Probably something on the site stopping it showing.

assassingod
11-23-2003, 01:17 PM
Just a quick thought, if you have multiple styles, are you sure you are applying it to the right one?

MindTrix
11-23-2003, 01:18 PM
im dumb, just not that dumb :) So yeah ive added it to the right one, still nothing. Oh well lol

MindTrix
11-23-2003, 01:37 PM
Ok turns out the code works perfectly, i just had lose code in my template that wasnt allowing it to work, but assassingod took it upon himself to go onto my site and fix it personally, so cheers mate. (Note i didnt even have to ask him :) )

Princeton
11-23-2003, 02:51 PM
shortcut:
background: url(yourimage.gif) #fff 50% no-repeat fixed }

(50% - center)

Syntax
background: background-color | background-image | background-repeat | background-attachment | background-position

you can mix and match but the background-repeat and background-attachment must be together

Note: the background shorthand property partially work on webTV and older browsers (4.0)

Dean C
11-23-2003, 04:45 PM
Time to move to templates forum ;)