Nestor C
Nestor C

Reputation: 637

jquery is not working when we got error somewhere in page

i have 3 pages ,

one page is main page , and other 2 pages, (popup pages),

in main page( page No 1) , i am writing jquery references

<script type="text/javascript" src="../Scripts/jquery-1.7.1.js"></script>
    <script type="text/javascript" src="../Scripts/jquery-ui-1.8.20.js"></script>

now i am loading second page(page No 2) in popup using lightbox jquery popup, i am not write any jquery reference in second page, same like when i am opening 3rd page,

now problem is , if i wrote jquery ajax function to page no 3, and if i got error there, page 2 Jquery also stop working ( for example : in page -2 , document ready if i hide some element, it's stop to work)

why?

Upvotes: 1

Views: 166

Answers (1)

Barry Chapman
Barry Chapman

Reputation: 6780

if it is a completely new window, ie: not part of the DOM of the window that opened it, it will not have the necessary script files to run.

In your HTML for your 'child' windows, include the references to the jquery assets necessary

Upvotes: 2

Related Questions