Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

HTML Forum


You are currently viewing our HTML Forum as a guest. Please register to participate.
Login



Post a Project »

Find a Professional HTML Freelancer!

Find a Freelancer to help you with your HTML projects

FREE Outsourcing eBook!

Reply
Old 01-24-2006, 06:31 PM Odd "DIV" behavior
Novice Talker

Posts: 10
Name: Adam H
Location: UK
Trades: 0
This is kinda complex, i have a JavaScript.
Which when users click "HIDE" it hides all of the "GAME" content, so it looks like a nice innocent site.

So make the site then have a point, Google search then pops up in the thing. Pretty simple, and will confuse the simplest of Boss's / Teachers.


ALTHOUGH!!!..
Its all working, but the google bit that is supposed to replace the game content when users click HIDE. stays at the bottom of the screen.

Can anyone please help me make the div go to the top when the other div is hidden?


----------
I would include the html, but its all over the place, be easier for you guys to "VIEW SOURCE".

Thanks in advance!!!

(Their will be buttons, or by time you view it, it may be as a image. The button / image is near the top under the logo )
__________________
FunShed.com .. Offline due to re-development.
FunShed.com is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 01-25-2006, 01:09 AM
vangogh's Avatar
Post Impressionist

Latest Blog Post:
Why Responsive Design?
Posts: 10,815
Name: Steven Bradley
Location: Boulder, Colorado
Trades: 0
I took a quick look and I think it's because of the way you're hiding the content area. You're setting the visibility of the content to hidden when the button is clicked which would seem to make sense except that just hides the content, it's still technically there even though you can't see it.

The Google stuff stays where it is because as I mentioned above the content is still there even though it's not visible.

What you want to do is change the content area to display:none (You may have to give it a display:block before the script is applied so it has the display property. I can't remember at the moment if that's necessary) This will not only hide it, but take it out of the normal document flow and allow the Google stuff at the bottom to move up to where you want.

A couple of alternatives if you want to leave is as visibilty:hidden You can also give the content area an absolute position {position:absolute} This should also remove it from the normal document flow. You may also need to give it a value for top or left. I don't think so, but maybe. If you do just move the stuff far off to the right or left.

You can also give the Google info some position information and tell it where to go when you hide the content. so maybe the script would give the Google info
{position:absolute; top:20px; left:200px}

I think removing the content area from the document flow using display:none will be the easist option.
__________________
l Search Engine Friendly Web Design |
Please login or register to view this content. Registration is FREE

l Tips On Marketing, SEO, Design, and Development |
Please login or register to view this content. Registration is FREE

l
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
vangogh is offline
Reply With Quote
View Public Profile Visit vangogh's homepage!
 
Old 01-28-2006, 05:46 AM
Novice Talker

Posts: 6
Name: Rob
Location: Queensland Australia
Trades: 0
site looks good now FunShed
RRavens is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Odd "DIV" behavior
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.37318 seconds with 12 queries