javascript - Do I need to include css and js files in the lightbox page? -


do need load css , js files again in lightbox html code? css seems work fine. js functions not work in lightbox page. js files included in parent html page , triggered in same file.

only jquery code have written in lightbox html code works in lightbox page. other js functions written in included js files not work.

should use different methods trigger js functions included in parent page in lightbox page??

edit

lightbox html code:

<div id="lightbox-holder">     <div class="result">          <p>total amount</p>          <h3>1000</h3>     </div>      <div class="equal-sign"> </div>      <div class="left-stepper">  //stepper input       <label class="steper-label">left stepper</label>       <input type="text" id="spinner1" class="ui-stepper" value="0" />     </div>      <div class="plus-sign"> </div>      <div class="right-stepper"> //stepper input         <label class="steper-label">right stepper</label>         <input type="text" id="spinner2" class="ui-stepper" value="0" />     </div>    </div>   <script type="text/javascript">    $(document).ready(function (){          func.init();          $('#cost_allocation').live('click', function() {                $(this).hide();             $('#help_icon').hide();             $('#breakdown').show();                $('#ok_button').hide();             $('#save_button').show();          });          $('#save_button').live('click', function(){             $("#jqlightboxcontents").remove();             $("#jqveil").remove();          }); }); </script> 

this jquery inside lightbox page works. js functions triggered through func.init() not work.

the func.init() triggering js files required code work. example, stepper input unit(numeric stepper) code written in file named stepper.js , triggered using init function. works in parent page, not displayed in lightbox page. should invoke init() function in different way?

no, not. since lightbox in same page, there no need reinclude files.


Comments

Popular posts from this blog

php - What is the difference between $_SERVER['PATH_INFO'] and $_SERVER['ORIG_PATH_INFO']? -

fortran - Function return type mismatch -

queue - mq_receive: message too long -