Moderators: Derry, Goldie, Harpo
Go
New
Find
Notify
Tools
Reply
  
5-star Rating (1 Vote) Rate It!  Login/Join 
Junior Mechanic
Posted
Hi!

I would simply like to know how I can prevent a vertical scrollbar from appearing on my indexpage even though the page is too long to view in entirety without one.

The reason is that I am using an image as decoration on the page, and it is placed so it exceeds the bottom of the page and thus it creates the scrollbar. however, I do not want viewers scrolling down just to see the image end down there. Smile

I already tried using the image as a background, and it worked fine, except it was way slower to load this way, thus I would like to just insert the image to the page and cut out the scrollbar.
 
Posts: 2 | Registered: March 10, 2006Reply With QuoteEdit or Delete MessageReport This Post
Guru 'Power' Mechanic
Picture of Bruceee
Posted Hide Post
Try this either as a custom header (preferable) or as a code object:
<style type="text/css">
body{overflow:hidden;}
</style>

There shouldn't be any difference in load time between a background image (Page Editor > Background tab) and the same image in the foreground. The image has to be downloaded the first time it is displayed, and after that it should be "free", either way. Could there have been some other factor in play that is misleading you?
 
Posts: 9269 | Location: Wellington, New Zealand | Registered: December 11, 2003Reply With QuoteEdit or Delete MessageReport This Post
Junior Mechanic
Posted Hide Post
Many thanks Bruceee! Smile

That code snippet worked wonders. By the way, I did not really know what the purpose of the custom header was earlier, can you use it just like you would your <head> tag in normal html editing?

On the case of the loading, I know it sounds weird, and in fact it is. Thing is though, either it has to do with my webspace provider, or just my own machine, the image is taking longer to load when it is used in the background.

The page loads, and you have the text there, and it takes something between 3 and 5 seconds until the image pops in there out of nowhere. Smile
 
Posts: 2 | Registered: March 10, 2006Reply With QuoteEdit or Delete MessageReport This Post
Guru 'Power' Mechanic
Picture of Bruceee
Posted Hide Post
quote:
can you use it just like you would your <head> tag in normal html editing?
Yes, if you look at the published code, you'll see the custom header code between the <HEAD> and </HEAD> tags.

If you put an image on your page as distinct from using it as a background, it displays progressively, so you start to see it before it is all loaded. That would make it seem to load faster. Could that be the difference?
 
Posts: 9269 | Location: Wellington, New Zealand | Registered: December 11, 2003Reply With QuoteEdit or Delete MessageReport This Post
Working Mechanic
Picture of coreyjames66
Posted Hide Post
O.k., So here's a question......

Will that code do the same for a "Side Scroller"?

If not is there code for that?


*******I know not what I do. I'm just thrilled that sometimes, it works!*******
 
Posts: 78 | Location: Minnesota(or) Minahsoda, as we like to call it! | Registered: May 14, 2005Reply With QuoteEdit or Delete MessageReport This Post
Guru 'Power' Mechanic
Picture of Bruceee
Posted Hide Post
It should kill the horizontal scroll bar as well -- try it Smile
 
Posts: 9269 | Location: Wellington, New Zealand | Registered: December 11, 2003Reply With QuoteEdit or Delete MessageReport This Post
Working Mechanic
Posted Hide Post
quote:
"Side Scroller"?


What about killing just the horizontal Scroller?
Is that possible?
 
Posts: 20 | Registered: June 19, 2006Reply With QuoteEdit or Delete MessageReport This Post
Guru 'Power' Mechanic
Picture of Bruceee
Posted Hide Post
Browsers generally display a horizontal scrollbar only when necessary. If you see one, when there shouldn't be one, it may be that you have an object off the edge of your page.

See also: this thread.

I don't know of any code that will unconditionally suppress the horizontal scrollbar and leave the vertical untouched. Such code may well exist though -- try Google. If you find something, please do post it here.
 
Posts: 9269 | Location: Wellington, New Zealand | Registered: December 11, 2003Reply With QuoteEdit or Delete MessageReport This Post
  Powered by Eve Community  
 


™ & © 1998 - 2008, Virtual Mechanics Inc. All rights reserved.