smarty_470 Posted August 1, 2013 Share Posted August 1, 2013 Hello folks, I am new to this forum and looking for some help from all you awesome ones. I have the following two pages on two different sites: http://www.jli.edu.in/programs.php http://www.jli.sg/programs When you click on the first one you will see a section 'Course Structure' and clicking on it will show its content. Now the second one runs the same code and calls for the same files but somehow it is not working. It is showing open by default. Can anyone point out to me why this is happening? Appreciate your help in this regard. Smarty470 Quote Link to comment https://forums.phpfreaks.com/topic/280709-need-help-with-simple-jquery-not-working/ Share on other sites More sharing options...
Muddy_Funster Posted August 1, 2013 Share Posted August 1, 2013 are you atempting to load files across different domains using javascript? Quote Link to comment https://forums.phpfreaks.com/topic/280709-need-help-with-simple-jquery-not-working/#findComment-1442936 Share on other sites More sharing options...
smarty_470 Posted August 1, 2013 Author Share Posted August 1, 2013 Thanks for the reply. No the files are hosted on the same site: Here is the code: <head> <!--accordian script--> <script type="text/javascript" src="js/jquery.js"></script> <script type="text/javascript" src="js/chili-1.7.pack.js"></script> <script type="text/javascript" src="js/jquery.easing.js"></script> <script type="text/javascript" src="js/jquery.dimensions.js"></script> <script type="text/javascript" src="js/jquery.accordion.js"></script> <script type="text/javascript"> jQuery().ready(function(){ // simple accordion jQuery('#list1a').accordion(); jQuery('#list1b').accordion({ autoheight: false }); jQuery('#list3').accordion({ header: 'div.accordian_title', active: false, alwaysOpen: false, animated: false, autoheight: false }); jQuery('#list4').accordion({ header: 'div.accordian_title', active: false, alwaysOpen: false, animated: false, autoheight: false }); var accordions = jQuery('#list1a, #list1b, #list3'); jQuery('#switch select').change(function() { accordions.accordion("activate", this.selectedIndex-1 ); }); jQuery('#close').click(function() { accordions.accordion("activate", -1); }); jQuery('#switch2').change(function() { accordions.accordion("activate", this.value); }); jQuery('#enable').click(function() { accordions.accordion("enable"); }); jQuery('#disable').click(function() { accordions.accordion("disable"); }); jQuery('#remove').click(function() { accordions.accordion("destroy"); wizardButtons.unbind("click"); }); }); </script> </head> <html> <div id="list3"> <div class="head2 accordian_title"><p class="float"><b>Program Curriculum</b></p><p class="float_right"><img src="images/tooltip_arrow.gif" alt="" border="0" /></p> <p class="clear"></p></div> <div> <ul class="program_listing"> <img src="images/PGDCR-Curriculum.jpg" alt="program curriculum" border="0" /> </ul><br></div> </html> Quote Link to comment https://forums.phpfreaks.com/topic/280709-need-help-with-simple-jquery-not-working/#findComment-1442937 Share on other sites More sharing options...
Muddy_Funster Posted August 1, 2013 Share Posted August 1, 2013 not seeing where tht script is loading any content, or indeed where any PHP is... Quote Link to comment https://forums.phpfreaks.com/topic/280709-need-help-with-simple-jquery-not-working/#findComment-1442941 Share on other sites More sharing options...
smarty_470 Posted August 1, 2013 Author Share Posted August 1, 2013 I only posted the code related to this script. Can you check the page source please? Thanks Quote Link to comment https://forums.phpfreaks.com/topic/280709-need-help-with-simple-jquery-not-working/#findComment-1442943 Share on other sites More sharing options...
jakerow Posted August 1, 2013 Share Posted August 1, 2013 Is it called program curriculum in one and course structure in the other? To me they both are not open by default. Using Chrome Version 25.0.1364.152 Quote Link to comment https://forums.phpfreaks.com/topic/280709-need-help-with-simple-jquery-not-working/#findComment-1442984 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.