Avatar of kathys39
kathys39
 asked on

jquery tabs - not working when loaded in a new div

I have a basic index page using jquery tabs for left-hand navigation.  When I click a link, I load an external html file in a div - that part works as the html is loaded fine.  What does not work is any jquery and/or jquery tabs in the new div -

Here is code from my index.php:

Now from my js file which I have included in my index.php:

 $(document).read(function() {
        $('#training').click(function() {
            $(#contentcolumn").load("training.html");
             return false;
       })
})

and finally my training.html file, where the html loads, but the tabs do not appear at all, just a list appears for what should be tabs:

<div id = "training sked">
<ul class="anchors">
  <li><a href="#Program">Program Classes</a></li>
  .....
</ul>

<div id = "Program" class="anchor">
<table id = "programclass">
....
</table>

Can anyone help me figure out why the jquery tabs are not working correctly in the new div?


<ul class="category items">
    <li><a id="training"> href="#">Training Schedule</a></li>
 ...
</ul>
 
Later on I do have my <div id = contentcolumn> for the new data to appear

Open in new window

JavaScript

Avatar of undefined
Last Comment
hielo

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
hielo

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
All of life is about relationships, and EE has made a viirtual community a real community. It lifts everyone's boat
William Peck