Jump to content

jquery help: find children of ..


everisk

Recommended Posts

I have a code like

 

//we search trough the content for the visible div and we fade it out

$("#container_upper_bg").find("div:visible").fadeOut("fast", function(){

 

//once the fade out is completed, we start to fade in the right div

$("#container_upper_bg").find("#"+idToLoad[0]).fadeIn();  <--- Here I want find #idToLoad and its children, then fadeIn .. How do I do that?

 

Thank you in advance!

 

 

Link to comment
https://forums.phpfreaks.com/topic/178570-jquery-help-find-children-of/
Share on other sites

idToLoad is part of container_upper_bg, but container_upper_bg contains a few others div, including idToLoad. However, idToLoad might contain its own children (div) and I only want idToLoad and its children to fadeIn .. not all children of container_upper_bg. HTML is something like

 

<div id="container_upper_bg">

<div id="home">

        <div id="container_upper_center">

            <div id="upper_left">

                  Some information

            </div>

            <div id="upper_right"><img src="images/home_pic.jpg"></div>

        </div> <!-- end container_upper_center -->

    </div>

   

    <div id="service" style="display:none">

        Some other information

    </div>

   

</div> <!-- end container_upper_bg -->

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.