![]() |
How do I get an image to show over the entire page?
I have an image that I have changed the opacity on that I would like to have appear over the site - sort of like a ghosted image. What would be the best way to do this, how do I get the image to always fill the screen no matter resolution or forum index length, etc? Detailed instructions would be greatly appreciated.
Actually, what I would also like to try, and perhaps instructions could be offered for that as well, would be to make the image static, so that the forum/index scrolls, but the image does not move with the rest of the forum... thanks again. --------------- Added [DATE]1378783397[/DATE] at [TIME]1378783397[/TIME] --------------- BUMP Basically I have a custom template that I bought. I like the colors and I want to keep them, but I want to "ghost" an image over it... how? Thanks... |
Do you mean like in the background? if you're talking about foreground, you wouldn't be able to do it since you wouldn't be able to click the links behind it..
|
To make your background not scroll with your forum index do the following:
Styles and Templates > Style Manager Choose your theme/style and click on Go In the input box at the top it will say "search stylevar", in there look for "doc_background" Once you are in there add the following: At the very end of your background's url add "fixed" , minus the double quotes. It should look like this: Code:
url(http://www.yourdomain.com/path-to-your-background-image/image.jpg) fixed You shouldn't have to change anything except just adding "fixed" to the end of the url. Then make sure you have Background Repeat set to "repeat-y" Units set to "% " Background Image Horizontal Offset set to "50" Background Image Vertical Offset set to "0" |
Ok, thanks. That worked. Went into additional.css file in Admin. However, I have noticed that it renders correctly in all browsers except for IE. It seems to not be full width of screen. How would I fix this issue? Thanks!
Seems that this might be an IE8 issue... how to fix to cover those users using IE8? |
Hmmmm...weird...it works for me on IE...did you clear your cookies and cache?
Try that and let me know what happens...Do you have a link I can check your site out? |
Quote:
Thanks again! I narrowed it down to this: The image was around 1200 X 800 (rough guess...) it renders fine on my laptop, but when I go to a larger desktop monitor it centers the image (like it should) but the image does not stretch to fill the monitor. I ended up increasing the image size with gimp and photoshop, but now the png is massive ~10 megs. It now fills the entire screen on both, but I believe that this is way to massive, though it is relatively quick on my high speed internet, just thinking of those that may not have this... I used pngcrush, but it only shrunk the png (transparent background) by 3%. Any ideas? The original image was like 1240x800 (?) but since the larger desktop monitor has a higher resolution the smaller png image was not filling the background, so I had to double the pixel size on the original which took it from around 1 meg to 10 megs... help... |
I stopped supporting IE8 and IE7 this year and now I just degrade new areas of the board graciously.
The way to handle IE8 is to have a different solution then modern browsers. A simple but effective way is just to use IE conditional comments in HTML. Then you can supply a different formatted graphic for IE8 and have different CSS. Just Google the term. I would just pass you my code, but we use 'LESS' for our highly modified CSS. Would really just confuse you. If you decide to go with 'IE conditional comments in HTML' and have a problem, post your code, and give me a yell. I remember fooling around with the images and I believe we supported 1900x1200 wallpaper, our image size was 140-190k (depending on the detail). This took quite a bit of work in Photoshop to get the bitrate -- for lack of a better word -- correct. Forget about that 10meg image, your users will end up hating it. Turn off your cache on your browser and you will find out. Hope any of this helps! :) PS: You will not find a simple CSS solution to handle full background images effectively for older IE browsers. <-- Trying to save you some time. . |
Thanks. I thought about the html ie override to ie only css file, but too much work. So basically pass on ie deprecated browsers and assume users are using ie9 which should render correctly?
--------------- Added [DATE]1379091457[/DATE] at [TIME]1379091457[/TIME] --------------- Thanks on the wallpaper size... yea, need to figure out a way to get a smaller image size... --------------- Added [DATE]1379092191[/DATE] at [TIME]1379092191[/TIME] --------------- Actually, if you could post it here or pm me what you did for ie8 in your html and relevant css file I would appreciate it... was looking online and I still see that ie8 is used by 10% of the global users... opinions, thoughts on setting up forum for ie8 users? Thanks. |
Quote:
Coders of the World, Unite! |
I believe this should do the work:
PHP Code:
|
Quote:
|
Quote:
|
Quote:
tut: PHP Code:
http://paulmason.name/media/demos/fu...kground-image/ |
Thanks I will try that. Any idea how to shrink a png file smaller? I tried a different image and I was able to compress it to 2 megs which I think is still too big... I need the transparency...
|
Quote:
if you have original source .psd, then you can reduce the size foor sure, but for now if you don't then use the link above to make the size as small as possible. Good luck |
Quote:
|
Thanks. I have been using that. The smallest I can get the image down in a png is 1.6m is that going to be an issue? Thanks for the input...
|
Quote:
|
Quote:
|
I see that someone developed a JS for multiple backgrounds, including crappy IE (deprecated versions)... I have a custom template, but I assume the same as the vanilla version that came with VB. Anyways, can I add the JS through the admincp? If not, which files would be the most appropriate? Thanks again!
--------------- Added [DATE]1379529349[/DATE] at [TIME]1379529349[/TIME] --------------- I see that someone developed a JS for multiple backgrounds, including crappy IE (deprecated versions)... I have a custom template, but I assume the same as the vanilla version that came with VB. Anyways, can I add the JS through the admincp? If not, which files would be the most appropriate? Thanks again! EDIT: found this to supercede the JS, thoughts on how to implement it, and which files? Thanks! https://github.com/louisremi/background-size-polyfill --------------- Added [DATE]1379529678[/DATE] at [TIME]1379529678[/TIME] --------------- Not sure how to change the htc file to show my background image... help... |
Quote:
Have no answer for your latest question as I pretty much ignore issues that IE 6-8 has with my site :D |
Well I have come to the conclusion to F@ck IE 7 and IE 8!!!!! ...and trying to wrap my forum around these users... What a waste of my time...
Should have listened to the advice given here... |
Ok, so what exactly is the problem ... I might be able to help
|
Quote:
|
Ok My Man, I think I have the perfect solution for you to add the 2nd background to your site using a png image.
This script here I use it for a vote pop up on my site, but I just changed it a bit and it actually adds a background to the whole page using a 1x1 png image but you can use a full size image as well if its a png one. You are going to want to add this to your "header" template at the very top before anything else. Replace the transa.png file with what ever your image's file name is. Remember, this image has to be a png file which is what you want, so you should have no problems here. Replace the url of the trans.png's with where your file is located at and you should be good to go My Man ! Remember, this is a pop up I use for a vote feature on mysite, so you might have to play with it a little but it should work just like I posted it for you. GOOD LUCK ! Code:
<!-- Vote Popup --> |
Hey, thanks! Will give it a try!
|
No problem, hope it works out for you buddy...let me know if it works and if it doesn't let me know anyways and I will help you out with making it work....
|
All times are GMT. The time now is 11:07 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|